Gang Problem

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
  • Hi lieber User ich bräcuhte euer Hilfe,


    SetPlayerTeamFromClass(playerid, classid)
    {
    if (classid == 106,105,107,269,270,271)
    {
    gTeam[playerid] = TEAM_GROVE;
    }
    else if (classid == 102,103,104)
    {
    gTeam[playerid] = TEAM_BALLA ;
    }
    else if (classid == 108,109,110)
    {
    gTeam[playerid] = TEAM_VAGOS;
    }
    else if (classid == 114,115,116)
    {
    gTeam[playerid] = TEAM_VATOS_LOCOS;
    }
    else if (classid == 117,118,120)
    {
    gTeam[playerid] = TEAM_TRIADEN;
    }
    else if (classid == 247,248,254)
    {
    gTeam[playerid] = TEAM_BIKER;
    }
    else if (classid == 280,281,282,283,284,288 )
    {
    gTeam[playerid] = TEAM_COPS;
    }
    else if (classid == 217)
    {
    gTeam[playerid] = TEAM_ADMIN;
    }
    }
    SetPlayerToTeamColor(playerid)
    {
    if (gTeam[playerid] == TEAM_GROVE)
    {
    SetPlayerColor(playerid, TEAM_GROVE_COLOR);
    }
    else if (gTeam[playerid] == TEAM_BALLA)
    {
    SetPlayerColor(playerid, TEAM_BALLA_COLOR);
    }
    else if (gTeam[playerid] == TEAM_VAGOS)
    {
    SetPlayerColor(playerid, TEAM_VAGOS_COLOR);
    }
    else if (gTeam[playerid], TEAM_TRIADEN_COLOR)
    {
    SetPlayerColor(playerid, TEAM_TRIADEN_COLOR;
    }
    else if (gTeam[playerid] == TEAM_BIKER)
    {
    SetPlayerColor(playerid, TEAM_BIKER_COLOR;
    }
    else if (gTeam[playerid] == TEAM_VATOS_LOCOS)
    {
    SetPlayerColor(playerid, TEAM_VATOS_LOCOS_COLOR;
    }
    else if (gTeam[playerid] == TEAM_COPS)
    {
    SetPlayerColor(playerid, TEAM_COPS_COLOR
    }
    else if (gTeam[playerid] == TEAM_ADMIN)
    {
    SetPlayerColor(playerid, TEAM_ADMIN)



    Fehlermessages :
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : warning 206: redundant test: constant expression is non-zero
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(454) : error 017: undefined symbol "gTeam"
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(454) : warning 215: expression has no effect
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(454) : error 001: expected token: ";", but found "]"
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(454) : error 029: invalid expression, assumed zero
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(454) : fatal error 107: too many error messages on one line


    Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    4 Errors.



    was habe ich falsch gemacht?
    brauche dringend hilfe

  • SetPlayerTeamFromClass(playerid, classid)
    {
    if (classid == 106 || classid == 105 || classid == 107 ||classid ==269 || classid ==270 || classid=271)
    {
    gTeam[playerid] = TEAM_GROVE;
    }
    else if (classid == 102 || classid == 103 || classid == 104)
    {
    gTeam[playerid] = TEAM_BALLA ;
    }
    else if (classid == 108 || classid == 109 || classid == 110)
    {
    gTeam[playerid] = TEAM_VAGOS;
    }
    else if (classid == 114 || classid == 115 || classid == 116)
    {
    gTeam[playerid] = TEAM_VATOS_LOCOS;
    }
    else if (classid == 117 || classid == 118 || classid == 120)
    {
    gTeam[playerid] = TEAM_TRIADEN;
    }
    else if (classid == 247 || classid == 248 || classid == 254)
    {
    gTeam[playerid] = TEAM_BIKER;
    }
    else if (classid == 281 || classid == 282 || classid == 283 || classid == 284 || classid == 288 )
    {
    gTeam[playerid] = TEAM_COPS;
    }
    else if (classid == 217)
    {
    gTeam[playerid] = TEAM_ADMIN;
    }
    }
    SetPlayerToTeamColor(playerid)
    {
    if (gTeam[playerid] == TEAM_GROVE)
    {
    SetPlayerColor(playerid, TEAM_GROVE_COLOR);
    }
    else if (gTeam[playerid] == TEAM_BALLA)
    {
    SetPlayerColor(playerid, TEAM_BALLA_COLOR);
    }
    else if (gTeam[playerid] == TEAM_VAGOS)
    {
    SetPlayerColor(playerid, TEAM_VAGOS_COLOR);
    }
    else if (gTeam[playerid], TEAM_TRIADEN_COLOR)
    {
    SetPlayerColor(playerid, TEAM_TRIADEN_COLOR;
    }
    else if (gTeam[playerid] == TEAM_BIKER)
    {
    SetPlayerColor(playerid, TEAM_BIKER_COLOR;
    }
    else if (gTeam[playerid] == TEAM_VATOS_LOCOS)
    {
    SetPlayerColor(playerid, TEAM_VATOS_LOCOS_COLOR;
    }
    else if (gTeam[playerid] == TEAM_COPS)
    {
    SetPlayerColor(playerid, TEAM_COPS_COLOR
    }
    else if (gTeam[playerid] == TEAM_ADMIN)
    {
    SetPlayerColor(playerid, TEAM_ADMIN)


    Danke für deine Hilfe aber ich habe immernoch folgende Error Messages :


    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : warning 211: possibly unintended assignment
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : error 022: must be lvalue (non-constant)
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : warning 215: expression has no effect
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : error 001: expected token: ";", but found ")"
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : error 029: invalid expression, assumed zero
    C:\Program Files\Rockstar Games\GTA San Andreas\gamemodes\Awesome_Deathmatch_testscript.pwn(452) : fatal error 107: too many error messages on one line


    Compilation aborted.Pawn compiler 3.2.3664 Copyright (c) 1997-2006, ITB CompuPhase



    4 Errors.

  • SetPlayerTeamFromClass(playerid, classid)
    {
    if (classid == 106 || classid == 105 || classid == 107 ||classid ==269 || classid ==270 || classid=271)
    {
    gTeam[playerid] = TEAM_GROVE;
    }
    else if (classid == 102 || classid == 103 || classid == 104)
    {
    gTeam[playerid] = TEAM_BALLA ;
    }
    else if (classid == 108 || classid == 109 || classid == 110)
    {
    gTeam[playerid] = TEAM_VAGOS;
    }
    else if (classid == 114 || classid == 115 || classid == 116)
    {
    gTeam[playerid] = TEAM_VATOS_LOCOS;
    }
    else if (classid == 117 || classid == 118 || classid == 120)
    {
    gTeam[playerid] = TEAM_TRIADEN;
    }
    else if (classid == 247 || classid == 248 || classid == 254)
    {
    gTeam[playerid] = TEAM_BIKER;
    }
    else if (classid == 281 || classid == 282 || classid == 283 || classid == 284 || classid == 288)
    {
    gTeam[playerid] = TEAM_COPS;
    }
    else if (classid == 217)
    {
    gTeam[playerid] = TEAM_ADMIN;
    }
    }
    SetPlayerToTeamColor(playerid)
    {
    if (gTeam[playerid] == TEAM_GROVE)
    {
    SetPlayerColor(playerid, TEAM_GROVE_COLOR);
    }
    else if (gTeam[playerid] == TEAM_BALLA)
    {
    SetPlayerColor(playerid, TEAM_BALLA_COLOR);
    }
    else if (gTeam[playerid] == TEAM_VAGOS)
    {
    SetPlayerColor(playerid, TEAM_VAGOS_COLOR);
    }
    else if (gTeam[playerid], TEAM_TRIADEN_COLOR)
    {
    SetPlayerColor(playerid, TEAM_TRIADEN_COLOR;
    }
    else if (gTeam[playerid] == TEAM_BIKER)
    {
    SetPlayerColor(playerid, TEAM_BIKER_COLOR;
    }
    else if (gTeam[playerid] == TEAM_VATOS_LOCOS)
    {
    SetPlayerColor(playerid, TEAM_VATOS_LOCOS_COLOR;
    }
    else if (gTeam[playerid] == TEAM_COPS)
    {
    SetPlayerColor(playerid, TEAM_COPS_COLOR
    }
    else if (gTeam[playerid] == TEAM_ADMIN)
    {
    SetPlayerColor(playerid, TEAM_ADMIN)



    }


    sorry wusste nicht wie das geht