number of arguments does not match definition
#1

Hello when I try to compile I get this errors:
pawn Код:
C:\Users\Mohamad\Desktop\San Andreas Roleplay\gamemodes\rlgrp.pwn(48952) : warning 202: number of arguments does not match definition
C:\Users\Mohamad\Desktop\San Andreas Roleplay\gamemodes\rlgrp.pwn(48952) : warning 202: number of arguments does not match definition
C:\Users\Mohamad\Desktop\San Andreas Roleplay\gamemodes\rlgrp.pwn(48952) : warning 202: number of arguments does not match definition
I got in this line:
pawn Код:
KickWithMessage2(giveplayerid, COLOR_LIGHTRED, "AdmCmd: %s was kicked by %s, reason: %s", giveplayer, sendername, (result));
and the KickWithMessage2 stock is:
pawn Код:
stock KickWithMessage2(playerid, color, message[])
{
    SendClientMessageToAll(color, message);
    SetTimerEx("KickPublic2", 1000, 0, "d", playerid);
}
Reply
#2

You used arguments in KickWithMessage2 that are not defined in your stock. In order to insert a formated string use format function.

pawn Код:
new string[103];
format(string, sizeof(string), "AdmCmd: %s was kicked by %s, reason: %s", giveplayer, sendername, (result));

KickWithMessage2(giveplayerid, COLOR_LIGHTRED, string);
Reply
#3

thx bro
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)