Page tree
Skip to end of metadata
Go to start of metadata



Introduced in

Version:1.00

Description

Description:

Specifies the code to run when a player connects to an MP session.

Note: Non-functional for JIP.

Syntax

Syntax:onPlayerConnected code
Parameters:
  • code: String - Code. The array _this can be used, which contains the _id (see clientID) and the _name (see clientName) of the joining player.
Return Value:Nothing

Examples

Examples:onPlayerConnected "[_id, _name] execVM ""PlayerConnected.sqf""";

Additional Information

See also: onPlayerDisconnected
Multiplayer:The code executes only on the server, not on the joining player computer, nor on any other client. This happens even if onPlayerConnected executes on all machines.
Problems: 

Notes