BIS fnc bleedTickets: Difference between revisions

From Bohemia Interactive Community
Jump to navigation Jump to search
m (Text replacement - " {{Function|Comments=" to "{{Function|Comments=")
m (overhauled page to use proper formatting)
Line 1: Line 1:
{{Function|Comments=
{{Function
____________________________________________________________________________________________


| arma3 |Game name=
|game1= arma3


|1.10|Game version=
|version1= 1.10
____________________________________________________________________________________________


| Function that handles bleeding ticket system. Tickets are set beforehand using [[BIS_fnc_respawnTickets]]. |DESCRIPTION=
<!--|exec= server|=-->
____________________________________________________________________________________________


| [<nowiki>[WEST,EAST,RESISTANCE,CIVILIAN]</nowiki>, 0.5, 3, 5] call '''BIS_fnc_bleedTickets'''; |SYNTAX=
<!--|arg= local-->


|p1= [[Array]] - Array of sides that should be affected by bleed tickets. ''Optional parameter, default is '''all''' sides''.|Parameter1=
|eff= local
|p2= [[Number]] - Dominance ratio, values from 0 to 1. Determines how much of a sector a side must hold for bleeding tickets to start. ''Optional parameter, default is 0.5 (ie half a sector)''. |Parameter2=


|p3= [[Number]] - Amount of tickets bled every step. ''Optional parameter, default value 3''. |PARAMETER3=
|descr= Function that handles bleeding ticket system. Tickets are set beforehand using [[BIS_fnc_respawnTickets]].


|p4= [[Number]] - Delay in seconds between every bleeding step. ''Optional parameter, default value 5''. |=
|mp= Server-side execution only.


| [[Boolean]] |RETURNVALUE=
|s1= [sides, dominanceRatio, bleedingAmount, bleedingDelay] call [[BIS_fnc_bleedTickets]]
|mp= Server-side execution only. |=
____________________________________________________________________________________________


|x1= <code>[] call BIS_fnc_bleedTickets; // Uses all default values to start the system.</code> |Example1=
|p1= sides: [[Array]] - (Optional, default All sides) Array of effected sides
|x2= <code><nowiki>[[WEST,EAST], 1, 1, 10]</nowiki> call BIS_fnc_bleedTickets; // Starts the system with WEST and EAST involved, bleeding one ticket every ten seconds if one side holds the whole sector.</code> |=
____________________________________________________________________________________________


| [[BIS_fnc_addScriptedEventHandler]] |SEEALSO=
|p2= dominanceRatio: [[Number]] - (Optional, default 0.5) Dominance ratio, values from 0 to 1. Determines how much of a sector a side must hold for bleeding tickets to start
 
|p3= bleedingAmount: [[Number]] - (Optional, default 3) Amount of tickets bled every step. Optional parameter
 
|p4= bleedingDelay: [[Object]] - (Optional, default 5) Delay in seconds between every bleeding step
 
|r1= [[Boolean]]
 
|x1= <code>[[call]] [[BIS_fnc_bleedTickets]];</code>
 
|x2= <code><noWiki>[[</noWiki>[[WEST]],[[EAST]]<noWiki>]</noWiki>, 1, 1, 10] [[call]] [[BIS_fnc_bleedTickets]];</code>
 
|exec= call
 
|seealso= [[BIS_fnc_addScriptedEventHandler]] [[BIS_fnc_respawnTickets]]


}}
}}

Revision as of 10:53, 11 January 2020

Hover & click on the images for description

Description

Description:
Function that handles bleeding ticket system. Tickets are set beforehand using BIS_fnc_respawnTickets.
Execution:
call
Multiplayer:
Server-side execution only.
Groups:
Uncategorised

Syntax

Syntax:
[sides, dominanceRatio, bleedingAmount, bleedingDelay] call BIS_fnc_bleedTickets
Parameters:
sides: Array - (Optional, default All sides) Array of effected sides
dominanceRatio: Number - (Optional, default 0.5) Dominance ratio, values from 0 to 1. Determines how much of a sector a side must hold for bleeding tickets to start
bleedingAmount: Number - (Optional, default 3) Amount of tickets bled every step. Optional parameter
bleedingDelay: Object - (Optional, default 5) Delay in seconds between every bleeding step
Return Value:
Boolean

Examples

Example 1:
call BIS_fnc_bleedTickets;
Example 2:
[[WEST,EAST], 1, 1, 10] call BIS_fnc_bleedTickets;

Additional Information

See also:
BIS_fnc_addScriptedEventHandler BIS_fnc_respawnTickets

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

Notes

Bottom Section

Posted on September 29, 2014 - 19:58 (UTC)
Tryteyker-
The function calls on the scripted eventhandler (see BIS_fnc_addScriptedEventHandler) "dominantSideChanged" everytime a sector changes dominant side (this again depending on the value given to the function).