addPlayerScores: Difference between revisions
Jump to navigation
Jump to search
Lou Montana (talk | contribs) m (Text replacement - "<code>([^ ]*)\[\[([a-zA-Z0-9_]+)\]\]([^ ]*)<\/code>" to "<code>$1$2$3</code>") |
Lou Montana (talk | contribs) m (Text replacement - ">Posted on May ([0-9]{1}), ([0-9]{4})" to ">Posted on $2-05-0$1") |
||
(3 intermediate revisions by the same user not shown) | |||
Line 19: | Line 19: | ||
|r1= [[Nothing]] | |r1= [[Nothing]] | ||
|x1= < | |x1= <sqf>player addPlayerScores [0, 1, 0, 0, 1];</sqf> | ||
|seealso= [[addScore]] [[addScoreSide]] [[getPlayerScores]] [[score]] [[scoreSide]] | |seealso= [[addScore]] [[addScoreSide]] [[getPlayerScores]] [[score]] [[scoreSide]] | ||
Line 28: | Line 28: | ||
<dt></dt> | <dt></dt> | ||
<dd class="notedate">Posted on | <dd class="notedate">Posted on 2017-05-02 - 01:48 (UTC)</dd> | ||
<dt class="note">[[User:Beno 83au|Beno 83au]]</dt> | <dt class="note">[[User:Beno 83au|Beno 83au]]</dt> | ||
<dd class="note"> | <dd class="note"> | ||
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: | 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: | ||
< | <sqf>player addPlayerScores [2, 0, 0, 0, 0];</sqf> | ||
The 2 points will add 1 point to counter the negative friendly-fire point and 1 point to add correctly to the score. | The 2 points will add 1 point to counter the negative friendly-fire point and 1 point to add correctly to the score. | ||
</dd> | </dd> | ||
</dl> | </dl> |
Latest revision as of 23:01, 13 May 2023
Description
- Description:
- MP server only: Adds player score.
- Groups:
- Object ManipulationMultiplayer
Syntax
- Syntax:
- unit addPlayerScores values
- Parameters:
- unit: Object
- values: Array - killsInfantry , killsSoft, killsArmor, killsAir, killed
- Return Value:
- Nothing
Examples
- Example 1:
Additional Information
- See also:
- addScore addScoreSide getPlayerScores score scoreSide
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 2017-05-02 - 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:
The 2 points will add 1 point to counter the negative friendly-fire point and 1 point to add correctly to the score.