aintaro Posted April 19, 2014 Posted April 19, 2014 hello guys, I was wondering how can you make a ped unkillable? thanks in advance, Aintaro
Castillo Posted April 19, 2014 Posted April 19, 2014 You must cancel the onClientPedDamage event. You can also use my "extra_health" resource which has an invulnerable function. https://community.multitheftauto.com/in ... ls&id=5195
Mr_Moose Posted April 19, 2014 Posted April 19, 2014 I think you need onClientPlayerStealthKill event too since stealth kills might not trigger onClientPlayerDamage. Not sure about it thought.
Mr_Moose Posted April 19, 2014 Posted April 19, 2014 It says ped in the wiki and I managed to cancel it for peds as well in v1.3.5. Unless if it's changed recently it should work for peds too.
Castillo Posted April 19, 2014 Posted April 19, 2014 Oh, I don't know if they added that recently, last time I checked I wasn't able to cancel it.
Mr_Moose Posted April 19, 2014 Posted April 19, 2014 Could probably be like that, most functions and events which is originally made for single elements but applies the same properties to their source elements merging and creates new functions like setElementHealth() for instance, which used to be setPlayerHealth(), setVehicleHealth() (If I remember correct), etc.. Anyway I had this issue in my store robbery script not long ago which also was supposed to protect peds from getting killed.
Recommended Posts
Create an account or sign in to comment
You need to be a member in order to leave a comment
Create an account
Sign up for a new account in our community. It's easy!
Register a new accountSign in
Already have an account? Sign in here.
Sign In Now