CobbTheWarriorsRPG Posted May 16, 2015 Share Posted May 16, 2015 Well im making this, if somebody damage you and you are in los santos, you dont get damaged but doesnt work --Server Side function cancelDamage( attacker, weapon, bodypart, loss ) local location = getElementZoneName ( attacker, true ) if ( location == "Los Santos" ) then cancelEvent() end end addEventHandler ( "onPlayerDamage", root, cancelDamage )) Link to comment
ALw7sH Posted May 16, 2015 Share Posted May 16, 2015 (edited) "onPlayerDamage" can not be cancelled function cancelDamage( attacker ) local x,y,z = getElementPosition(attacker) local location = getZoneName ( x, y, z, true ) if ( location == "Los Santos" ) then cancelEvent() end end addEventHandler ( "onClientPlayerDamage", root, cancelDamage ) Edited May 16, 2015 by Guest Link to comment
CobbTheWarriorsRPG Posted May 16, 2015 Author Share Posted May 16, 2015 I will try it!, a lot of thanks Bro!!! Link to comment
Mr.unpredictable. Posted May 16, 2015 Share Posted May 16, 2015 So, what i need to do for make this? Just copy his code client side Link to comment
CobbTheWarriorsRPG Posted May 16, 2015 Author Share Posted May 16, 2015 A lot of thanks! it works Link to comment
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