Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sonik_Paintballer - 30.11.2012
galera olhem esses 2 comandos:
pawn Код:
if(strcmp(cmd, "/blindarcarro", true) == 0)
{
if (PlayerInfo[playerid][pVIP] >= 5 || IsPlayerInAnyVehicle(playerid) || Istunevip(playerid))
{
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "%s estб com o carro blindado!", playername);
SendClientMessageToAll(COLOR_RED,string);
GivePlayerMoneyEx(playerid,-1500000);
RepairCar[playerid] = GetPlayerVehicleID(playerid);
SetVehicleHealth(RepairCar[playerid], 10000.0);
}
return 1;
}
pawn Код:
if(strcmp(cmd, "/neon", true) == 0)
{
if (PlayerInfo[playerid][pAdmin] >= 4 || IsPlayerInAnyVehicle(playerid) || PlayerInfo[playerid][pVIP] >= 5 || Istunevip(playerid))
{
ShowPlayerDialog(playerid, neondialog, DIALOG_STYLE_LIST, "Cores de Neon", "Azul Escuro\nVermelho\nVerde\nBranco\nVioleta\nAmarelo\nCiano\nAzul Claro\nRosa\nLaranja\nVerde Claro\nAmarelo Claro\nRetirar Neon", "Selecionar", "Cancelar");
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "* %s Estб escolhendo um neon!", sendername);
ProxDetector(100.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
return 1;
}
esses 2 comandos funcionan mesmo sem a pessoa estar dentro de um veiculo e sem estar no local (Istunevip),oq eu faзo? :S
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Nice-.- - 30.11.2012
https://sampwiki.blast.hk/wiki/IsPlayerInRangeOfPoint estude isso
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sonik_Paintballer - 30.11.2012
Desculpe amigo mais nгo tenho tempo :/ minha vida й mt corrida e meu sv ja ta no VPS
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Maklister - 30.11.2012
Quote:
Originally Posted by Sonik_Paintballer
Desculpe amigo mais nгo tenho tempo :/ minha vida й mt corrida e meu sv ja ta no VPS
|
Esse й o problema que abrir um servidor sem ao mesmo ter tempo para o mesmo, servidor й necessбrio tempo amigo ...
sem tempo nгo tem como estudar, e sem estudar nгo se aprende codar ....
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sonik_Paintballer - 30.11.2012
por issoeu prefiro colar kkkk mais eai tem alguma soluзгo ai? :S
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sky™ - 30.11.2012
simples!
pawn Код:
if(strcmp(cmd, "/blindarcarro", true) == 0)
{
if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo");
if(Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pVIP] >= 5)
{
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "%s estб com o carro blindado!", playername);
SendClientMessageToAll(COLOR_RED,string);
GivePlayerMoneyEx(playerid,-1500000);
RepairCar[playerid] = GetPlayerVehicleID(playerid);
SetVehicleHealth(RepairCar[playerid], 10000.0);
format(STRX, sizeof(STRX), "%s Blindou seu Veiculo", playername);
CmdsLog(STRX);
}
return 1;
}
if(strcmp(cmd, "/neon", true) == 0)
{
if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo");
if(Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pAdmin] >= 4 || PlayerInfo[playerid][pVIP] >= 5)
{
ShowPlayerDialog(playerid, neondialog, DIALOG_STYLE_LIST, "Cores de Neon", "Azul Escuro\nVermelho\nVerde\nBranco\nVioleta\nAmarelo\nCiano\nAzul Claro\nRosa\nLaranja\nVerde Claro\nAmarelo Claro\nRetirar Neon", "Selecionar", "Cancelar");
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "* %s Estб escolhendo um neon!", sendername);
ProxDetector(100.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
return 1;
}
//e ja juntando com a resposta do outro topico
forward CmdsLog(string[]);
public CmdsLog(string[])
{
new entry[256];
new hour, minute,
second, year, month, day;
getdate(year, month, day);
gettime(hour, minute, second);
format(entry, sizeof(entry), "%s\r|| Data : %d/%d/%d || Horбrio : %d:%d:%d\n", string, day, month, year, hour, minute, second);
new File:hFile;
hFile = fopen("Cmds.log", io_append);
fwrite(hFile, entry);
fclose(hFile);
return 1;
}
//2 topicos seus que eu respondo se nгo leu as regras melhor ler Proximo eu reporto!
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Maklister - 30.11.2012
Quote:
Originally Posted by Sonik_Paintballer
por issoeu prefiro colar kkkk mais eai tem alguma soluзгo ai? :S
|
Tenso ¬¬'
#ModoLatinoOn
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sonik_Paintballer - 30.11.2012
Quote:
Originally Posted by Sky_.
simples!
pawn Код:
if(strcmp(cmd, "/blindarcarro", true) == 0) { if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo"); if(Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem"); if (PlayerInfo[playerid][pVIP] >= 5) { GetPlayerName(playerid, playername,sizeof(playername)); format(string, sizeof(string), "%s estб com o carro blindado!", playername); SendClientMessageToAll(COLOR_RED,string); GivePlayerMoneyEx(playerid,-1500000); RepairCar[playerid] = GetPlayerVehicleID(playerid); SetVehicleHealth(RepairCar[playerid], 10000.0); format(STRX, sizeof(STRX), "%s Blindou seu Veiculo", playername);
CmdsLog(STRX); } return 1; }
if(strcmp(cmd, "/neon", true) == 0) { if(IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo"); if(Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pAdmin] >= 4 || PlayerInfo[playerid][pVIP] >= 5) { ShowPlayerDialog(playerid, neondialog, DIALOG_STYLE_LIST, "Cores de Neon", "Azul Escuro\nVermelho\nVerde\nBranco\nVioleta\nAmarelo\nCiano\nAzul Claro\nRosa\nLaranja\nVerde Claro\nAmarelo Claro\nRetirar Neon", "Selecionar", "Cancelar"); GetPlayerName(playerid, playername,sizeof(playername)); format(string, sizeof(string), "* %s Estб escolhendo um neon!", sendername); ProxDetector(100.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); } return 1; }
//e ja juntando com a resposta do outro topico
forward CmdsLog(string[]); public CmdsLog(string[]) { new entry[256]; new hour, minute, second, year, month, day; getdate(year, month, day); gettime(hour, minute, second);
format(entry, sizeof(entry), "%s\r|| Data : %d/%d/%d || Horбrio : %d:%d:%d\n", string, day, month, year, hour, minute, second); new File:hFile; hFile = fopen("Cmds.log", io_append); fwrite(hFile, entry); fclose(hFile); return 1; }
//2 topicos seus que eu respondo se nгo leu as regras melhor ler Proximo eu reporto!
|
mesmo eu no carro e no lugar de tunagem a mensagem й dita "vocк nгo estб em um veiculo" e se eu tiver apй fala q eu nao to no lugar da tunagem '-'
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sky™ - 30.11.2012
pawn Код:
if(strcmp(cmd, "/blindarcarro", true) == 0)
{
if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo");
if(!Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pVIP] >= 5)
{
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "%s estб com o carro blindado!", playername);
SendClientMessageToAll(COLOR_RED,string);
GivePlayerMoneyEx(playerid,-1500000);
RepairCar[playerid] = GetPlayerVehicleID(playerid);
SetVehicleHealth(RepairCar[playerid], 10000.0);
format(STRX, sizeof(STRX), "%s Blindou seu Veiculo", playername);
CmdsLog(STRX);
}
return 1;
}
if(strcmp(cmd, "/neon", true) == 0)
{
if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo");
if(!Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pAdmin] >= 4 || PlayerInfo[playerid][pVIP] >= 5)
{
ShowPlayerDialog(playerid, neondialog, DIALOG_STYLE_LIST, "Cores de Neon", "Azul Escuro\nVermelho\nVerde\nBranco\nVioleta\nAmarelo\nCiano\nAzul Claro\nRosa\nLaranja\nVerde Claro\nAmarelo Claro\nRetirar Neon", "Selecionar", "Cancelar");
GetPlayerName(playerid, playername,sizeof(playername));
format(string, sizeof(string), "* %s Estб escolhendo um neon!", sendername);
ProxDetector(100.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
}
return 1;
}
//e ja juntando com a resposta do outro topico
forward CmdsLog(string[]);
public CmdsLog(string[])
{
new entry[256];
new hour, minute,
second, year, month, day;
getdate(year, month, day);
gettime(hour, minute, second);
format(entry, sizeof(entry), "%s\r|| Data : %d/%d/%d || Horбrio : %d:%d:%d\n", string, day, month, year, hour, minute, second);
new File:hFile;
hFile = fopen("Cmds.log", io_append);
fwrite(hFile, entry);
fclose(hFile);
return 1;
}
opa desculpe arrumei ja!
Re: Pq o comando ta funfando mesmo sem tar no lugar? o.O -
Sonik_Paintballer - 01.12.2012
Quote:
Originally Posted by Sky_.
pawn Код:
if(strcmp(cmd, "/blindarcarro", true) == 0) { if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo"); if(!Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem"); if (PlayerInfo[playerid][pVIP] >= 5) { GetPlayerName(playerid, playername,sizeof(playername)); format(string, sizeof(string), "%s estб com o carro blindado!", playername); SendClientMessageToAll(COLOR_RED,string); GivePlayerMoneyEx(playerid,-1500000); RepairCar[playerid] = GetPlayerVehicleID(playerid); SetVehicleHealth(RepairCar[playerid], 10000.0); format(STRX, sizeof(STRX), "%s Blindou seu Veiculo", playername);
CmdsLog(STRX); } return 1; }
if(strcmp(cmd, "/neon", true) == 0) { if(!IsPlayerInAnyVehicle(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб em um veiculo"); if(!Istunevip(playerid)) return SendClientMessage(playerid, Vermelho, "vocк nгo estб no Local de tunagem");
if (PlayerInfo[playerid][pAdmin] >= 4 || PlayerInfo[playerid][pVIP] >= 5) { ShowPlayerDialog(playerid, neondialog, DIALOG_STYLE_LIST, "Cores de Neon", "Azul Escuro\nVermelho\nVerde\nBranco\nVioleta\nAmarelo\nCiano\nAzul Claro\nRosa\nLaranja\nVerde Claro\nAmarelo Claro\nRetirar Neon", "Selecionar", "Cancelar"); GetPlayerName(playerid, playername,sizeof(playername)); format(string, sizeof(string), "* %s Estб escolhendo um neon!", sendername); ProxDetector(100.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE); } return 1; }
//e ja juntando com a resposta do outro topico
forward CmdsLog(string[]); public CmdsLog(string[]) { new entry[256]; new hour, minute, second, year, month, day; getdate(year, month, day); gettime(hour, minute, second);
format(entry, sizeof(entry), "%s\r|| Data : %d/%d/%d || Horбrio : %d:%d:%d\n", string, day, month, year, hour, minute, second); new File:hFile; hFile = fopen("Cmds.log", io_append); fwrite(hFile, entry); fclose(hFile); return 1; }
opa desculpe arrumei ja!
|
muito obrigado =D