SA-MP Forums Archive
(HELP)SendClientMessage - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (https://sampforum.blast.hk/forumdisplay.php?fid=12)
+---- Forum: Help Archive (https://sampforum.blast.hk/forumdisplay.php?fid=89)
+---- Thread: (HELP)SendClientMessage (/showthread.php?tid=269366)



(HELP)SendClientMessage - spaty2 - 16.07.2011

Can someone tell me why this is not work?
pawn Код:
public OnFilterScriptInit()
{
    if SetTimer("AFKKicker", 60000, 1)
    SendClientMessage(i,0xAA3333AA,"You are AFK now");
    return 1;
I got this errors
Quote:

error 001: expected token: "*then", but found "-identifier-"
error 017: undefined symbol "i"

I need that will say me after one minute, im afk


Re: (HELP)SendClientMessage - Lorenc_ - 16.07.2011

pawn Код:
public OnFilterScriptInit()
{
    for(new i; i<MAX_PLAYERS; i++) {
        SendClientMessage(i,0xAA3333AA,"You are AFK now");
    }
    SetTimer("AFKKicker", 60000, 1);
    return 1;
}



Re: (HELP)SendClientMessage - spaty2 - 16.07.2011

Thx


Re: (HELP)SendClientMessage - MoroDan - 16.07.2011

OnFilterScriptInit() !? Wtf ?


Re: (HELP)SendClientMessage - spaty2 - 16.07.2011

But i think it don't work in game


Re: (HELP)SendClientMessage - freshOrange - 16.07.2011

Place it under OnPlayerSpawn or OnPlayerConnect