Jump to content

help with effects


MAB

Recommended Posts

attempt to call global 'createEffect'

function start(player) 
         if ( hasObjectPermissionTo ( player, "function.kickPlayer", false ) ) then 
              showCursor(player,true,true) 
              addEventHandler("onPlayerClick",player,explosion) 
            end 
end 
addCommandHandler("ilovetoburn",start) 
  
function explosion (button,state,element,x,y,z) 
         if (button == "left" and state == "down") then 
               createExplosion (x,y,z,1) 
               createEffect ("teargas",x,y,z) 
        end 
    end 
  
function stop(player) 
         if ( hasObjectPermissionTo ( player, "function.kickPlayer", false ) ) then 
              showCursor(player,false,false) 
              removeEventHandler("onPlayerClick",player,explosion) 
            end 
end 
addCommandHandler("ihatetoburn",stop) 

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...