addPlayerScores: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "\| *((\[\[.*\]\],? ?)+) * \}\}" to "|seealso= $1 }}") |
Lou Montana (talk | contribs) |
||
Line 32: | Line 32: | ||
<dt class="note">[[User:User Name|]]</dt> | <dt class="note">[[User:User Name|]]</dt> | ||
<dd class="note">This is an example note. It is true and verifiable, and contains a little code snippet. | <dd class="note">This is an example note. It is true and verifiable, and contains a little code snippet. | ||
<code>[[if]] ([[_this]] == anExample) [[then]] { [[hint]] "Leave it here for others to read"; };</code></dd> | <code>[[if]] ([[Magic Variables#this|_this]] == anExample) [[then]] { [[hint]] "Leave it here for others to read"; };</code></dd> | ||
--> | --> | ||
<!-- END Note Section --> | <!-- END Note Section --> |
Revision as of 13:18, 25 February 2021
Description
- Description:
- Description needed
- Groups:
- Object ManipulationMultiplayer
Syntax
- Syntax:
- Syntax needed
- Parameters:
- unit: Object
- values: Array - killsInfantry , killsSoft, killsArmor, killsAir, killed
- Return Value:
- Return value needed
Examples
- Example 1:
player addPlayerScores [0, 1, 0, 0, 1];
Additional Information
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 May 2, 2017 - 01:48 (UTC)
- Beno 83au
-
As this command will add the given number to a player's score, a little bit of thought needs to be given to friendly-fire if it is for something like a deathmatch or a FFA, due to friendly-fire incurring negative points. So to counter this just add 2 points every time a player kills a unit from the same side:
player addPlayerScores [2, 0, 0, 0, 0];
The 2 points will add 1 point to counter the negative friendly-fire point and 1 point to add correctly to the score.