Jump to content
  • 0

Disable a command to players


TheBite

Question

Recommended Posts

  • 0
oh, it's because all those are bind to a command, like talking in the chat via '/say'.

ok, everything works, but if you're trying to not let the player use the superman command then you would need to go to the actual script with the superman command.

I'm tryed to paste this:

Thanks.

Try this:

addEventHandler ('onPlayerCommand', root, function (cmd) 
    outputChatBox(cmd,source) 
    if cmd:lower() ~= 'superman' then return end 
    outputChatBox("superman",source) 
    if not isGuestAccount ( getPlayerAccount ( source ) ) then return end 
    cancelEvent() 
end) 

in the admintag resource (server.lua) (why i think this resource is the problem) but nothing...

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