Bei diesem Sirenen Script gibt es ingame ein Error
die define
#define DIALOG_SIRENEAN 128
#define DIALOG_SIRENEAUS 129
der sirenen Script
if(strcmp(cmdtext,"/sirene",true)==0)
{
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid] [pLeader] == 1 || PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid] [pLeader] == 3 || PlayerInfo[playerid][pMember] == 22 || PlayerInfo[playerid] [pLeader] == 22)
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist in keiner Staatsfraktion!");
return 1;
}
if(IsPlayerInAnyVehicle(playerid))
{
new vid = GetPlayerVehicleID(playerid);
if(sirenean[vid] == false)
{
ShowPlayerDialog(playerid,DIALOG_SIRENEAN,DIALOG_STYLE_MSGBOX,"Polizei Sirene","Möchtest du eine Sirene an dieses Fahrzeug anbauen ?","Ja","Nein");
}
else if(sirenean[vid] == true)
{
ShowPlayerDialog(playerid,DIALOG_SIRENEAUS,DIALOG_STYLE_MSGBOX,"Polizei Sirene","Möchtest du die Sirene dieses Fahrzeuges abbauen ?","Ja","Nein");
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist in keinem Fahrzeug!");
}
return 1;
}
der dialog
if(dialogid== DIALOG_SIRENEAN)
{
if(response == 0)
{
return 1;
}
if(response == 1)
{
new vid = GetPlayerVehicleID(playerid);
new Float:x,Float:y,Float:z;
GetPlayerPos(playerid,x,y,z);
sirene[vid] = CreateObject(18646,x,y,z,0,0,0,100);
AttachObjectToVehicle(sirene[vid],vid,-0.5, -0.2, 0.8, 2.0, 2.0, 3.0);
sirenean[vid] = true;
SendClientMessage(playerid,0xFF0000,"Du hast die Sirene angebaut!");
}
}
if(dialogid== DIALOG_SIRENEAUS)
{
if(response == 0)
{
return 1;
}
if(response == 1)
{
new vid = GetPlayerVehicleID(playerid);
DestroyObject(sirene[vid]);
sirenean[vid] =false;
SendClientMessage(playerid,0xFF0000,"Du hast die Sirene abgebaut!");
}
}
//edit Dialog und define hinzugefügt
und ingame steht dann du bist kein Staats Mitglied.
pls help
Mfg