24.09.2010, 22:46
(
Последний раз редактировалось Tee; 24.09.2010 в 22:56.
)
Next time use and put your code in.
Here is it:
You can use:
Here is it:
pawn Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
if(strcmp(cmdtext, "/pgate", true)==0)
{
if(IsPlayerAdmin(playerid))return SendClientMessage(playerid,0xFF0000FF,"You are not an admin");
SendClientMessage(playerid, COLOR_BBLUE, "Gate opening ... close automaticaly!");
MoveObject(pgate, 829.798,-2067.799,8.735, 1.5);
SetTimer("pgatet", 5000, 0);
return 1;
}
if(strcmp(cmdtext, "/g1", true)==0)
{
if(IsPlayerAdmin(playerid))return SendClientMessage(playerid,0xFF0000FF,"You are not an admin");
SendClientMessage(playerid, COLOR_BBLUE, "Garage [1] opening ... close automaticaly!");
MoveObject(g1gate, 841.935,-2077.986,7.885, 1.5);
SetTimer("g1gatet", 10000, 0);
return 1;
}
if(strcmp(cmdtext, "/g2", true)==0)
{
if(IsPlayerAdmin(playerid))return SendClientMessage(playerid,0xFF0000FF,"You are not an admin");
SendClientMessage(playerid, COLOR_BBLUE, "Garage [2] opening ... close automaticaly!");
MoveObject(g2gate, 854.147,-2078.010,7.844, 1.5);
SetTimer("g2gatet", 10000, 0);
return 1;
}
pawn Код:
IsPlayerAdmin(playerid);