01.08.2010, 11:40
thank you for help but check this
i used this:
but when the player disconnects? or when the game mode restarts? how can i save the HasLeaderFBI?
i used this:
pawn Код:
new HasLeaderFBI;
dcmd_giveleaderfbi(playerid,params[])
{
new target,string[120];
if(HasLeaderFBI == 1) return SendClientMessage(playerid,red,"The F.B.I. has allready a leader!");
if(!IsPlayerAdmin(playerid)) return SendClientMessage(playerid,red,"You are NOT Authorized to use this command!");
if(sscanf(params,"d",target)) return SendClientMessage(playerid,red,"USAGE: /giveleaderfbi [ID]");
if(((PlayerInfo[playerid][LeaderFBI] == 1) || (PlayerInfo[playerid][LeaderVLA] == 1)) return SendClientMessage(playerid,red,"Player is allready leader of a team/family!");
format(string,sizeof(string),"Congratz, you are now the Federal Bureau of Investigation Leader!");
SendClientMessage(target,red,"------------------------");
SendClientMessage(target,lightblue,string);
SendClientMessage(target,red,"------------------------");
PlayerInfo[playerid][LeaderFBI] = 1;
HasLeaderFBI = 1;
return 1;
}