2 (3) 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
  • Hallo,
    bekomme immer 2-3 Errors bei meinem Callback OnPlayerPickUpPickUp.
    Und dazu noch viele Warnings. Vielleicht weiß ja jemand weiter ...


    public OnPlayerPickUpPickup(playerid, pickupid)
    {
    if(pickupid == w1flag1 || pickupid == w1flag2 || pickupid == w1flag3 || pickupid == w2flag1 || pickupid == w2flag2
    || pickupid == w2flag3 || pickupid == w3flag1 || pickupid == w3flag2 || pickupid == w3flag3 || pickupid == w4flag1
    || pickupid == w4flag2 || pickupid == w4flag3 || pickupid == w5flag1 || pickupid == w5flag2 || pickupid == w5flag3
    || pickupid == w7flag1 || pickupid == w7flag2 || pickupid == w7flag3
    || pickupid == w8flag1 || pickupid == w8flag2 || pickupid == w8flag3 || pickupid == w9flag1
    || pickupid == w9flag2 || pickupid == w9flag3 || pickupid == w10flag1 || pickupid == w10flag2
    || pickupid == w10flag3 ||) // Check that the pickup ID of the pickup they picked up is mypickup
    {
    if(flags[playerid] == 0)
    {
    SendClientMessageToAll(COLOR_GREEN, "%d has found a flag!",GetPlayerName(playerid)); // Message the player
    GivePlayerMoney(playerid, 1000); // Give the player the money
    flags[playerid] = 1;
    }
    if(flags[playerid] = 1)
    {
    SendClientMessageToAll(COLOR_GREEN, "%d has found the second flag!",GetPlayerName(playerid)); // Message the player
    GivePlayerMoney(playerid, 2500); // Give the player the money
    flags[playerid] = 2;
    }
    if(flags[playerid] == 2)
    {
    SendClientMessageToAll(COLOR_GREEN, "%d has found the last flag!",GetPlayerName(playerid)); // Message the player
    GivePlayerMoney(playerid, 5000); // Give the player the money
    flags[playerid] = 0;
    if(gTeam[playerid] == 0)
    {
    SendClientMessageToAll(COLOR_RED, "The Mafia has won this battle."); // Message the player
    }
    if(gTeam[playerid] == 1)
    {
    SendClientMessageToAll(COLOR_MAFIA, "The FBI has won this battle."); // Message the player
    }
    }
    // if you need to add more pickups, simply do this:
    else
    {
    SendClientMessage(playerid,COLOR_WHITE,"Test");
    }
    return 1;
    }

  • Ja, musst du schon, tut mir leid. :)


    Nein, hier: xD


    C:\Documents and Settings\111\Desktop\omafia.pwn(1044) : error 029: invalid expression, assumed zero
    C:\Documents and Settings\111\Desktop\omafia.pwn(1046) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1048) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1048) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111Desktop\omafia.pwn(1048) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1050) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1052) : warning 211: possibly unintended assignment
    C:\Documents and Settings\111\Desktop\omafia.pwn(1052) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1054) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1054) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1054) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1056) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1058) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1060) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1060) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1060) : warning 202: number of arguments does not match definition
    C:\Documents and Settings\111\Desktop\omafia.pwn(1062) : warning 213: tag mismatch
    C:\Documents and Settings\111\Desktop\omafia.pwn(1079) : error 030: compound statement not closed at the end of file (started at line 1038)
    Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    2 Errors.