Difference between revisions of "BIS fnc respawnTickets"

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " <h3 style="display:none">Notes</h3> <dl class="command_description"> <!-- Note Section BEGIN --> <!-- Note Section END --> </dl> " to "")
m (Text replacement - " *\|= " to " ")
Line 39: Line 39:
|x3= Return number of player's tickets
|x3= Return number of player's tickets
<code><nowiki>playerTickets = [</nowiki>[[player]],[[nil]],[[true]]] [[call]] [[BIS_fnc_respawnTickets]];</code> |=
<code><nowiki>playerTickets = [</nowiki>[[player]],[[nil]],[[true]]] [[call]] [[BIS_fnc_respawnTickets]];</code>
| [[Arma 3 Respawn]], [[BIS_fnc_addRespawnPosition]], [[BIS_fnc_removeRespawnPosition]] |SEEALSO=
| [[Arma 3 Respawn]], [[BIS_fnc_addRespawnPosition]], [[BIS_fnc_removeRespawnPosition]] |SEEALSO=

Revision as of 22:16, 17 January 2021

Hover & click on the images for description


Manage respawn tickets used by Tickets respawn template. When player dies, number of tickets is decreased by 1. The most local tickets are always used. Example: When you first add tickets to player's side, they will be affected. If you later define tickets also to player's group, they will completely replace the side tickets. When player runs out of the tickets, his respawn is disabled. If you use also EndMission respawn template, the mission will automatically end once tickets in all name spaces are exhausted.


[<target>,(<tickets>,<dynamicTarget>)] call BIS_fnc_respawnTickets;
target: Receiver of the respawn tickets
Namespace - use missionNamespace to set/get global tickets available for everyone
tickets: Number - added respawn tickets. When missing or set to 0, number of tickets won't be affected, which means you can use the function to simply get amount of tickets.
dynamicTarget: Boolean - when true, set/get tickets based on the target. target must be an Object.
Return Value:
Number - remaining tickets after adjustment

Alternative Syntax

[] call BIS_fnc_respawnTickets;
Return Value:
Number - remaining tickets in all name spaces


Example 1:
Add 5 tickets for BLUFOR [west, 5] call BIS_fnc_respawnTickets;
Example 2:
Return number of global tickets globalTickets = [missionNamespace] call BIS_fnc_respawnTickets;
Example 3:
Return number of player's tickets playerTickets = [player,nil,true] call BIS_fnc_respawnTickets;

Additional Information

See also:
Arma 3 RespawnBIS_fnc_addRespawnPositionBIS_fnc_removeRespawnPosition


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

Bottom Section