Hallo, ich habe diesen Code
#include <a_samp>
enum e_PlayerBusInfo {
bool:pmi_bAktiv,
pmi_Checkpoint
}
new Busfahrer[MAX_PLAYERS][e_PlayerBusInfo];
enum e_Bus {
Float:B_fX,
Float:B_fY,
Float:B_fZ,
Float:B_fRad
}
new
Bus_Stationen[][e_Bus] = {
{-74.2252, -1128.7936, 1.6359, 6.0},
{-89.2432, -1189.7782, 2.3241, 6.0},
{-63.3734, -1588.5732, 3.1782, 6.0},
{220.8943, -1393.5308, 52.1264, 6.0},
{169.0361, -1356.8065, 69.8208, 6.0},
{263.5524, -1341.0842, 53.7643, 6.0},
{871.9646, -864.5255, 77.2742, 6.0},
{935.7687, -835.7352, 94.4455, 6.0},
{1496.5879, -698.0237, 94.5207, 6.0},
{1001.1724, -935.0218, 41.9509, 6.0},
{-546.9002, -488.6077, 25.2961, 6.0}
};
public OnFilterScriptInit()
{
print("-] Tutorial - Checkpoints abfahren [-");
CreateVehicle(408,-535.8450,-502.6665,26.0667,358.0911,1,1,-1);
return 1;
}
public OnPlayerCommandText(playerid, cmdtext[]) {
if (strcmp("/starten", cmdtext, true, 8) == 0) {
if(!Busfahrer[playerid][pmi_bAktiv]) {
new
vehicleid = GetPlayerVehicleID(playerid),
model = GetVehicleModel(vehicleid);
if(model == 408) {
Busfahrer[playerid][pmi_Checkpoint]=0;
Busfahrer[playerid][pmi_bAktiv]=true;
SendClientMessage(playerid, COLOR_LIGHTGREEN, "Linie gestartet, fahre nun zu den einzelnen Haltestellen!");
SetPlayerCheckpoint(playerid,Bus_Stationen[0][B_fX],Bus_Stationen[0][B_fY],Bus_Stationen[0][B_fZ],Bus_Stationen[0][B_fRad]);
}
else {
SendClientMessage(playerid, COLOR_RED, "Du bist nicht im Bus!");
}
}
else {
SendClientMessage(playerid, COLOR_RED, "Es laeuft schon eine Mission!");
}
return 1;
}
return 0;
}
public OnPlayerEnterCheckpoint(playerid) {
if(Busfahrer[playerid][pmi_bAktiv]) {
Busfahrer[playerid][pmi_Checkpoint]++;
DisablePlayerCheckpoint(playerid);
new
playercp = Busfahrer[playerid][pmi_Checkpoint];
if(playercp == sizeof(Bus_Stationen)) {
Busfahrer[playerid][pmi_bAktiv]=false;
// Extra code
SendClientMessage(playerid, COLOR_GREEN, "Super Arbeit,du hast die bürger hervorragend transportiert");
GivePlayerMoney(playerid, 2000);
}
else {
new
String[128];
PlayerPlaySound(playerid,1056,0.0,0.0,0.0);
format(String,sizeof(String),"Weiter so,du hast es fasst geschafft ! (%d / %d)",playercp,sizeof(Bus_Stationen));
SendClientMessage(playerid,COLOR_LIGHTGREEN,String);
SetPlayerCheckpoint(playerid,Bus_Stationen[playercp][B_fX],Bus_Stationen[playercp][B_fY],Bus_Stationen[playercp][B_fZ],Bus_Stationen[playercp][B_fRad]);
}
return 1;
}
return 1;
}
aus einem Tutorial und beim compelieren erscheint folgende Fehlermeldung:
DRP.p(8358) : error 029: invalid expression, assumed zero
DRP.p(8358) : error 004: function "Streamer_OnFilterScriptInit" is not implemented
DRP.p(8365) : warning 225: unreachable code
DRP.p(8365) : error 029: invalid expression, assumed zero
DRP.p(8365) : error 017: undefined symbol "cmdtext"
DRP.p(8366) : error 017: undefined symbol "cmdtext"
DRP.p(8388) : warning 225: unreachable code
DRP.p(8388) : error 029: invalid expression, assumed zero
DRP.p(8388) : error 001: expected token: ";", but found "{"
Also wie kann ich die Probleme beheben ?
Ich hoffe auf eine schnelle Antwort