if (strcmp("/trafico", cmdtext, true, 10) == 0) if(IsPlayerInAnyVehicle(playerid)) { new VehicleID; VehicleID = GetPlayerVehicleID(playerid); SetVehiclePos(VehicleID,2177.8599,-980.9830,64.4688); SetVehicleZAngle(GetPlayerVehicleID(playerid),0); SetPlayerInterior(playerid,0); } else{ SetPlayerInterior(playerid,0); SetPlayerPos(playerid,2177.8599,-980.9830,64.4688); SetPlayerFacingAngle(playerid,0); } return 1;
if (strcmp("/trafico", cmdtext, true, 10) == 0)
if(IsPlayerInAnyVehicle(playerid)) {
new VehicleID,Nome[MAX_PLAYER_NAME],string[100];
GetPlayerName(playerid,Nome,sizeof(Nome));
VehicleID = GetPlayerVehicleID(playerid);
format(string,sizeof(string),"%s foi para a favela",Nome);
SendClientMessageToAll(-1,string);
SetVehiclePos(VehicleID,2177.8599,-980.9830,64.4688);
SetVehicleZAngle(GetPlayerVehicleID(playerid),0);
SetPlayerInterior(playerid,0);
}
else{
SetPlayerInterior(playerid,0);
SetPlayerPos(playerid,2177.8599,-980.9830,64.4688);
SetPlayerFacingAngle(playerid,0);
}
return 1;
zcmd
CMD:trafico(playerid)
{
if (IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
SetVehiclePos(VehicleID,2177.8599,-980.9830,64.4688);
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
new string[45];
format(string, sizeof(string), " %s Foi Para o trafico Comando /trafico ", name);
SendClientMessageToAll(-1, string);
SetPlayerInterior(playerid, 0);
}else {
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
SetPlayerPos(playerid,2177.8599,-980.9830,64.4688);
SetPlayerInterior(playerid, 0);
new string[45];
format(string, sizeof(string), " %s Foi Para o trafico Comando /trafico ", name);
SendClientMessageToAll(-1, string);
}
return 1;
}
strcmp
if (strcmp("/trafico", cmdtext, true, 8) == 0)
{
if (IsPlayerInAnyVehicle(playerid))
{
new VehicleID;
VehicleID = GetPlayerVehicleID(playerid);
SetVehiclePos(VehicleID,2177.8599,-980.9830,64.4688);
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
new string[45];
format(string, sizeof(string), " %s Foi Para o trafico Comando /trafico ", name);
SendClientMessageToAll(-1, string);
SetPlayerInterior(playerid, 0);
}else {
new name[MAX_PLAYER_NAME];
GetPlayerName(playerid, name, MAX_PLAYER_NAME);
SetPlayerPos(playerid,2177.8599,-980.9830,64.4688);
SetPlayerInterior(playerid, 0);
new string[45];
format(string, sizeof(string), " %s Foi Para o trafico Comando /trafico ", name);
SendClientMessageToAll(-1, string);
}
return 1;
}
pawn Код:
pawn Код:
|
aumente as strings
aonde estiver
new string [45];
para
new string [128];
pawn Код:
|