warning 202: number of arguments does not match definition
#1

Can someone help me solve this out .. This is the line..
Код:
				Kick(playerid,"Car Swing");
		}
Reply
#2

The Kick() function doesn't have a 'reason' parameter. You have to use SendClientMessage to show a message before kicking the player.

HOWEVER, be warned: If you send a message then immediately Kick() the player, the message likely won't be seen (sent after they are kicked). To circumvent this, set a timer and kick them after 500ms or so.
Reply
#3

yh i did this but the player cant see the message is just saying Server closed the connection ..
edit: i also tried to do something with timer like
Код:
SetTimerEx("DelayedKick", 1000, false, "i", playerid);
Код:
forward DelayedKick(playerid);
public DelayedKick(playerid)
{
    Kick(playerid);
    return 1;
}
but it sends the message 5 times..
Reply
#4

PHP код:
forward KickPublic(playerid);
public 
KickPublic(playeridKick(playerid);
stock KickWithMessage(playeridcolormessage[])
{
    
SendClientMessage(playeridcolormessage);
    
SetTimerEx("KickPublic"1000false"i"playerid);     
}
 
KickWithMessage(playerid, -1"text"); 
from wiki samp
Reply
#5

yh its working thank you !
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)