BTNX Posted July 1, 2013 Posted July 1, 2013 I'm not sure if this is the right section for this because I'm not sure if this is a source question or what. I need to add an @command "@support" and all it does is open a script... Similar to whisper system Quote
BTNX Posted July 1, 2013 Author Posted July 1, 2013 Ow... Thanks again... Btw, how would you use parameters? Quote
Patskie Posted July 1, 2013 Posted July 1, 2013 OnInit: bindatcmd("<any command you want to use>",strnpcinfo(3)+ "::OnExe"); end; OnExe: // Execute code when the binded command was triggered by the user 2 Quote
BTNX Posted July 1, 2013 Author Posted July 1, 2013 Thanks for the reply... Is it possible to use parameters with this? Quote
Euphy Posted July 1, 2013 Posted July 1, 2013 Please read the Wiki page I linked... .@atcmd_numparameters: The number of parameters defined. .@atcmd_parameters$[]: Array containing the given parameters, starting from an index of 0. Quote
DeadlySilence Posted July 1, 2013 Posted July 1, 2013 .@atcmd_command$ = The name of the @command used. .@atcmd_parameters$[] = Array containing the given parameters, starting from an index of 0. .@atcmd_numparameters = The number of parameters defined. You can get command parameters with .@atcmd_parameters$[index]. So, @test a b would result in this: .@atcmd_command$ = @test .@atcmd_parameters$[0] = a .@atcmd_parameters$[1] = b .@atcmd_numparameters = 2 1 Quote
BTNX Posted July 2, 2013 Author Posted July 2, 2013 @Euphy... I'm aware of the link... I actually knew about that page, I just didn't understand it before. Thanks for the replies everyone... Quote
Question
BTNX
I'm not sure if this is the right section for this because I'm not sure if this is a source question or what.
I need to add an @command "@support" and all it does is open a script... Similar to whisper system
7 answers to this question
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.