Guten Abend,
Ich hätte eine Frage wegen einem Busfahrer Skill System.
Also wie ich weitere Linien erstellen kann.
Die Checkpoints bestehen bereits:
new Float:BusCoordinates[][3] = {
{1172.9006,-1831.8010,13.7560},//{1203.0599, -934.3010, 42.3596},
{1437.2377,-1735.7953,13.7362},//{794.1573, -1096.1975, 23.5284},
{1808.7778,-1858.0728,13.7681},//{742.7133, -1393.4297, 13.0455},
{2253.5005,-1661.5022,15.6416},//{301.2852, -1397.0028, 13.5145},
{1716.8942,-1174.8401,24.0054},//{354.8143, -1648.1133, 32.4861},
{1430.2368,-1030.3519,24.0046},//{678.2159, -1760.6434, 12.9662},
{1205.3744,-932.4528,43.0804},//{1153.5178, -1714.3553, 13.4061},
{793.4728,-1378.0250,13.8099},//{1442.5582, -1524.2251, 13.0075},
{1172.9006,-1831.8010,13.7560}//{1442.5582, -1524.2251, 13.0075},
if(dialogid==DIALOG_LINIE)
{
if(response)
{
if(listitem==0)
{
buscd[playerid] = 10;
BusCP[playerid] = 2;
pCP[playerid] = CHECKPOINT_BUSBERUF;
SetPlayerCheckpoint(playerid, BusCoordinates[0][0], BusCoordinates[0][1], BusCoordinates[0][2], 5);
SendClientMessage(playerid, COLOR_LIGHTBLUE, "Du hast die Linie Gestartet, Folge nun den Checkpoins!");
public BusCountdownTimer(playerid)
{
if(buscd[playerid] > 1)
{
new str[45];
buscd[playerid]--;
format(str, sizeof(str), "~w~haltestelle...~n~~b~%i", buscd[playerid]);
GameTextForPlayer(playerid, str, 1000, 4);
BusCountdown[playerid] = SetTimerEx("BusCountdownTimer", 1000, false, "d", playerid);
}
else
{
TogglePlayerControllable(playerid, 1);
new msg[128];
if(BusCP[playerid] < 10)
{
format(msg, sizeof(msg), "Die nächste Haltestelle Wurde dir Makiert!");
SendClientMessage(playerid, COLOR_LIGHTBLUE, msg);
SetPlayerCheckpoint(playerid, BusCoordinates[BusCP[playerid]-1][0], BusCoordinates[BusCP[playerid]-1][1], BusCoordinates[BusCP[playerid]-1][2], 5);
BusCP[playerid]++;
if(strcmp(cmd, "/linie", true) == 0)
{
if(IsPlayerConnected(playerid))
{
if(Spieler[playerid][Job] == 2)
{
if(IsPlayerInAnyVehicle(playerid))
{
new veh = GetPlayerVehicleID(playerid);
for(new i = 0;i<sizeof(buscars);i++)
{
if(veh == buscars[i])
{
ShowPlayerDialog(playerid, DIALOG_LINIE, DIALOG_STYLE_LIST, "Linien Auswahl", "Linie 1: LS Stadtlinie 1, ab Skill 0\nLinie 2: LS Stadtlinie 2, ab Skill 2", "Starten", "Abbrechen");
return 1;
}
}
new vehh = GetPlayerVehicleID(playerid);
for(new i = 0;i<sizeof(rbuscars);i++)
{
if(vehh == rbuscars[i])
{
ShowPlayerDialog(playerid, DIALOG_LINIE, DIALOG_STYLE_LIST, "Linien Auswahl", "Linie 1: LS Stadtlinie 1, ab Skill 0\nLinie 2: LS Stadtlinie 2, ab Skill 2", "Starten", "Abbrechen");
return 1;
}
}
return 1;
}
}
else return SendClientMessage(playerid, ROT, "Du bist kein Busfahrer.");
}
Bitte um Hilfe! =)
Kontakt Skype: crankkgauk