Heal CMD
#3

use https://sampwiki.blast.hk/wiki/GetPlayerHealth
lets say you store the health in the variable x.
the player has 95 heal, so (x is a float...) x = 95.
the prize for healed 100 health is 1000$ so, for 1 hp it's 10$
now you do:
new prize = (100-floatround(x))*10);
we need to floatround so we don't get a float value, but a value with no dots.
Reply


Messages In This Thread
Heal CMD - by Michael[NBK] - 25.10.2011, 16:04
Re: Heal CMD - by Kingunit - 25.10.2011, 16:07
Re: Heal CMD - by Gamer_Z - 25.10.2011, 16:12
Re: Heal CMD - by =WoR=Varth - 25.10.2011, 16:14
Re: Heal CMD - by Michael[NBK] - 25.10.2011, 16:15
Re: Heal CMD - by =WoR=Varth - 25.10.2011, 16:29
Re: Heal CMD - by Michael[NBK] - 25.10.2011, 16:30
Re: Heal CMD - by =WoR=Varth - 25.10.2011, 16:33
Re: Heal CMD - by Michael[NBK] - 25.10.2011, 16:36

Forum Jump:


Users browsing this thread: 1 Guest(s)