12.12.2014, 12:31
test it
pawn Код:
// This is a comment
// uncomment the line below if you want to write a filterscript
//#define FILTERSCRIPT
#include <a_samp>
new KillColorChange[MAX_PLAYERS]; // <-----------------
new Color[]={
"FF0000",
"FFFF00",
"FF8800",
"9F785A",
"8A7EA1"
};
public OnPlayerConnect(playerid)
{
KillColorChange[playerid] = SetTimerEx("ColorChange", 1000, true, "d", playerid);
return 1;
}
forward ColorChange(playerid);
public ColorChange(playerid)
{
new string[128];
format(string, sizeof(string), "{%s}•••••••••{%s}•••••••••{%s}•••••••••", random(sizeof(Color)), random(sizeof(Color)), random(sizeof(Color)));
SendClientMessage(playerid, -1, string);
return 1;
}
public OnPlayerSpawn(playerid)
{
KillTimer(KillColorChange[playerid]);
return 1;
}