09.04.2017, 16:44
Hi,
Hmm. Getting a warning about "argument type mismatch (argument 1)", when i'm trying to get the cmdtext to timer function. Any ideas, what did i wrong?
Thanks a lot!
Hmm. Getting a warning about "argument type mismatch (argument 1)", when i'm trying to get the cmdtext to timer function. Any ideas, what did i wrong?
Код HTML:
.pwn(8450) : error 035: argument type mismatch (argument 1)
Код HTML:
cmd = strtok(cmdtext,idx);
if(!strcmp(cmd,"/attack",true))
{
new money[256];
money = strtok(cmdtext, idx);
if(!strlen(money))
{
SendClientMessage(playerid,COLOR_YELLOW,"* Use: /attack [money - "100000"]");
return 1;
}
// other things.
new IsAttackCountTimer = SetTimer("IsAttackTimer", 60000, false);
IsAttackTimer(money, gang, gplace, IsAttackCountTimer, playerid); // Line 8450
return 1;
}
Код HTML:
forward IsAttackTimer(money, gang, gplace, IsAttackCountTimer, playerid);
public IsAttackTimer(money, gang, gplace, IsAttackCountTimer, playerid)
{
new Message[410];
format(Message,sizeof(Message),"*{FFFFFF}[{FF0000}Attack{FFFFFF}] {FF0000}%s {FFFFFF}Gang is Attacking a {FF9900AA}%s for {33AA33AA}%s {FFFFFF} USD.",gang, gplace, money);
SendClientMessageToAll(0xB8860BAA,Message);
}

