#include <a_samp>
new carro[MAX_PLAYERS] = 520;
new TaNaArena[MAX_PLAYERS];
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/carro", cmdtext, true, 10) == 0)
{
CreateVehicle(carro[playerid], 0, 0, 0, 0, 0, 0, 60);
return 1;
}
if (strcmp("/arena", cmdtext, true, 10) == 0)
{
if (TaNaArena[playerid] == 0)
{
TaNaArena[playerid] = 1;
SetPlayerPos(playerid, 1417.0, 1245.89, 8484.78);
} else {
SendClientMessage(playerid, -1, "vocк jб estб na arena.");
}
return 1;
}
return 0;
}
new bool:Array[MAX_PLAYERS];
CMD:duel(playerid)
{
if(Array[playerid] == true)
return SendClientMessage(playerid,0xFFDD00FF,"> Vocк jб estб em um duel!");
return 1;
}
#undef MAX_PLAYERS
#define MAX_PLAYERS 20 // slots
#include <a_samp>
new carro[MAX_PLAYERS] = 520;
new TaNaArena[MAX_PLAYERS];
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/carro", cmdtext, true, 10) == 0)
{
CreateVehicle(carro[playerid], 0, 0, 0, 0, 0, 0, 60);
return 1;
}
if (strcmp("/arena", cmdtext, true, 10) == 0)
{
if (TaNaArena[playerid] == 0)
{
TaNaArena[playerid] = 1;
SetPlayerPos(playerid, 1417.0, 1245.89, 8484.78);
} else {
SendClientMessage(playerid, -1, "vocк jб estб na arena.");
}
return 1;
}
return 0;
}
#include <a_samp>
#define slots 100
new bool:TaNaArena[slots];
public OnPlayerConnect(playerid)
{
TaNaArena[playerid] = false;
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if (strcmp("/carro", cmdtext, true, 10) == 0)
{
CreateVehicle(520, 0, 0, 0, 0, 0, 0, 60);
return 1;
}
if (strcmp("/arena", cmdtext, true, 10) == 0)
{
if (TaNaArena[playerid] == false)
{
TaNaArena[playerid] = true;
SetPlayerPos(playerid, 1417.0, 1245.89, 8484.78);
} else {
SendClientMessage(playerid, -1, "vocк jб estб na arena.");
}
return 1;
}
return 0;
}
new
bool:TaNaArena[MAX_PLAYERS char],
carro[MAX_PLAYERS] = 520
;
public OnPlayerConnect(playerid){
return !(TaNaArena{playerid} = false);
}
public OnPlayerCommandText(playerid, cmdtext[])
{
if(!strcmp("/carro", cmdtext, true))
{
CreateVehicle(carro[playerid], 0, 0, 0, 0, 0, 0, 60);
return 1;
}
if(!strcmp("/sair", cmdtext, true)){
TaNaArena{playerid} = false;
SetPlayerVirtualWorld(playerid, 0);
SetPlayerInterior(playerid, 0);
SpawnPlayer(playerid);
return 1;
}
if(!strcmp("/arena", cmdtext, true))
{
if(TaNaArena{playerid}){
return SendClientMessage(playerid, -1, "vocк jб estб na arena. digite ( /Sair )");
}
TaNaArena{playerid} = true;
SetPlayerPos(playerid, 1417.0, 1245.89, 8484.78);
return 1;
}
return 0;
}
if (strcmp("/arena", cmdtext, true, 10) == 0) { if (TaNaArena[playerid] == 0) { TaNaArena[playerid] = 1; SetPlayerPos(playerid, 1417.0, 1245.89, 8484.7 ![]() } if(TaNaArena[playerid] == 1) { SendClientMessage(playerid, -1, "vocк jб estб na arena."); return 1; } return 1; } |
Nгo cara... Como vocк й burro kkkk
''else'' serve somente para bool's... Ou seja, nгo funciona vc colokar else numa funзгo que nгo й de bool |