28.02.2016, 20:36
Hi guys,
I'm trying to make a command work, but it seems like the parameters are not synced when using the command or whatsoever.
Basically, when using the command /startlottery, an admin is required to enter the following parameters by order: Minimum, Maximum, WinningTicket, Fee, Prize. If one of these or more wasn't typed in, it should print out to the admin on chat the following string:
[Minimum] [Maximum] [WinningTicket] [EntryFee] [Prize], SS:
![](http://i.imgur.com/NgmvCQw.png)
However, when the commend is used properly(when all parameters were inputted correctly), the command fail to operate(It doesn't actually work and start a lottery), it re-prints the same syntax msg, SS:
:
Here's the script of the Stack and the Command of the lottery creation, I hope you'll notice what's wrong in the script that makes it happen: http://pastebin.com/wTYrLJdS
P.S Here's the SCP stack:
I'll +REP the helpers, THANKS! <:
I'm trying to make a command work, but it seems like the parameters are not synced when using the command or whatsoever.
Basically, when using the command /startlottery, an admin is required to enter the following parameters by order: Minimum, Maximum, WinningTicket, Fee, Prize. If one of these or more wasn't typed in, it should print out to the admin on chat the following string:
[Minimum] [Maximum] [WinningTicket] [EntryFee] [Prize], SS:
![](http://i.imgur.com/NgmvCQw.png)
However, when the commend is used properly(when all parameters were inputted correctly), the command fail to operate(It doesn't actually work and start a lottery), it re-prints the same syntax msg, SS:
![](http://i.imgur.com/NgmvCQw.png)
Here's the script of the Stack and the Command of the lottery creation, I hope you'll notice what's wrong in the script that makes it happen: http://pastebin.com/wTYrLJdS
P.S Here's the SCP stack:
PHP код:
stock SCP(_id, _param[], _command[] = "")
{
format(iStr, sizeof(iStr), "{6a696a}[Command]: /%s {9c9a9c}%s", _command, _param);
return SendMessageToPlayer(_id, COLOR_LIGHTGREY, iStr, 128);
}