User Tools

Site Tools


revive_character

Differences

This shows you the differences between two versions of the page.

Link to this comparison view

Next revision
Previous revision
revive_character [2020/02/04 11:32] – created justinrevive_character [2021/04/21 18:47] (current) justin
Line 11: Line 11:
 ^Argument^Description^Type^Required^ ^Argument^Description^Type^Required^
 |character|Character that will be revived.|[[Entity]]|Yes| |character|Character that will be revived.|[[Entity]]|Yes|
-|heal_amount|Amount of health to restore after being revived.|[[Decimal]]|Yes|+|heal_amount|Amount of health to restore after being revived.|[[Number]]|Yes|
  
 ====Example:==== ====Example:====
-<code lua+<code bauxite
-revive_character(player, player.stat["max_hp"] / 2)+revive_character(player, player.stat["max_hp"] / 2);
 </code> </code>
 //Results:// The player is brought back to life with half of their maximum health. //Results:// The player is brought back to life with half of their maximum health.
  
 <WRAP center round tip 100%> <WRAP center round tip 100%>
-Use the **Revive Character** function in the "Player is Defeated" global event script to revive the player character and return them to a house or base.+Use the **Revive Character** function in your "Player is Defeated" global event script to revive the player character and return them to a house or base.
 </WRAP> </WRAP>
  
revive_character.1580844745.txt.gz · Last modified: 2020/02/04 11:32 by justin