So 0 Errors und so.. aber wen ich im Auto "H" drücke kommt sie einfach nicht-.-
Code:
public OnPlayerKeyStateChange(playerid, newkeys, oldkeys)
{
new Sirene[MAX_PLAYERS];
new vehicle = GetPlayerVehicleID(playerid);
if(newkeys == (KEY_CROUCH))
{
if(IsPlayerInAnyVehicle(playerid))
{
if(Sirene[playerid] == 0)
{
Sirene[playerid] = 1;
Sirenen[0] = CreateObject(18646,0,0,0,0,0,0);
AttachObjectToVehicle(Sirenen[0],vehicle, -0.5, -0.2, 0.8, 2.0, 2.0, 3.0);
}
if(Sirene[playerid] == 1)
{
Sirene[playerid] = 0;
DestroyObject(Sirenen[0]);
}
}
}
}
Lg