16.04.2011, 16:25
pawn Код:
if(strcmp(cmdtext, "/arena", true) == 0 && GetPVarInt(playerid, "NaArena") == 0 )
{
if(IsPlayerInAnyVehicle(playerid))
return SendClientMessage(playerid,COLOR_RED,"Vocк nгo pode ir a Arena em um veнculo!");
new pname[MAX_PLAYER_NAME];
new string [256];
GetPlayerName(playerid, pname, MAX_PLAYER_NAME);
format(string, sizeof(string), "O Player {FFFFFF}%s {FFFF00}foi atй a Arena! Digite {FFFFFF}/arena{FFFF00}.", pname);
SendClientMessageToAll(0xFFFF00FF, string);
SetPlayerPos(playerid, 1677.4564,-1337.7351,158.4766);
ResetPlayerWeapons(playerid);
GivePlayerWeapon(playerid, 16, 50);
GivePlayerWeapon(playerid, 31, 100000);
GivePlayerWeapon(playerid, 26, 100000);
GivePlayerWeapon(playerid, 32, 100000);
SetPlayerHealth(playerid, 100.0);
SetPlayerArmour(playerid, 100.0);
SetPVarInt(playerid, "NaArena",1);
return 1;
}
if(strcmp(cmdtext, "/sair", true) == 0 && GetPVarInt(playerid, "NaArena") == 1 )
return SendClientMessage(playerid,COLOR_RED,"Vocк saiu da Arena!"),
SetPlayerHealth(playerid, 0.0);
SetPVarInt(playerid, "NaArena",0);
if(GetPVarInt(playerid, "NaArena") == 1)
return SendClientMessage(playerid,COLOR_RED,"Vocк nгo pode usar comandos na Arena! Digite {FFFFFF}/sair {FF0000}se quiser sair da Arena!");
//fim da arena
Podem me ajudar?