- 0
Problema OnPlayerCommandText
-
Similar Content
-
- 2 answers
- 823 views
-
Problema turf
By Soryn.,
- 3 answers
- 444 views
-
- 0 replies
- 185 views
-
- 2 replies
- 349 views
-
- 2 replies
- 113 views
-
-
Recently Browsing 0 members
- No registered users viewing this page.
Question
Bladex
Poi am adaugat
[pawn] return SendClientMessage(playerid, COLOR_UNEMD, "ERROR: Unknown Command!");
}[/pawn]
asa nam nici o problema cu asta functioneaza totul bine pana acum cand am creeat o comanda din care m-am inspirat de undeva si imi pare de fiecare data cand comanda e utilizata ERROR:Unknown Command! dupa care comanda executa scriptul. As dorii ajutor sa nu imi mai apara ERROR:Unknown Command! cand folosesc comanda!
Comanda:
[pawn] if(strcmp(cmd,"/attack",true)==0)
{
if(PlayerInfo[playerid][pLider] == 4 || PlayerInfo[playerid][pLider] == 5 || PlayerInfo[playerid][pLider] == 6)
{
for(new z=0; z<sizeof(ZoneInfo); z++)
{
if(IsPlayerInZone(playerid,z))
{
if(takezone == 1)
{
SendClientMessage(playerid, COLOR_GRAD1, " The Gang war is allready started");
}
else
{
new leader[30];
format(leader,sizeof(leader),"%s" ,ZoneInfo[GetPlayerZone(playerid)][zOwner]);
#define min 30000
GetPlayerName(playerid, sendername, sizeof(sendername));
if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 12 && PlayerInfo[playerid][pLider] == 4)
{
SendClientMessage(playerid, COLOR_GRAD1, " Error. You are in an area of your");
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 13 && PlayerInfo[playerid][pLider] == 5)
{
SendClientMessage(playerid, COLOR_GRAD1, " Error. You are in an area of your");
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 14 && PlayerInfo[playerid][pLider] == 6)
{
SendClientMessage(playerid, COLOR_GRAD1, " Error. You are in an area of your");
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 15 && PlayerInfo[playerid][pLider] == 15)
{
SendClientMessage(playerid, COLOR_GRAD1, " Error. You are in an area of your");
}
if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 12 && PlayerInfo[playerid][pLider] == 5)
{
if(cooldownblls == 0)
{
format(string, sizeof(string), " The Sindacco Family Leader %s is attacking a territory held by The Forelli Family!",sendername,leader);
SendClientMessageToAll(-1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timerbllsgst=SetTimer("bllsgst",min*20,0);
bllsvsgst = 1;
cooldownblls = 21600;
}
else
{
format(string, 128, " The Sindacco Family has cooldown. Must wait 6 hours (%d seconds).",cooldownblls);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 12 && PlayerInfo[playerid][pLider] == 6)
{
if(cooldownlsv == 0)
{
format(string, sizeof(string), " The Leone Family Leader %s is attacking a territory held by The Forelli Family!",sendername,leader);
SendClientMessageToAll( -1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timerlsvgst=SetTimer("lsvgst",min*20,0);
lsvvsgst = 1;
cooldownlsv = 21600;
}
else
{
format(string, 128, "The Leone Family has cooldown. Must wait 6 hours (%d seconds).",cooldownlsv);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 13 && PlayerInfo[playerid][pLider] == 4)
{
if(cooldowngst == 0)
{
format(string, sizeof(string), "The Forelli Family Leader %s is attacking a territory held by The Sindacco Family!",sendername,leader);
SendClientMessageToAll( -1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timergstblls=SetTimer("gstblls",min*20,0);
cooldowngst = 21600;
bllsvsgst = 1;
}
else
{
format(string, 128, "The Forelli Family has cooldown. Must wait 6 hours (%d seconds).",cooldowngst);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 13 && PlayerInfo[playerid][pLider] == 6)
{
if(cooldownblls == 0)
{
format(string, sizeof(string), "The Leone Family Leader %s is attacking a territory held by The Sindacco Family!",sendername,leader);
SendClientMessageToAll( -1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timerlsvblls=SetTimer("lsvblls",min*20,0);
for(new i=0; i<MAX_PLAYERS; i++)
{
if(PlayerInfo[pLider] == 14)
{
cooldownlsv = 21600;
}
}
lsvvsblls=1;
}
else
{
format(string, 128, " The Leone Family has cooldown. Must wait 6 hours (%d seconds).",cooldownlsv);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 14 && PlayerInfo[playerid][pLider] == 4)
{
if(cooldowngst == 0)
{
format(string, sizeof(string), "The Forelli Family Leader %s is attacking a territory held by The Leone Family!",sendername,leader);
SendClientMessageToAll( -1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timergstlsv=SetTimer("gstlsv",min*20,0);
cooldowngst = 21600;
lsvvsgst = 1;
}
else
{
format(string, 128, "The Forelli Family has cooldown. Must wait 6 hours (%d seconds).",cooldowngst);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
else if(ZoneInfo[GetPlayerZone(playerid)][zTeam] == 14 && PlayerInfo[playerid][pLider] == 5)
{
if(cooldownlsv == 0)
{
format(string, sizeof(string), "The Sindacco Family Leader %s is attacking a territory held by The Leone Family!",sendername,leader);
SendClientMessageToAll( -1, string);
takezone=1;
ZoneInfo[z][zTakeOn] = 1;
GangZoneFlashForAll(GetPlayerZone(playerid), COLOR_RED);
timerbllslsv=SetTimer("bllslsv",min*20,0);
for(new i=0; i<MAX_PLAYERS; i++)
{
if(PlayerInfo[pLider] == 5)
{
cooldownblls = 21600;
}
}
lsvvsblls=1;
}
else
{
format(string, 128, "The Sindacco Family has cooldown. Must wait 6 hours (%d seconds).",cooldownlsv);
SendClientMessage(playerid,COLOR_GREY, string);
}
}
}
}
}
}
else SCM(playerid, COLOR_GRAD1, " You are not a Gang Leader!");
}[/pawn]
Link to comment
Share on other sites
1 answer to this question
Recommended Posts