01.02.2013, 20:16
Aew Galera Tava Revisando Meu Sistema de Carros Vip e Percebi Que Os Meus Veнculos Vips Nгo Destrancam Prуximo Do Veiculo Ele So Estб Destrancando Dentro de interiores, e Outro problema e que os Carros Eles So Trancam Quando o Player Dono do Veiculo Estб Dentro Dele!
Revisando: Veiculo So Destranca Dentro de Interiores, e So Tranca Dentro Do Veiculo!
o Meu /veiculo trancar
Revisando: Veiculo So Destranca Dentro de Interiores, e So Tranca Dentro Do Veiculo!
o Meu /veiculo trancar
PHP код:
if(strcmp(tmp, "trancar", true) == 0)
{
if(PlayerInfo[playerid][pCarKey] == 0 && PlayerInfo[playerid][pCarKey2] == 0)
{
SendClientMessage(playerid, COLOR_GREY, "Vocк nгo tem um Carro VIP.");
return true;
}
if(PlayerInfo[playerid][pCarKey] != vehid && PlayerInfo[playerid][pCarKey2] != vehid)
{
SendClientMessage(playerid, COLOR_GREY, "Esse nгo й seu Carro VIP.");
return true;
}
new keycar = GetPlayerVehicleID(playerid);
if(vehid == PlayerInfo[playerid][pCarKey]) { keycar = PlayerInfo[playerid][pVeiculo]; }
else if(vehid == PlayerInfo[playerid][pCarKey2]) { keycar = PlayerInfo[playerid][pVeiculo2]; }
if(IsPlayerConnected(playerid))
{
if(CarInfo[keycar][cLock] == 1)
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i)) SetVehicleParamsForPlayer(CarInfo[keycar][ownedvehicle],i,0,0);
}
format(string, sizeof(string), "~w~Veiculo VIP~n~~g~Aberto");
PlayerPlaySound(playerid, 1145, 0.0, 0.0, 0.0);
GameTextForPlayer(playerid, string, 10000, 3);
CarInfo[keycar][cLock] = 0;
return true;
}
else
{
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i)) SetVehicleParamsForPlayer(CarInfo[keycar][ownedvehicle],i,0,1);
}
format(string, sizeof(string), "~w~Veiculo VIP~n~~r~Trancado");
PlayerPlaySound(playerid, 1145, 0.0, 0.0, 0.0);
GameTextForPlayer(playerid, string, 10000, 3);
CarInfo[keycar][cLock] = 1;
return true;
}
}
return true;
}