Esse PrintON[playerid] está verificando oque?
EDIT: Não sei se está certo, mais tente esse:
EDIT: Não sei se está certo, mais tente esse:
Código PHP:
if(newkeys == KEY_YES)
{
if((IsPlayerConnected(playerid)) && (IsPlayerInAnyVehicle(playerid) == 1) && (Logado[playerid] == 1))
{
new modelo;
modelo = GetVehicleModel(GetPlayerVehicleID(playerid));
if((modelo != 594) && (modelo != 481) && (modelo != 509) && (modelo != 510))
{
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
new mot, lu, alar, por, cap, porma, ob;
new veiculoid = GetPlayerVehicleID(playerid);
GetVehicleParamsEx(veiculoid, mot, lu, alar, por, cap, porma, ob);
if(mot == VEHICLE_PARAMS_OFF || mot == VEHICLE_PARAMS_UNSET)
{
SetVehicleParamsEx(veiculoid, VEHICLE_PARAMS_ON, lu, alar, por, cap, porma, ob);
TextDrawShowForPlayer(playerid, BarraMotorx[playerid]);
TextDrawHideForPlayer(playerid, BarraMotor[playerid]);
} else {
SetVehicleParamsEx(veiculoid, VEHICLE_PARAMS_OFF, lu, alar, por, cap, porma, ob);
TextDrawShowForPlayer(playerid, BarraMotor[playerid]);
TextDrawHideForPlayer(playerid, BarraMotorx[playerid]);
}
}
}
}
return 1;
}
Discord:https://discord.gg/Vg5HMqgdP9