hallo habe nen problem mein Motor lässt sich zwar anschalten aber nicht abschalten wieso?
if (newkeys == KEY_FIRE) // Motor An/Aus
{
if(IsPlayerInAnyVehicle(playerid))
{
if(GetPlayerState(playerid) == PLAYER_STATE_DRIVER)
{
if(Motor[GetPlayerVehicleID(playerid)] == 0)
{
GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(vid,VEHICLE_PARAMS_ON,lights,alarm,doors,bonnet,boot,objective);
Motor[GetPlayerVehicleID(playerid)] = 1;
return 1;
}
else
{
GetVehicleParamsEx(vid,engine,lights,alarm,doors,bonnet,boot,objective);
SetVehicleParamsEx(vid,VEHICLE_PARAMS_OFF,lights,alarm,doors,bonnet,boot,objective);
Motor[GetPlayerVehicleID(playerid)] = 0;
return 1;
}
}
}
return 1;
}
Danke euch
mfg.
bacardi