Notorious^ Posted October 25, 2018 Share Posted October 25, 2018 Hi all ı want add explosion to helmet zombie.his skin number 44.ı tried with createExplosion (x,y,z, 0) but its not worked.its more important for us please help.what can ı do ? thanks .. function zombiedamaged ( attacker, weapon, bodypart ) if getElementType ( source ) == "ped" then if (getElementData (source, "zombie") == true) then if ( bodypart == 9 ) then helmeted = "no" local zskin = getElementModel ( source ) for k, skin in pairs( helmetzombies ) do if skin == zskin then helmeted = "yes" end end if helmeted == "no" then triggerServerEvent ("headboom", source, source, attacker, weapon, bodypart ) end end end end end addEventHandler ( "onClientPedDamage", getRootElement(), zombiedamaged ) Link to comment
Dzsozi (h03) Posted October 25, 2018 Share Posted October 25, 2018 Try changing pairs to ipairs. If I am correct pairs is for table keys that is a string like [“1”] and ipairs is for undefined table keys or [1]. So if you have your helmetZombies table defined something like this helmetZombies = {44, 45, 46} --etc then you should use ipairs. Link to comment
AkqFox Posted February 8, 2020 Share Posted February 8, 2020 (edited) On 25/10/2018 at 10:35, Notorious^ said: Hello, once I have created the zombie bomb script it says "triggerServerside event headexplosion, but event is not added serverside" in / debugscript 3 Do you know what I can do? Edited February 8, 2020 by AkqFox Link to comment
NeXuS™ Posted February 8, 2020 Share Posted February 8, 2020 This post was created back in 2018, why was this bumped? Do you still require help @Notorious^? 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