CMD:derby(playerid, params[])
{
My_Interior[playerid] = 15;
new string[128], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
format(string, sizeof(string), "{6666FF}(/derby) {00CCFF}%s {6666FF}Teleport Shod Be Derby P1", pName);
SendClientMessageToAll(0xFFFFFFFF, string);
SendClientMessage(playerid,COLOR_RED,"Baraye Khoroj Az Derby Bezanid /leavederby");
GameTextForPlayer(playerid,"~y~Khoshoomadi Be ~n~~b~Derby Deathmatch", 2000, 3);
SetPlayerPos(playerid, -1362.5800, 931.3489, 1035.9734);
SetPlayerInterior(playerid, 15);
SetPlayerVirtualWorld(playerid, 15);
bloodring_id[playerid] = CreateVehicle(504, -1362.5800, 931.3489, 1035.9734, 0.0, 0, 0, -1);
LinkVehicleToInterior(bloodring_id[playerid], 15);
SetVehicleVirtualWorld(bloodring_id[playerid], 15);
PutPlayerInVehicle(playerid, bloodring_id[playerid], 0);
TogglePlayerControllable(playerid, 0);
SetTimerEx("unfreeze",10000,false,"i",playerid);
SetPlayerHealth(playerid, 100);
DerbyNumber = 1;
return 1;
}
forward unfreeze(playerid);
public unfreeze(playerid)
{
SetTimerEx("Count",100,false,"ii",playerid,3);
return 1;
}
forward Count(playerid,time);
public Count(playerid,time)
{
if(time != 0)
{
new string[5];
format(string, sizeof(string), "%d", time);
GameTextForPlayer(playerid, string, 1000, 5);
}
else
{
GameTextForPlayer(playerid, "GO!", 2500, 3);
TogglePlayerControllable(playerid, 1);
}
return 1;
}
forward unfreeze(playerid);
public unfreeze(playerid)
{
SetTimer("Three", 1000, 0);
SetTimer("Two", 2000, 0);
SetTimer("One", 3000, 0);
SetTimer("Go", 4000, 0);
return 1;
}
forward Three();
public Three()
{
SendClientMessageToAllEx(COLOR_LIGHTBLUE, "3");
return 1;
}
forward Two();
public Two()
{
SendClientMessageToAllEx(COLOR_LIGHTBLUE, "2");
return 1;
}
forward One();
public One()
{
SendClientMessageToAllEx(COLOR_LIGHTBLUE, "1");
return 1;
}
forward Go();
public Go()
{
SendClientMessageToAllEx(COLOR_LIGHTBLUE, "Go!");
return 1;
}
new TimerUnfreezeAfterC;
CMD:derby(playerid, params[])
{
My_Interior[playerid] = 15;
new string[128], pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, MAX_PLAYER_NAME);
format(string, sizeof(string), "{6666FF}(/derby) {00CCFF}%s {6666FF}Teleport Shod Be Derby P1", pName);
SendClientMessageToAll(0xFFFFFFFF, string);
SendClientMessage(playerid,COLOR_RED,"Baraye Khoroj Az Derby Bezanid /leavederby");
GameTextForPlayer(playerid,"~y~Khoshoomadi Be ~n~~b~Derby Deathmatch", 2000, 3);
SetPlayerPos(playerid, -1362.5800, 931.3489, 1035.9734);
SetPlayerInterior(playerid, 15);
SetPlayerVirtualWorld(playerid, 15);
bloodring_id[playerid] = CreateVehicle(504, -1362.5800, 931.3489, 1035.9734, 0.0, 0, 0, -1);
LinkVehicleToInterior(bloodring_id[playerid], 15);
SetVehicleVirtualWorld(bloodring_id[playerid], 15);
PutPlayerInVehicle(playerid, bloodring_id[playerid], 0);
TogglePlayerControllable(playerid, 0);
TimerUnfreezeAfterC = SetTimerEx("unfreezeCount", 1000, false, "ii", playerid, 10);
SetPlayerHealth(playerid, 100);
DerbyNumber = 1;
return 1;
}
forward unfreezeCount(playerid, time);
public unfreezeCount(playerid, time)
{
if((time -= 1) > 0)
{
TimerUnfreezeAfterC = SetTimerEx("unfreezeCount", 1000, false, "ii", playerid, time);
new string[5];
format(string, sizeof(string), "%d", time);
GameTextForPlayer(playerid, string, 1000, 5);
}
else
{
GameTextForPlayer(playerid, "GO!", 2500, 3);
TogglePlayerControllable(playerid, 1);
KillTimer(TimerUnfreezeAfterC);
}
return 1;
}
|
NealPeteros i writed your codes don't compiled
F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6110) : error 017: undefined symbol "SendClientMessageAllEx" F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6117) : error 017: undefined symbol "SendClientMessageToAllEx" F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6124) : error 017: undefined symbol "SendClientMessageToAllEx" F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6125) : warning 217: loose indentation F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6131) : error 017: undefined symbol "SendClientMessageToAllEx" F:\sa-mp 3z Alimash\IranianDeathMatch\gamemodes\DeathMatch.pwn (6132) : warning 217: loose indentation Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase 4 Errors. |
forward unfreezeCount(playerid, time);
public unfreezeCount(playerid, time)
{
if((time -= 1) > 0)
{
TimerUnfreezeAfterC = SetTimerEx("unfreezeCount", 1000, false, "ii", playerid, time);
if(time <= 3)
{
new string[5];
format(string, sizeof(string), "%d", time);
GameTextForPlayer(playerid, string, 1000, 5);
}
}
else
{
GameTextForPlayer(playerid, "GO!", 2500, 3);
TogglePlayerControllable(playerid, 1);
KillTimer(TimerUnfreezeAfterC);
}
return 1;
}