Raven's Rolleplay Money Bug :/ Help Pls

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
  • PlayerInfo[playerid][pOrigin] = 1;
    SendClientMessage(playerid, COLOR_WHITE, "Du bist also Las Venturas Staats Bürger!");
    SendClientMessage(playerid, TUTFARBE, "_________________________________________");
    SendClientMessage(playerid, COLOR_GREEN, " ");
    SendClientMessage(playerid, COLOR_GREEN, "Account wurde erfolgreich erstellt!");
    RegistrationStep[playerid] = 0;
    PlayerInfo[playerid][pTut] = 1;
    PlayerInfo[playerid][pPos_x] = 1612.324;
    PlayerInfo[playerid][pPos_y] = -2330.167;
    PlayerInfo[playerid][pPos_z] = 13.5469;
    MedicBill[playerid] = 0;
    SetPlayerSpawn(playerid);
    TogglePlayerControllable(playerid, 1);
    SafeGivePlayerMoney(playerid, 500);






    public SafeGivePlayerMoney(plyid, amounttogive)
    {
    ScriptMoneyUpdated[plyid] = 1;
    new RemoveMoney = ScriptMoney[plyid] + amounttogive;
    new AddMoney = ScriptMoney[plyid] + amounttogive;
    new string[20];
    format(string, sizeof(string),"$%d",amounttogive);
    if (amounttogive < 0)
    {
    if(ReceivedMoney[plyid] == 0)
    {
    if(!IsAtTransfender(plyid) && !IsAtPaySpray(plyid))
    {
    TextDrawHideForPlayer(plyid, Textdraw52[plyid]);
    ReceivedMoney[plyid] = 1;
    TextDrawColor(Textdraw52[plyid], 0xFF0000FF);
    TextDrawSetString(Textdraw52[plyid], string);
    TextDrawShowForPlayer(plyid, Textdraw52[plyid]);
    MoneyTimer[plyid] = SetTimerEx("RedMoney",125,true,"i",plyid);
    }
    }
    else
    {
    if(!IsAtTransfender(plyid) && !IsAtPaySpray(plyid))
    {
    KillTimer(MoneyTimer[plyid]);
    ReceivedMoney[plyid] = 1;
    TextDrawHideForPlayer(plyid, Textdraw52[plyid]);
    TextDrawColor(Textdraw52[plyid], 0xFF0000FF);
    TextDrawSetString(Textdraw52[plyid], string);
    TextDrawShowForPlayer(plyid, Textdraw52[plyid]);
    MoneyTimer[plyid] = SetTimerEx("RedMoney",125,true,"i",plyid);
    }
    }
    GivePlayerMoney(plyid, amounttogive);
    ScriptMoney[plyid] = RemoveMoney;
    }
    else
    {
    if(ReceivedMoney[plyid] == 0)
    {
    if(!IsAtTransfender(plyid) && !IsAtPaySpray(plyid))
    {
    TextDrawHideForPlayer(plyid, Textdraw52[plyid]);
    ReceivedMoney[plyid] = 1;
    TextDrawColor(Textdraw52[plyid], 0x00FF00FF);
    TextDrawSetString(Textdraw52[plyid], string);
    TextDrawShowForPlayer(plyid, Textdraw52[plyid]);
    MoneyTimer[plyid] = SetTimerEx("GreenMoney",125,true,"i",plyid);
    }
    }
    else
    {
    if(!IsAtTransfender(plyid) && !IsAtPaySpray(plyid))
    {
    KillTimer(MoneyTimer[plyid]);
    ReceivedMoney[plyid] = 1;
    TextDrawHideForPlayer(plyid, Textdraw52[plyid]);
    TextDrawColor(Textdraw52[plyid], 0x00FF00FF);
    TextDrawSetString(Textdraw52[plyid], string);
    TextDrawShowForPlayer(plyid, Textdraw52[plyid]);
    MoneyTimer[plyid] = SetTimerEx("GreenMoney",125,true,"i",plyid);
    }
    }
    ScriptMoney[plyid] = AddMoney;
    GivePlayerMoney(plyid, amounttogive);
    }
    ScriptMoneyUpdated[plyid] = 0;
    return 1;
    }

    Einmal editiert, zuletzt von Möx () aus folgendem Grund: Fehler