Jump to content

zombie blips


TorNix~|nR

Recommended Posts

Hi everyone, I have a zombie blips script! but I have little problem, I made that when Zombie is dead, the blip destroyed!

and it do not work can anyone help please?

 blips = { } 
  
addEvent ( "onZombieSpawn", true ) 
addEventHandler ( "onZombieSpawn", root, 
function ( ) 
for _, v in ipairs ( getElementsByType ( "ped" ) ) do 
if getElementData ( v, "zombie" ) then 
if ( not blips [ v ] ) then 
blips [ v ] = createBlipAttachedTo ( v, 0, 1, 255, 0, 0, 150, 0, 500) 
end 
end 
end 
end 
) 
  
addEvent ( "onPedWasted", true ) 
addEventHandler ( "onPedWasted", root, 
function ( ) 
if ( isElement ( blips [ source ] ) ) then 
destroyElement ( blips [ source ] ) 
end 
end 
)  

Link to comment

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 account

Sign in

Already have an account? Sign in here.

Sign In Now
  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...