Hallo.
Ich wollte fragen ob man ein /gov System für jede Fraktion machen kann wie zbs wenn ich La Cosa Nostra bin und /gov mache {Muss mind. Rank 5 sein]
___La Cosa Nostra___
RankName (Mein Name) : Die La Cosa Nostra sucht noch 5Member Ab Lvl 3+Ts Pflicht
Und das für jede Fraktion weil bei mir steht das hier:
//----------------------------------[government]-----------------------------------------------
if(strcmp(cmd, "/government", true) == 0 || strcmp(cmd, "/gov", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(gTeam[playerid] != 2 && !IsACop(playerid) && !IsPlayerInFrac(playerid, 7)&& !IsPlayerInFrac(playerid, 24)&& !IsPlayerInFrac(playerid, 11))
{
SendClientMessage(playerid, COLOR_GREY, " Du bist kein Polizist !");
return 1;
}
if(PlayerInfo[playerid][pRank] < 5)
{
SendClientMessage(playerid, COLOR_GREY, " Du brauchst Rang 5 !");
return 1;
}
GetPlayerName(playerid, sendername, sizeof(sendername));
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[64];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_GRAD2, "Benutze: (/gov)ernment [text]");
return 1;
}
SendClientMessageToAll(COLOR_WHITE, "|___________ Regierungsnachrichten ___________|");
if(PlayerInfo[playerid][pLeader] == 7)
{
format(string, sizeof(string), "Bundespräsident %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pMember] == 7 && PlayerInfo[playerid][pRank] == 11)
{
format(string, sizeof(string), "Bundeskanzler %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pMember] == 7 && PlayerInfo[playerid][pRank] >= 7)
{
format(string, sizeof(string), "Minister %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pMember] == 7 && PlayerInfo[playerid][pRank] == 6)
{
format(string, sizeof(string), "Geheimdienst Leiter %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pLeader] == 11 || PlayerInfo[playerid][pLeader] == 11)
{
format(string, sizeof(string), "Fahrlehrer %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pLeader] == 1)
{
format(string, sizeof(string), "Polizei Pressesprecher %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pLeader] == 24 || PlayerInfo[playerid][pMember] == 24)
{
format(string, sizeof(string), "Ordnungsamtler %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pLeader] == 2)
{
format(string, sizeof(string), "Director of Secret Service %s: %s", sendername, result);
}
else if(PlayerInfo[playerid][pLeader] == 3)
{
format(string, sizeof(string), "General %s: %s", sendername, result);
}
else format(string, sizeof(string), "Beamter %s: %s", sendername, result);
SendClientMessageToAll(COLOR_DBLUE, string);
}
return 1;
}