/aduty 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
  • Hallo ich editiere zurzeit mein Godfather dann habe ich einwenig die /aduty Rang namen geändert aber inGame kommt immer noch Administrantor:


    if (strcmp(cmd, "/adminduty", true) == 0 || strcmp(cmd, "/aduty", true) == 0)
    {
    if(AdminDuty[playerid] == 0)
    {
    if(PlayerInfo[playerid][pAdmin] == 1)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Mod[playerid] = Create3DTextLabel("Probe Supporter",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Mod[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Probe Supporter -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] == 2)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Mod[playerid] = Create3DTextLabel("Supporter",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Mod[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Supporter -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] == 3)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Mod[playerid] = Create3DTextLabel("Moderator",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Mod[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Moderator -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] == 4)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Supermod[playerid] = Create3DTextLabel("Super Moderator",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Supermod[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Super Moderator -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] >=5)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Admin[playerid] = Create3DTextLabel("Administrator",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Admin[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Administrator -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] >=6)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Admin[playerid] = Create3DTextLabel("Super Administrator",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Admin[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Super Administrator -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] >=7)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Admin[playerid] = Create3DTextLabel("Servermanager",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Admin[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Servermanager -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    if(PlayerInfo[playerid][pAdmin] >=8)
    {
    SetPlayerColor(playerid,0xFFDC00FF);
    AdminDuty[playerid] = 1;
    Admin[playerid] = Create3DTextLabel("Projektleiter",0xFFDC00FF,30.0,40.0,50.0,40.0,0);
    Attach3DTextLabelToPlayer(Admin[playerid], playerid, 0.0, 0.0, 0.4);
    GetPlayerName(playerid, sendername, sizeof(sendername));
    format(string,sizeof(string),"|- Projektleiter -| %s ist nun im Dienst",sendername,playerid);
    SendClientMessageToAll(0xFFDC00FF, string);
    SetPlayerArmour(playerid, 100);
    return 1;
    }
    }
    if(AdminDuty[playerid] == 1)
    {
    SendClientMessage(playerid,COLOR_YELLOW,"{00FFAA}INFO: {FFFFFF}Du bist nun nicht mehr im Dienst.");
    Delete3DTextLabel(Admin[playerid]);
    Delete3DTextLabel(Supermod[playerid]);
    Delete3DTextLabel(Mod[playerid]);
    Delete3DTextLabel(Supporter[playerid]);
    Delete3DTextLabel(Admin[playerid]);
    Delete3DTextLabel(Supermod[playerid]);
    Delete3DTextLabel(Mod[playerid]);
    Delete3DTextLabel(Supporter[playerid]);
    AdminDuty[playerid] = 0;
    {
    if(PlayerInfo[playerid][pMember] == 1 || PlayerInfo[playerid][pLeader] == 1)
    {
    }
    else
    {
    SetPlayerColor(playerid,TEAM_HIT_COLOR);
    }
    }
    return 1;
    }
    return 1;
    }

    Was du heute kannst besorgen, das Verschiebe nicht auf Morgen.

  • Du musst aus den >= ein == machen,
    weil wenn du Level 8 bist ist es ja auch größer als 5, somit kommt bei dir immer 5, egal welchen Rang über 5 du hast ;)


    Lol schon wieder hab ich das nicht gesehen :D Danke dir bin sau verpeilt noch nicht geschlaffen ;)

    Was du heute kannst besorgen, das Verschiebe nicht auf Morgen.