SA-MP Forums Archive
[Help] - 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)
+--- Thread: [Help] (/showthread.php?tid=280976)



[Help] - Trol_Patrol - 03.09.2011

nvm..........


Re: [Help] - Wesley221 - 03.09.2011

pawn Код:
forward SendAdminMessage(color, string[]);
public SendAdminMessage(color, string[])
{
    if(GetPlayerSkin(i) != 0)
    {
        SendClientMessage(i, color, string);
    }
}



Re: [Help] - Trol_Patrol - 03.09.2011

It gives me other error:
rror 017: undefined symbol "i"


AW: [Help] - Joshua_Turnerz - 03.09.2011

In your function...where in hell do you suppose its going to get 'playerid' from

Quote:

public SendAdminMessage(color, string[])//<-- Function Call
{
if(GetPlayerSkin(i) != 0)//<-- its not going to get 'i' either !
{
SendClientMessage(playerid, color, string); //<-- so you KNOW its not going to have 'PLAYERID' either..
}
}

Perhaps if you tried to loop through all players ... ForEach( or for(new

try searching around for those, and you will find your problem.


Re: [Help] - =WoR=Varth - 03.09.2011

pawn Код:
for(new i;i<MAX_PLAYERS;i++)
    {
        if(GetPlayerSkin(i) != 0)
        {
            SendClientMessage(i, color, string);
        }
    }



AW: [Help] - Joshua_Turnerz - 03.09.2011

no offense bro... but if you 'Give' these people the answers .. they are NEVER going to learn, they are literally going to copy and paste every little thing, and then royally screw themselves over later on down the run...

a little 'searching' is going to help them 'appreciate' the knowledge.


Re: AW: [Help] - =WoR=Varth - 03.09.2011

Quote:
Originally Posted by Joshua_Turnerz
Посмотреть сообщение
no offense bro... but if you 'Give' these people the answers .. they are NEVER going to learn, they are literally going to copy and paste every little thing, and then royally screw themselves over later on down the run...

a little 'searching' is going to help them 'appreciate' the knowledge.
Not always.