[Hilfe]Bei Fraktions Rank

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
  • Guck mal Bitte ob das mit Fraktions Rank Richtig ist


    stock LoadAccount(playerid)
    {
    new Spielerdatei[64];
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid,name,sizeof(name));
    format(Spielerdatei,sizeof(Spielerdatei),"/Accounts/%s.txt",name);
    SetPlayerScore(playerid,dini_Int(Spielerdatei,"Level"));
    GivePlayerMoney(playerid,dini_Int(Spielerdatei,"Geld"));
    SetPVarInt(playerid,"Job",dini_Int(Spielerdatei,"Job"));
    SetPVarInt(playerid,"Adminlevel",dini_Int(Spielerdatei,"Adminlevel"));
    SetPVarInt(playerid,"Fraktion",dini_Int(Spielerdatei,"Fraktion"));
    SetPVarInt(playerid,"Rank",dini_Int(Spielerdatei,"Fraktionsrang"));
    SetPVarInt(playerid,"Baned",dini_Int(Spielerdatei,"Baned"));
    SetPVarInt(playerid,"Paytime",dini_Int(Spielerdatei,"Paytime"));
    if(GetPVarInt(playerid,"Baned")==1)
    {
    SendClientMessage(playerid,ROT,"Du bist vom Server gebannt.");
    Kick(playerid);
    }
    SetPVarInt(playerid,"loggedin",1);
    return 1;
    }



    stock PlayerRank(playerid,fraktid)
    {
    if(GetPVarInt(playerid,"Fraktionsrang")==Rank)return 1;
    return 0;
    }


    stock SpielerSpeichern(playerid)
    {
    if(GetPVarInt(playerid,"loggedin")==1)
    {
    new Spielerdatei[64];
    new name[MAX_PLAYER_NAME];
    GetPlayerName(playerid,name,sizeof(name));
    format(Spielerdatei,sizeof(Spielerdatei),"/Accounts/%s.txt",name);
    dini_IntSet(Spielerdatei,"Level",GetPlayerScore(playerid));
    dini_IntSet(Spielerdatei,"Geld",GetPlayerMoney(playerid));
    dini_IntSet(Spielerdatei,"Job",GetPVarInt(playerid,"Job"));
    dini_IntSet(Spielerdatei,"Adminlevel",GetPVarInt(playerid,"Adminlevel"));
    dini_IntSet(Spielerdatei,"Fraktion",GetPVarInt(playerid,"Fraktion"));
    dini_IntSet(Spielerdatei,"Rank",GetPVarInt(playerid,"Fraktionsrang"));
    dini_IntSet(Spielerdatei,"Baned",GetPVarInt(playerid,"Baned"));
    dini_IntSet(Spielerdatei,"timeban",GetPVarInt(playerid,"timeban"));
    dini_IntSet(Spielerdatei,"Paytime",GetPVarInt(playerid,"Paytime"));
    }
    return 1;
    }


    stock PlayerRank(playerid,fraktid)
    {
    if(GetPVarInt(playerid,"Fraktionsrang")==Rank)return 1;
    return 0;
    }


    ocmd:stats(playerid,params[])
    {
    new string[400];
    new FrakRankName[40];
    new FrakName[40];
    new AdminName[40];
    if(GetPVarInt(playerid,"Fraktion") == 1) { FrakName = fraktname1; }
    else if(GetPVarInt(playerid,"Fraktion") == 2) { FrakName = fraktname2; }
    else if(GetPVarInt(playerid,"Fraktion") == 3) { FrakName = fraktname3; }
    else if(GetPVarInt(playerid,"Fraktion") == 4) { FrakName = fraktname4; }
    else if(GetPVarInt(playerid,"Fraktion") == 5) { FrakName = fraktname5; }
    else if(GetPVarInt(playerid,"Fraktion") == 6) { FrakName = fraktname6; }
    if(GetPVarInt(playerid,"Adminlevel") == 0) { AdminName = "Kein Admin"; }
    else if(GetPVarInt(playerid,"Adminlevel") == 1) { AdminName = "Probe Supporter"; }
    else if(GetPVarInt(playerid,"Adminlevel") == 2) { AdminName = "Supporter"; }
    else if(GetPVarInt(playerid,"Adminlevel") == 3) { AdminName = "Admin"; }
    else if(GetPVarInt(playerid,"Adminlevel") == 4) { AdminName = "Stellv Projektleiter"; }
    else if(GetPVarInt(playerid,"Adminlevel") == 5) { AdminName = "Projektleiter"; }
    if(GetPVarInt(playerid,"PlayerRank") == 1) { FrakRankName = "1"; }
    else if(GetPVarInt(playerid,"PlayerRank") == 2) { FrakRankName = "2"; }
    else if(GetPVarInt(playerid,"PlayerRank") == 3) { FrakRankName = "3"; }
    else if(GetPVarInt(playerid,"PlayerRank") == 4) { FrakRankName = "4"; }
    else if(GetPVarInt(playerid,"PlayerRank") == 5) { FrakRankName = "Co Leader"; }
    else if(GetPVarInt(playerid,"PlayerRank") == 6) { FrakRankName = "Leader"; }
    format(string,sizeof(string),"{FFFFFF}Statistiken von {FF6E00}%s{FFFFFF}\n\n{FF6E00}Name {FFFFFF}[%s] \n{FF6E00}Kills {FFFFFF}[%d] \n{FF6E00}Adminlevel {FFFFFF}[%s] \n{FF6E00}Geld {FFFFFF}[%d]{FF6E00}\nJob {FFFFFF}[%s]\n{FF6E00}Fraktion{FFFFFF} [%s]\n{FF6E00}FraktionRank{FFFFFF} [%s]",SpielerName(playerid),SpielerName(playerid),GetPlayerScore(playerid),AdminName,GetPlayerMoney(playerid),FrakRankName,GetPVarInt(playerid,"Job"),FrakName);
    ShowPlayerDialog(playerid, DIALOG_STATS, DIALOG_STYLE_MSGBOX, "Informationen", string, "Schließen", "");
    return 1;
    }


    Guck mal bitte das Bild an dann Wist ihr schon was ich damit meine http://www.imagebanana.com/view/70tn4pja/samp009.png