Jump to content

missing something


tiesjan

Recommended Posts

hello, i'm missing a code or something in my script and i don't know what i need to enter there....

here it is

function showhelp(thePlayer) 
    showhelp=(????????)(thePlayer); 
    outputChatBox("/pm, send a personal message",thePlayer,255,0,0); 
    outputChatBox("/stations,set radio steams",thePlayer,255,0,0); 
    outputChatBox("/rules,a explanation of the rules and the punishments",thePlayer,255,0,0); 
    outputChatBox("/report report someone who breaks the rules ",thePlayer,255,0,0); 
    outputChatBox("/lock, lock your vehicle for others",thePlayer,255,0,0); 
end 
  
addCommandHandler("showhelp",help); 

its on the place with all the ?????? :lol:

Link to comment

What is this?

function showhelp(thePlayer) 
    outputChatBox("/pm, send a personal message",thePlayer,255,0,0) 
    outputChatBox("/stations,set radio steams",thePlayer,255,0,0) 
    outputChatBox("/rules,a explanation of the rules and the punishments",thePlayer,255,0,0) 
    outputChatBox("/report report someone who breaks the rules ",thePlayer,255,0,0) 
    outputChatBox("/lock, lock your vehicle for others",thePlayer,255,0,0) 
end 
  
addCommandHandler("showhelp",showhelp) 

No need for semi colons btw.

Link to comment
addCommandHandler ( string commandName, function handlerFunction, [bool restricted = false, bool caseSensitive = true] ) 

The first argument (the string) is the command.

second one is the function.

function showhelp(thePlayer) 
    outputChatBox("/pm, send a personal message",thePlayer,255,0,0) 
    outputChatBox("/stations,set radio steams",thePlayer,255,0,0) 
    outputChatBox("/rules,a explanation of the rules and the punishments",thePlayer,255,0,0) 
    outputChatBox("/report report someone who breaks the rules ",thePlayer,255,0,0) 
    outputChatBox("/lock, lock your vehicle for others",thePlayer,255,0,0) 
end 
  
addCommandHandler("help",showhelp) 

The command is /help now.

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