new bopeativado[MAX_PLAYERS]; |
bopeativado[playerid] = 0; |
if(strcmp(cmd, "/ativarbope", true) == 0) { if(IsPlayerConnected(playerid)) { if(bopeativado[playerid] == 1) { SendClientMessage(playerid, COLOR_GREY, "O BOPE jб estб ativado!"); return 1; } if(PlayerInfo[playerid][pLider] == 1) { bopeativado[playerid] == 1; SendClientMessage(playerid,COLOR_GREY,"Vocк ativou o BOPE."); return 1; } } } return 1; } if(strcmp(cmd, "/desativarbope", true) == 0) { if(IsPlayerConnected(playerid)) { if(bopeativado[playerid] == 0) { SendClientMessage(playerid, COLOR_GREY, "O BOPE jб estб desativado!"); return 1; } if(PlayerInfo[playerid][pLider] == 1) { bopeativado[playerid] == 0; SendClientMessage(playerid,COLOR_GREY,"Vocк desativou o BOPE."); return 1; } } } return 1; } |
if(strcmp(cmd, "/ifbope", true) == 0) { if(IsPlayerConnected(playerid)) { if(bopeativado[playerid] == 0) { SendClientMessage(playerid, COLOR_GREY, "O equipamento do BOPE nгo estб ativado!"); return 1; } if(PlayerToPoint(10.0, playerid,255.1426,75.9933,1003.6406)) { if(PlayerInfo[playerid][pMembro] == 1 || PlayerInfo[playerid][pLider] == 1) { ResetPlayerWeapons(playerid); GivePlayerWeapon(playerid, 25, 80); GivePlayerWeapon(playerid, 31, 200); GivePlayerWeapon(playerid, 17, 10); SetPlayerArmour(playerid, 100); GetPlayerName(playerid,sendername,sizeof(sendernam e)); format(string, sizeof(string), " O oficial %s pegou seu equipamento do BOPE.", sendername, playerid); ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPL E,COLOR_PURPLE); return 1; } } } return 1; } if(strcmp(cmd, "/sniperbope", true) == 0) { if(IsPlayerConnected(playerid)) { if(bopeativado[playerid] == 0) { SendClientMessage(playerid, COLOR_GREY, "O equipamento do BOPE nгo estб ativado!"); return 1; } if(PlayerToPoint(10.0, playerid,255.1426,75.9933,1003.6406)) { if(PlayerInfo[playerid][pMembro] == 1 && PlayerInfo[playerid][pCargo] < 5 || PlayerInfo[playerid][pLider] == 1 && PlayerInfo[playerid][pCargo] < 5) { ResetPlayerWeapons(playerid); GivePlayerWeapon(playerid, 24, 30); GivePlayerWeapon(playerid, 34, 50); GivePlayerWeapon(playerid, 17, 10); SetPlayerArmour(playerid, 100); GetPlayerName(playerid,sendername,sizeof(sendernam e)); format(string, sizeof(string), " O oficial %s pegou seu equipamento do BOPE SNIPER.", sendername, playerid); ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPL E,COLOR_PURPLE); return 1; } } } return 1; } |