Hey
dieser befehl geht nicht, bis /car daten
hoffe ihr könnt mir helfen
if(strcmp(cmd,"/car",true)==0)
{
if (IsPlayerInAnyVehicle(playerid))
{
new x_names[256];
x_names = strtok(cmdtext, idx);
if(!strlen(x_names))
{
SendClientMessage(playerid, COLOR_GREEN, "|__________________ Akzeptieren __________________|");
SendClientMessage(playerid, COLOR_GREEN, "Benutze: /car put/take/daten ");
SendClientMessage(playerid, COLOR_GREEN, "Mats,Drogen,Weste");
SendClientMessage(playerid, COLOR_GREEN, "|____________________________________________|");
return 1;
}
if(strcmp(x_names,"daten",true) == 0)
{
new string[256];
new car = GetPlayerVehicleID(playerid);
new weste[256];
if(CarInfo[car][cRustung] == 1)
{
weste = "Ja";
}
else
{
weste="Nein";
}
format(string, sizeof(string), "Drogen=%d,Mats=%d,Schutzweste=%s",CarInfo[car][cDrogen],CarInfo[car][cMats],weste);
SendClientMessage(playerid,COLOR_GREEN,string);
}
if(strcmp(x_names,"put",true) == 0)
{
new x_put[256];
x_put = strtok(cmdtext, idx);
if(!strlen(x_put))
{
SendClientMessage(playerid, COLOR_GREEN, "|__________________ Akzeptieren __________________|");
SendClientMessage(playerid, COLOR_GREEN, "Benutze: /car put ");
SendClientMessage(playerid, COLOR_GREEN, "Mats,Drogen,Weste");
SendClientMessage(playerid, COLOR_GREEN, "|____________________________________________|");
return 1;
}
if(strcmp(x_put,"weste",true) == 0)
{
new car = GetPlayerVehicleID(playerid);
if(CarInfo[car][cRustung] == 0)
{
new Float:armour;
new armor=GetPlayerArmour(playerid,armour);
if(armor == 100)
{
SetPlayerArmour(playerid,0);
CarInfo[car][cRustung] = 1;
}
}
}
}
if(strcmp(x_names,"take",true) == 0)
{
new x_take[256];
x_take = strtok(cmdtext, idx);
if(!strlen(x_take))
{
SendClientMessage(playerid, COLOR_GREEN, "|__________________ Akzeptieren __________________|");
SendClientMessage(playerid, COLOR_GREEN, "Benutze: /car put ");
SendClientMessage(playerid, COLOR_GREEN, "Mats,Drogen,Weste");
SendClientMessage(playerid, COLOR_GREEN, "|____________________________________________|");
return 1;
}
if(strcmp(x_take,"weste",true) == 0)
{
new car = GetPlayerVehicleID(playerid);
if(CarInfo[car][cRustung] == 1)
{
SetPlayerArmour(playerid,100);
CarInfo[car][cRustung] = 0;
}
}
}
}
return 0;
}
//edit1:
kann mir keiner helfen
mfg