Hilfe ich habe 23 errors?

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
  • if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_LSCOP); // Copfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_LSCOP); // Blau
    }
    }
    if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_SFCOP); // Copfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_SFCOP); // Blau
    }
    }
    if(PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_ARMY); // ARMYfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_ARMY); // Dunkelgrün
    }
    }
    if(PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pLeader] == 4) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_MEDIC); // Medicfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_MEDIC); // Blau
    }
    }
    if(PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pLeader] == 5) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_LCN); // LCNfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_LCN); // Grün-Blau
    }
    }
    if(PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pLeader] == 6) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_YAKUZA); // Yakuzafarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_YAKUZA); // Dunkelrot
    }
    }
    if(PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pLeader] == 7) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_PRAESI); // Präsidentenfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_PRAESI); // Pink
    }
    }
    if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_HITMANS); // Hitmanfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_HITMANS); // Lilablau
    }
    }
    if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_CNN); // CNNfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_CNN); // Orange
    }
    }
    if(PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pLeader] == 10) //<<<<


    SetPlayerColor(playerid,NAMECOLOR_TAXI); // Taxifarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_TAXI); // Gelb
    }
    }
    if(PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pLeader] == 11) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_LEHRER); // Fahrlehrerfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_LEHRER); // Dunkelgelb
    }
    }
    if(PlayerInfo[playerid][pMember] == 12 || PlayerInfo[playerid][pLeader] == 12) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 13 || PlayerInfo[playerid][pLeader] == 13) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_GROVE); // Grovefarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_GROVE); // Hellgrün
    }
    }
    if(PlayerInfo[playerid][pMember] == 14 || PlayerInfo[playerid][pLeader] == 14) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_BALLAS); // Ballasfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_BALLAS); // Lila
    }
    }
    if(PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 15) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 16 || PlayerInfo[playerid][pLeader] == 16) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_AZTECAS); // AZTECASfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_AZTECAS); // Türkis
    }
    }
    if(PlayerInfo[playerid][pMember] == 18 || PlayerInfo[playerid][pLeader] == 18) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_RIVAS); // RIVASfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_RIVAS); // Grau
    }
    }
    if(PlayerInfo[playerid][pMember] == 19 || PlayerInfo[playerid][pLeader] == 19) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 20 || PlayerInfo[playerid][pLeader] == 20) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_FAF); // Terroristenfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_FAF); // Braun
    }
    }
    if(PlayerInfo[playerid][pMember] == 21 || PlayerInfo[playerid][pLeader] == 21) //<<<<
    {
    SetPlayerColor(playerid,NAMECOLOR_FBI); // FBIfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_FBI); // DunkelBlau
    }
    }
    if(PlayerInfo[playerid][pMember] == 22 || PlayerInfo[playerid][pLeader] == 22) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 23 || PlayerInfo[playerid][pLeader] == 23) //<<<<
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe // <<<
    }
    SetPlayerColor(playerid,COLOR_WHITE); //
    }
    }
    if(PlayerInfo[playerid][pMember] == 24 || PlayerInfo[playerid][pLeader] == 24) //<<<< Das hier ist die zeile 12898
    {
    SetPlayerColor(playerid,NAMECOLOR_Ordnungsamt); // Ordnungsamtfarbe // <<<
    }
    SetPlayerColor(playerid,NAMECOLOR_Ordnungsamt); // Dunkelhellblau
    }
    }



    wäre nett wenn mir jemand sagen könnte was falsch ist ? bitte nicht so starke kritik :D ist immerhin der 1. versuch :D

  • Hey Wo haste den Die Zeilen drinne stehen wo die Errors Kommen???
    Haste die Farben Defeniert...
    Und Die anderen Sachen Defeniert.?

  • bei

    Zitat

    public OnGameModeInit()

    wies im tutorial standt


    farben sind definiert



    #define NAMECOLOR_LSCOP 0x1E90FF00
    #define NAMECOLOR_SFCOP 0x1E90FF00
    #define NAMECOLOR_FBI 0x3393BEAA
    #define NAMECOLOR_ARMY 0x005400FF
    #define NAMECOLOR_TAXI 0xFFFF00FF
    #define NAMECOLOR_MEDIC 0xFF0000FF
    #define NAMECOLOR_PRAESI 0xFF76FFFF
    #define NAMECOLOR_PRAESI_SCHUTZ 0xFFC7FFFF
    #define NAMECOLOR_YAKUZA 0x6F0000FF
    #define NAMECOLOR_LCN 0x005459FF
    #define NAMECOLOR_CNN 0xFF9300FF
    #define NAMECOLOR_LEHRER 0x00FF0098
    #define NAMECOLOR_VAGOS 0xCC77E8AA
    #define NAMECOLOR_GROVE 0x00FF0098
    #define NAMECOLOR_BALLAS 0x6E00FFFF
    #define NAMECOLOR_RIVAS 0x787878FF
    #define NAMECOLOR_FAF 0xCC0000AA
    #define NAMECOLOR_AZTECAS 0x00FFFFFF
    #define NAMECOLOR_HITMANS 0x070C5E98
    #define NAMECOLOR_Ordnungsamt 0x00C3FFFF


    wie meinste das die anderen sachen?

  • Doppelpost ist Verboten, nächstemal gibt es eine Verwarnung!
    Bei immer der Selben Abfrage die erste mit if und die restlichen immer mit else if
    Außerdem solltest du auf Klammern achten und dir die Strukur überlegen.
    Sehen und lernen, Ich weiß nicht was vor dem ersten if kommt, kann sein das du die weite nach rechts mit Tab nochmal anpassen musst (Alles markieren & 1x Tabulator Taste)

    //
    if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)
    {
    SetPlayerColor(playerid,NAMECOLOR_LSCOP); // Copfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 2 || PlayerInfo[playerid][pLeader] == 2)
    {
    SetPlayerColor(playerid,NAMECOLOR_SFCOP); // Copfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 3 || PlayerInfo[playerid][pLeader] == 3)
    {
    SetPlayerColor(playerid,NAMECOLOR_ARMY); // ARMYfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 4 || PlayerInfo[playerid][pLeader] == 4)
    {
    SetPlayerColor(playerid,NAMECOLOR_MEDIC); // Medicfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 5 || PlayerInfo[playerid][pLeader] == 5)
    {
    SetPlayerColor(playerid,NAMECOLOR_LCN); // LCNfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 6 || PlayerInfo[playerid][pLeader] == 6)
    {
    SetPlayerColor(playerid,NAMECOLOR_YAKUZA); // Yakuzafarbe
    }
    else if(PlayerInfo[playerid][pMember] == 7 || PlayerInfo[playerid][pLeader] == 7)
    {
    SetPlayerColor(playerid,NAMECOLOR_PRAESI); // Präsidentenfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 8 || PlayerInfo[playerid][pLeader] == 8)
    {
    SetPlayerColor(playerid,NAMECOLOR_HITMANS); // Hitmanfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 9 || PlayerInfo[playerid][pLeader] == 9)
    {
    SetPlayerColor(playerid,NAMECOLOR_CNN); // CNNfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 10 || PlayerInfo[playerid][pLeader] == 10)
    {
    SetPlayerColor(playerid,NAMECOLOR_TAXI); // Taxifarbe
    }
    else if(PlayerInfo[playerid][pMember] == 11 || PlayerInfo[playerid][pLeader] == 11)
    {
    SetPlayerColor(playerid,NAMECOLOR_LEHRER); // Fahrlehrerfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 12 || PlayerInfo[playerid][pLeader] == 12)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 13 || PlayerInfo[playerid][pLeader] == 13)
    {
    SetPlayerColor(playerid,NAMECOLOR_GROVE); // Grovefarbe
    }
    else if(PlayerInfo[playerid][pMember] == 14 || PlayerInfo[playerid][pLeader] == 14)
    {
    SetPlayerColor(playerid,NAMECOLOR_BALLAS); // Ballasfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 15 || PlayerInfo[playerid][pLeader] == 15)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 16 || PlayerInfo[playerid][pLeader] == 16)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 17 || PlayerInfo[playerid][pLeader] == 17)
    {
    SetPlayerColor(playerid,NAMECOLOR_AZTECAS); // AZTECASfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 18 || PlayerInfo[playerid][pLeader] == 18)
    {
    SetPlayerColor(playerid,NAMECOLOR_RIVAS); // RIVASfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 19 || PlayerInfo[playerid][pLeader] == 19)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 20 || PlayerInfo[playerid][pLeader] == 20)
    {
    SetPlayerColor(playerid,NAMECOLOR_FAF); // Terroristenfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 21 || PlayerInfo[playerid][pLeader] == 21)
    {
    SetPlayerColor(playerid,NAMECOLOR_FBI); // FBIfarbe
    }
    else if(PlayerInfo[playerid][pMember] == 22 || PlayerInfo[playerid][pLeader] == 22)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 23 || PlayerInfo[playerid][pLeader] == 23)
    {
    SetPlayerColor(playerid,COLOR_WHITE); // farbe
    }
    else if(PlayerInfo[playerid][pMember] == 24 || PlayerInfo[playerid][pLeader] == 24)
    {
    SetPlayerColor(playerid,NAMECOLOR_Ordnungsamt); // Ordnungsamtfarbe
    }
    //Rest vom public