Bully-Board
Bully Modding Section => Modding Questions/Help => Modding Questions/Help Archives => Topic started by: denifarropilha on November 03, 2013, 09:40:25 PM
-
I started lua , and i need to change a character health, can someone help me with that?
-
PedSetHealth(PEDNAME,HEALTH)
200 = Jimmy's default health
-
:cool: you can also change it via pedstat.dat
-
PedSetHealth(PEDNAME,HEALTH)
200 = Jimmy's default health
don't forget about set the max health
PedSetMaxHealth(PEDNAME,HEALTH) :)
-
Would it be possible to make Jimmy able to have an almost infinite amount of health?
-
It's possible if u repeat the command with the repeat function.
-
or using a number like this one "999999999999999999999"
-
Or just the PlayerSetInvulnerable(true)
-
Yeah that can work too.
-
Wow , Thanks everyone.
-
To change Jimmy's health:
PlayerSetHealth(number)
Replace number with the amount of health u want.
To change a ped's health:
PedSetHealth(PedID, number)
replace PedID with name of ped