setVehicleInit: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "<code>([^<]*)\[\[Magic Variables#this(_| )2\|(this)\]\]([^<]*)<\/code>" to "<code>$1$3$4</code>")
m (Text replacement - "[[Initialization Order" to "[[Initialisation Order")
 
(2 intermediate revisions by the same user not shown)
Line 25: Line 25:


|mp= The statement will be sent to clients connecting after the command has been executed.<br>
|mp= The statement will be sent to clients connecting after the command has been executed.<br>
Note that the statement will be executed automatically by [[Multiplayer Scripting#Join In Progress|JIP]] clients before [[Event Scripts#init.sqs|init.sqs]]/[[Event_Scripts#init.sqf|init.sqf]] have been executed - see [[Initialization Order]].
Note that the statement will be executed automatically by [[Multiplayer Scripting#Join In Progress|JIP]] clients before [[Event Scripts#init.sqs|init.sqs]]/[[Event_Scripts#init.sqf|init.sqf]] have been executed - see [[Initialisation Order]].


|s1= unitName [[setVehicleInit]] statement
|s1= unitName [[setVehicleInit]] statement
Line 35: Line 35:
|r1= [[Nothing]]
|r1= [[Nothing]]


|x1= <code>_soldier3 setVehicleInit "this allowFleeing 0";</code>
|x1= <sqf>_soldier3 setVehicleInit "this allowFleeing 0";</sqf>


|seealso= [[Multiplayer Scripting]] [[Initialization Order]] [[processInitCommands]] [[clearVehicleInit]]
|seealso= [[Multiplayer Scripting]] [[Initialisation Order]] [[processInitCommands]] [[clearVehicleInit]]
}}
}}


Line 49: Line 49:


<dt><dt>
<dt><dt>
<dd class="notedate">Posted on May 22, 2016 - 21:38 (UTC)</dd>
<dd class="notedate">Posted on 2016-05-22 - 21:38 (UTC)</dd>
<dt class="note">[[User:AgentRevolution|AgentRev]]</dt>
<dt class="note">[[User:AgentRevolution|AgentRev]]</dt>
<dd class="note">[[remoteExec]] and [[remoteExecCall]] will accept an object as JIP parameter, which make them behave in a very similar way to [[setVehicleInit]] before it was disabled.</dd>
<dd class="note">[[remoteExec]] and [[remoteExecCall]] will accept an object as JIP parameter, which make them behave in a very similar way to [[setVehicleInit]] before it was disabled.</dd>


</dl>
</dl>

Latest revision as of 19:32, 18 May 2023

Hover & click on the images for description

Description

Description:
Attach a statement to a unit. The statement is propagated over the network in MP games, it can be executed by invoking processInitCommands.
Arma 3
For security reasons, the command was disabled in Arma 3. Use remoteExec for remote execution.
Multiplayer:
The statement will be sent to clients connecting after the command has been executed.
Note that the statement will be executed automatically by JIP clients before init.sqs/init.sqf have been executed - see Initialisation Order.
Groups:
Object Manipulation

Syntax

Syntax:
unitName setVehicleInit statement
Parameters:
unitName: Object
statement: String
Return Value:
Nothing

Examples

Example 1:
_soldier3 setVehicleInit "this allowFleeing 0";

Additional Information

See also:
Multiplayer Scripting Initialisation Order processInitCommands clearVehicleInit

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
03:12, 20 March 2008 (CET)
Crowe
setVehicleInit statements will be executed in the order of the unit creation time. This means, the statements of units who have been placed in the editor first, will be executed first.
Posted on 2016-05-22 - 21:38 (UTC)
AgentRev
remoteExec and remoteExecCall will accept an object as JIP parameter, which make them behave in a very similar way to setVehicleInit before it was disabled.