Jump to content

Disable /kill command


igthomas

Recommended Posts

This function removes a command handler, that is one that has been added using addCommandHandler. This function can only remove command handlers that were added by the resource that it is called in.

so if wiki is not wrong then this way won't work

removeCommandHandler("kill") 

this one will work

addEventHandler("onPlayerCommand", root, 
function(cmd) 
     if cmd == "kill" then 
          cancelEvent() 
     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...