if(!strcmp("/ddc1", cmdtext, true) == 0)
{
if(IsPlayerInAnyVehicle(playerid))
{
new ddc1tele;
ddc1tele = GetPlayerVehicleID(playerid);
SetVehiclePos(ddc1tele, -294.2373,1536.7737,75.5625);
new teleddc1[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc1, sizeof(teleddc1));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-1 (/ddc1)",teleddc1);
SendClientMessageToAll(Verde, string);
}
else
{
SetPlayerPos(playerid, -294.2373,1536.7737,75.5625);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-1 (/ddc1)",teleddc2);
SendClientMessageToAll(Verde, string);
}
return 1;
}
//ddc2
if(!strcmp("/ddc2", cmdtext, true) == 0)
{
if(IsPlayerInAnyVehicle(playerid))
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 562)
{
new ddc2tele;
ddc2tele = GetPlayerVehicleID(playerid);
SetVehiclePos(ddc2tele, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
else
{
SetPlayerPos(playerid, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
}
else
{
SetPlayerPos(playerid, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
return 1;
}
if(!strcmp("/ddc1", cmdtext, true))
{
if(IsPlayerInAnyVehicle(playerid))
{
new ddc1tele;
ddc1tele = GetPlayerVehicleID(playerid);
SetVehiclePos(ddc1tele, -294.2373,1536.7737,75.5625);
new teleddc1[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc1, sizeof(teleddc1));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-1 (/ddc1)",teleddc1);
SendClientMessageToAll(Verde, string);
}
else
{
SetPlayerPos(playerid, -294.2373,1536.7737,75.5625);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-1 (/ddc1)",teleddc2);
SendClientMessageToAll(Verde, string);
}
return 1;
}
//ddc2
if(!strcmp("/ddc2", cmdtext, true))
{
if(IsPlayerInAnyVehicle(playerid))
{
if(GetVehicleModel(GetPlayerVehicleID(playerid)) == 562)
{
new ddc2tele;
ddc2tele = GetPlayerVehicleID(playerid);
SetVehiclePos(ddc2tele, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
else
{
SetPlayerPos(playerid, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
}
else
{
SetPlayerPos(playerid, 2291.7197,1392.2921,42.8203);
new teleddc2[MAX_PLAYER_NAME], string[150];
GetPlayerName(playerid, teleddc2, sizeof(teleddc2));
format(string, sizeof(string), "[INFO] O Player %s foi para DDC-2 (/ddc2)",teleddc2);
SendClientMessageToAll(Verde, string);
}
return 1;
}
if(!strcmp("/ddc2", cmdtext, true)) e if(!strcmp("/ddc2", cmdtext, true) == 0)
if(strcmp("/ddc2", cmdtext, true)) e if(strcmp("/ddc2", cmdtext, true) == 0) qual a diferenзa entre cada um? '-' |
if(!strcmp(blablabla))
e
if(strcmp(blablabla) == 0);
if(strcmp(blablabla))
if(!strcmp(blablabla) == 0)
pawn Код:
Nгo diferenзa entre pawn Код:
pawn Код:
pawn Код:
|
if(!strcmp(cmdtext, "/comando", true))
{
bla bla bla
}
OU
if(strcmp(cmdtext, "/comando", true) == 0)
{
bla bla bla
}
//sim vocк pode usar o primeiro para alguns comandos e o segundo para outros mas nгo misture os dois em um comando sу :S