onPlayerDisconnected: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - "{{Command " to "{{RV|type=command ")
m (Text replacement - " *\| *Exec *= * " to " ")
Line 7: Line 7:
|gr2= Event Handlers
|gr2= Event Handlers


|serverExec= server |Exec=
|serverExec= server


| This command will execute attached code whenever a player is leaving an MP session. The code will receive a number of special variables:
| This command will execute attached code whenever a player is leaving an MP session. The code will receive a number of special variables:

Revision as of 19:54, 29 January 2021

Hover & click on the images for description

Description

Description:
Description needed
Multiplayer:
In MP onPlayerDisconnected is executed only on the server
Groups:
MultiplayerEvent Handlers

Syntax

Syntax:
Syntax needed
Parameters:
code: String or Code
Return Value:
Return value needed

Examples

Example 1:
onPlayerDisconnected "diag_log [_id, _uid, _name]";
Example 2:
onPlayerDisconnected { if (count allPlayers == 0) then { endMission "END1"; }; };

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
Posted on January 14, 2015 - 19:21 (UTC)
AgentRev
For Arma 3 v1.32 and onward, one might want to consider using instead the HandleDisconnect mission event handler for greater flexibility.