setVehicleVarName: Difference between revisions
Jump to navigation
Jump to search
(anyone can explain this better?) |
m (<nowiki>) |
||
Line 7: | Line 7: | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
| Sets the name of the variable which contains a reference to this object. It is necessary in MP to change the variable content after a respawn. When you only use 'myVar = <vehicle>', you'll just have a normal variable, when you use this command as well, 'myVar' will be the name for the vehicle, i.e. if you have other variables containing the vehicle, they'll now return 'myVar' and not WEST ...|= Description | | Sets the name of the variable which contains a reference to this object. It is necessary in MP to change the variable content after a respawn. When you only use 'myVar <nowiki>=</nowiki> <vehicle>', you'll just have a normal variable, when you use this command as well, 'myVar' will be the name for the vehicle, i.e. if you have other variables containing the vehicle, they'll now return 'myVar' and not WEST ...|= Description | ||
____________________________________________________________________________________________ | ____________________________________________________________________________________________ | ||
Revision as of 10:28, 19 January 2009
Description
- Description:
- Sets the name of the variable which contains a reference to this object. It is necessary in MP to change the variable content after a respawn. When you only use 'myVar = <vehicle>', you'll just have a normal variable, when you use this command as well, 'myVar' will be the name for the vehicle, i.e. if you have other variables containing the vehicle, they'll now return 'myVar' and not WEST ...
- Groups:
- Uncategorised
Syntax
Examples
- Example 1:
player setVehicleVarName "aP"
- Example 3:
//Assign a variable to an object and be able to refer to that
//object using the variable, in both single and multi player.
_Object="M1A1" CreateVehicle (GetPos Player); _VarName="MYTANK"; _Object SetVehicleVarName _VarName; _Object Call Compile Format ["%1=_This ; PublicVariable ""%1""",_VarName];
Additional Information
- See also:
- See also needed
Notes
-
Report bugs on the Feedback Tracker and/or discuss them on the Arma Discord or on the Forums.
Only post proven facts here! Add Note