SetPlayerLivesLeft

From Zandronum Wiki
Revision as of 16:32, 21 August 2016 by DrinkyBird (talk | contribs) (Created page with "{{ACSWarning}} int '''SetPlayerLivesLeft''' (int ''player'', int ''amount'') *''player'': the player to set the lives for. Setting ''player'' to ''PlayerNumber()'' will refe...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
This article documents a Zandronum-specific ACS feature which may not be supported by ZDoom and its other child ports.

int SetPlayerLivesLeft (int player, int amount)

  • player: the player to set the lives for. Setting player to PlayerNumber() will refer to the activator of the script.
  • amount: amount of lives left to set.

Returns 1 for success, 0 for failure (e.g. if the player does not exist). amount is the amount of lives the player has left after he dies. Lives are only reduced on respawning; to give a player 3 lives, an amount of 2 should be used. An amount of 0 indicates last life.