Guten Abend,
Ich habe das problem das ich meine Umkleideraum für die Cops/FBI/Army nicht mehr finde
und wollte mal fragen ob mir einer den /duty Befehl so umscripten kann das ich in den
Copcars onduty/offduty gehen kann??
MFG Luke
Guten Abend,
Ich habe das problem das ich meine Umkleideraum für die Cops/FBI/Army nicht mehr finde
und wollte mal fragen ob mir einer den /duty Befehl so umscripten kann das ich in den
Copcars onduty/offduty gehen kann??
MFG Luke
Dan poste wenigstens den Command, dan haben wir schonmal einen Vorteil
if(strcmp(cmd, "/dienst", true) == 0)
{
if(IsPlayerConnected(playerid))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pLeader] == 15 || PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 18 || PlayerInfo[playerid][pMember] == 18)
{
if (PlayerToPoint(3.0,playerid,217.7090,185.7917,1003.0313) || PlayerToPoint(3.0,playerid,255.3710,77.1289,1003.6406))
{
if(OnDuty[playerid]==0)
{
format(string, sizeof(string), "%s nimmt seine Uniform und seine Waffen aus dem Spint.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 24, 250);
GivePlayerWeapon(playerid, 3, 0);
GivePlayerWeapon(playerid, 29, 250);
GivePlayerWeapon(playerid, 31, 250);
SetPlayerHealth(playerid,100);
OnDuty[playerid] = 1;
}
else if(OnDuty[playerid]==1)
{
format(string, sizeof(string), "%s legt seine Uniform und seine Waffen in den Spint.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 23, 150);
GivePlayerWeapon(playerid, 5, 0);
OnDuty[playerid] = 0;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD2, "Du bist nicht im Umkleidungsraum!");
return 1;
}
}
else if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2)
{
if (PlayerToPoint(6, playerid,217.7090,185.7917,1003.0313))
{
if(OnDuty[playerid]==0)
{
format(string, sizeof(string), "%s nimmt seine Uniform und seine Waffen aus dem Spint.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 24, 250);
GivePlayerWeapon(playerid, 3, 0);
GivePlayerWeapon(playerid, 29, 250);
GivePlayerWeapon(playerid, 31, 250);
SetPlayerHealth(playerid,100);
OnDuty[playerid] = 1;
}
else if(OnDuty[playerid]==1)
{
format(string, sizeof(string), "%s legt seine Uniform und seine Waffen in den Spint.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 23, 150);
GivePlayerWeapon(playerid, 5, 0);
OnDuty[playerid] = 0;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD2, "Du bist nicht im Umkleidungsraum!");
return 1;
}
}
else if(PlayerInfo[playerid][pMember] == 4||PlayerInfo[playerid][pLeader] == 4)
{
if(JobDuty[playerid] == 1)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Offduty!");
JobDuty[playerid] = 0;
Medics -= 1;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Onduty!");
JobDuty[playerid] = 1;
Medics += 1;
}
}
else if(PlayerInfo[playerid][pJob] == 7)
{
if(JobDuty[playerid] == 1)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Offduty!");
JobDuty[playerid] = 0;
Mechanics -= 1;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Onduty!");
JobDuty[playerid] = 1;
Mechanics += 1;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist kein Verbrechensjäger!");
}
}
return 1;
}
if(strcmp(cmd, "/dienst", true) == 0)
{
if(IsPlayerConnected(playerid))
{
GetPlayerName(playerid, sendername, sizeof(sendername));
if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1 || PlayerInfo[playerid][pLeader] == 15 || PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 18 || PlayerInfo[playerid][pMember] == 18)
{
if(IsPlayerInVehicle(playerid))
{
if(OnDuty[playerid]==0)
{
format(string, sizeof(string), "%s nimmt seine Uniform und seine Waffen aus dem Spint.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 24, 250);
GivePlayerWeapon(playerid, 3, 0);
GivePlayerWeapon(playerid, 29, 250);
GivePlayerWeapon(playerid, 31, 250);
SetPlayerHealth(playerid,100);
OnDuty[playerid] = 1;
}
else if(OnDuty[playerid]==1)
{
format(string, sizeof(string), "%s legt seine Uniform und seine Waffen in den Kofferraum.", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 23, 150);
GivePlayerWeapon(playerid, 5, 0);
OnDuty[playerid] = 0;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD2, "Du bist nicht im Fahrzeug");
return 1;
}
}
else if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2)
{
if (Is
{
if(OnDuty[playerid]==0)
{
format(string, sizeof(string), "%s nimmt seine Uniform und seine Waffen aus dem Kofferraum", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 24, 250);
GivePlayerWeapon(playerid, 3, 0);
GivePlayerWeapon(playerid, 29, 250);
GivePlayerWeapon(playerid, 31, 250);
SetPlayerHealth(playerid,100);
OnDuty[playerid] = 1;
}
else if(OnDuty[playerid]==1)
{
format(string, sizeof(string), "%s legt seine Uniform und seine Waffen in den Kofferraum", sendername);
ProxDetector(30.0, playerid, string, COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE,COLOR_PURPLE);
GivePlayerWeapon(playerid, 23, 150);
GivePlayerWeapon(playerid, 5, 0);
OnDuty[playerid] = 0;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD2, "Du bist nicht in einem Fahrzeug");
return 1;
}
}
else if(PlayerInfo[playerid][pMember] == 4||PlayerInfo[playerid][pLeader] == 4)
{
if(JobDuty[playerid] == 1)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Offduty!");
JobDuty[playerid] = 0;
Medics -= 1;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Onduty!");
JobDuty[playerid] = 1;
Medics += 1;
}
}
else if(PlayerInfo[playerid][pJob] == 7)
{
if(JobDuty[playerid] == 1)
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Offduty!");
JobDuty[playerid] = 0;
Mechanics -= 1;
}
else
{
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du bist nun Onduty!");
JobDuty[playerid] = 1;
Mechanics += 1;
}
}
else
{
SendClientMessage(playerid, COLOR_GRAD1, "Du bist kein Verbrechensjäger!");
}
}
return 1;
}
Musste mal versuchen, weiß aber nicht genau
Nein geht nicht
Danke trozdem
Was kommt den ? Error, oder klappts einfach nicht ?
Mitten beim compilen zeigt mir mein windows eine problem behandlung an und pawno stürzt ab
EDIT:Kann mir den wenigstens jemand sagen wie ich das ändern kann das ich überall onduty/offduty gehen kann??
MFG luke
script check ich ncht
Könnte mir dann bitte einer ein neues machen?
MFG luke
Edit: Hab es selber herraus gefunden.