Navigation

Wichtiger Hinweis: Bitte ändert nicht manuell die Schriftfarbe auf schwarz sondern belasst es bei der Standardeinstellung. Somit tragt ihr dazu bei dass euer Text auch bei Verwendung unseren dunklen Forenstils noch lesbar ist!

Tipp: Ihr wollt längere Codeausschnitte oder Logfiles bereitstellen? Benutzt unseren eigenen PasteBin-Dienst Link
  • Hallo ich habe das FilterScript hier gefunden und wollte mal fragen ob das in der 03 auch geht da das Menu ja alt ist und ja auch wen ich da angebe wo ich hin will geht das Menu nicht weg was muss ich machen ?



    In diesem Moment schlafen 6,3 Millionen Menschen, 18,9 Millionen essen, 2,2 Millionen machen Liebe und 1 Dummerchen ließt meine Signatur!



  • kann es sein, dass du das ShowMenuForPlayer(navi1, playerid);
    mit HideMenuForPlayer(navi1, playerid);
    in jedem case ersetzen musst?

  • public OnPlayerExitedMenu(playerid)
    {
    TogglePlayerControllable(playerid,1);
    return 1;
    }


    Zu:
    public OnPlayerExitedMenu(playerid)
    {
    TogglePlayerControllable(playerid,1);
    HideMenuForPlayer(navi1, playerid);
    return 1;
    }

    Why do programmers always mix up Halloween and Christmas?
    Oct 31 == Dec 25


  • so hab ich jetzt aber jetzt geht das menu nicht mal mehr auf


    In diesem Moment schlafen 6,3 Millionen Menschen, 18,9 Millionen essen, 2,2 Millionen machen Liebe und 1 Dummerchen ließt meine Signatur!



  • So...


    #include <a_samp>


    new Menu:navi1;



    #define COLOR_RED 0xAA3333AA
    #define COLOR_GREEN 0x33AA33AA


    public OnFilterScriptInit() {
    for(new playerid=0; playerid<GetMaxPlayers(); playerid++)
    {
    TogglePlayerControllable(playerid,1);
    }
    }


    public OnFilterScriptExit() {
    return 1;
    }


    public OnGameModeInit()
    {
    navi1=Menu:CreateMenu("~w~Navigation",1,130,150,300);
    AddMenuItem(navi1,0," ADAC LS"); //0
    AddMenuItem(navi1,0," ADAC LV"); //1
    AddMenuItem(navi1,0," ADAC SF"); //2
    AddMenuItem(navi1,0," Biker"); //3
    AddMenuItem(navi1,0," Biker-Shop"); //4
    AddMenuItem(navi1,0," Boot-Job"); //5
    AddMenuItem(navi1,0," Taxifahrer LS"); //6
    AddMenuItem(navi1,0," Taxifahrer LV"); //7
    AddMenuItem(navi1,0," Post LS"); //8
    AddMenuItem(navi1,0," Post LV"); //9
    AddMenuItem(navi1,0," Post SF"); //10
    AddMenuItem(navi1,0,"Abbruch"); //11
    return 0;
    }


    public OnPlayerSelectedMenuRow(playerid, row)
    {
    new Menu:Now;
    Now = GetPlayerMenu(playerid);
    if(Now == navi1) {
    TogglePlayerControllable(playerid,false);
    switch(row)
    {
    case 0: {
    SetPlayerCheckpoint(playerid,-79.9094,-1135.0229,1.0781,5); // ADAC LS
    HideMenuForPlayer(navi1, playerid);
    }
    case 1: {
    SetPlayerCheckpoint(playerid,1886.0837,2339.3083,10.8203,5); // ADAC LV
    HideMenuForPlayer(navi1, playerid);
    }
    case 2: {
    SetPlayerCheckpoint(playerid,-2226.6082,286.9214,35.3203,5); // ADAC SF
    HideMenuForPlayer(navi1, playerid);
    }
    case 3: {
    SetPlayerCheckpoint(playerid,504.8405,-69.1731,998.7578,5); // BIKER PICKUP
    HideMenuForPlayer(navi1, playerid);
    }
    case 4: {
    SetPlayerCheckpoint(playerid,2131.8550,-1150.1294,24.1917,5); // Biker Shop
    HideMenuForPlayer(navi1, playerid);
    }
    case 5: {
    SetPlayerCheckpoint(playerid,-2190.0911,2414.0591,5.1563,5); // BOOT JOB
    HideMenuForPlayer(navi1, playerid);
    }
    case 6: {
    SetPlayerCheckpoint(playerid,1771.2418,-1907.2025,13.5552,5); // Taxi HQ LS
    HideMenuForPlayer(navi1, playerid);
    }
    case 7: {
    SetPlayerCheckpoint(playerid,1947.2200,2068.9106,10.8203,5); // Taxi LV
    HideMenuForPlayer(navi1, playerid);
    }
    case 8: {
    SetPlayerCheckpoint(playerid,1117.9919,-1249.7778,15.9281,5); // Post LS
    HideMenuForPlayer(navi1, playerid);
    }
    case 9: {
    SetPlayerCheckpoint(playerid,1680.8837,1760.2552,10.8285,5); // Post LV
    HideMenuForPlayer(navi1, playerid);
    }
    case 10: {
    SetPlayerCheckpoint(playerid,-2522.6191,1214.9878,37.4283,5); // Post SF
    HideMenuForPlayer(navi1, playerid);
    }
    case 11: {
    HideMenuForPlayer(navi1, playerid);
    }
    }
    }


    return 1;
    }


    public OnPlayerSpawn(playerid)
    {
    return 1;
    }


    public OnGameModeExit()
    {
    DestroyMenu(navi1);
    return 1;
    }


    public OnPlayerExitedMenu(playerid)
    {
    TogglePlayerControllable(playerid,1);
    HideMenuForPlayer(navi1, playerid);
    return 1;
    }


    public OnPlayerCommandText(playerid, cmdtext[])
    {
    if(!strcmp(cmdtext, "/navi", true)) {
    ShowMenuForPlayer(navi1, playerid);
    return 1;
    }
    return 0;
    }

    Why do programmers always mix up Halloween and Christmas?
    Oct 31 == Dec 25