09.02.2008, 21:48
Hi Guys Again xD I made This Commandґs
Top
Load Fire Work Command
Shoot Fire Work
Under all
But when i do /fire I hear BOOM! And it Fly a little And deletes but i donґt see the Explosion I want like a timer But dont know how to make it Like /Fire W8 1 sec BOOM And the fire work get deleted AND Btw
AND Btw: And when i type /fire It stands Unknown command and /load he same but it work perfectly
And i have other commands like that to that work but i get unknown command whats wrong with that?
Top
pawn Код:
new Fire;
new FireLock[MAX_PLAYERS];
new LoadLock[MAX_PLAYERS];
forward FireUnlock(playerid);
forward LoadUnlock(playerid);
pawn Код:
if(strcmp(cmdtext, "/load", true)==0)
{
if(LoadLock[playerid] == 0)
{
SendClientMessage(playerid, COLOR_YELLOW, "FireWork Was Succful Placed");
GameTextForPlayer(playerid,"~r~FireWork ~y~Was ~g~Succful Placed",2500,5);
Fire = CreateObject(3786, 1525.999512, -1346.289795, 330.407990, 346.2490, 90.2408, 71.1785);
LoadLock[playerid] = 1;
SetTimerEx("LoadUnlock", 120000, 0, "i", playerid);
}
else if(LoadLock[playerid] == 1)
SendClientMessage(playerid, COLOR_RED, "Omg U Can ONLY Load FireWorks every 2MIN!");
{
return 0;
}
}
pawn Код:
if(strcmp(cmdtext, "/fire", true)==0)
{
if(FireLock[playerid] == 0)
{
SendClientMessage(playerid, COLOR_YELLOW, "FireWork Was Succful Shooted");
GameTextForPlayer(playerid,"~r~FireWork ~y~Was ~g~Succful Shooted",2500,5);
MoveObject(Fire, 1526.262329, -1346.088379, 402.466187,9.0);
CreateExplosion(1526.262329, -1346.088379, 402.466187,6,300);
DestroyObject(Fire);
FireLock[playerid] = 1;
SetTimerEx("FireUnlock", 120000, 0, "i", playerid);
}
else if(FireLock[playerid] == 1)
SendClientMessage(playerid, COLOR_RED, "Omg U Can ONLY Shoot FireWorks every 2MIN!");
{
return 0;
}
}
pawn Код:
public FireUnlock(playerid)
{
FireLock[playerid] = 0;
}
pawn Код:
public LoadUnlock(playerid)
{
LoadLock[playerid] = 0;
}
AND Btw: And when i type /fire It stands Unknown command and /load he same but it work perfectly
And i have other commands like that to that work but i get unknown command whats wrong with that?