Player Ranks

Player ranks and stats database

Total Downloads: 4,866 - First Release: Mar 4, 2017 - Last Update: May 29, 2018

5/5, 19 likes
  1. Hi Steenamaroo,

    I'm in trouble with the collect of Economics balances via MySQL.
    The balance of a player is always saved to 0.

    I've tried to :
    • Delete every PlayerRanks files (Plugins, Data, Lang, ...) and Economics files and reinstall them (Economics before PlayerRanks) =same result
    • I've tried to unload every plugins related to Economics = same result
    • I've tried to change your code :
    Code:
    //Original
    if (Economics)
                        data.PlayerRankData[player.userID].Economics = Convert.ToInt32(Economics?.CallHook("GetPlayerMoney", player.userID));//"Modified"
    if (Economics)
                        data.PlayerRankData[player.userID].Economics = Convert.ToInt32(Economics?.CallHook("Balance", player.userID));
    
    Sometimes it seem to be working for 5 minutes and suddenly the balance go back to 0 but most of the time it doesn't work

    What you need to know :
    • I save PlayerRanks datas to my MySQL server every minute
    • I've "modified" Economics code to save player balances every 3 minutes with a timer
    • I use PlayerRanks v1.3.7 (Oxide) and Economics v3.5.0 (uMod)
    Thanks for your help ! :)
     
  2. Hey,
    Thanks for letting me know. I'll look into it and make sure it's working again in next version.

    This plug is in the queue to be migrated to umod.org, so I guess the next update will be there.
     
  3. No problem, I'll stay tunned and thanks for the fast reply! ;)
     
  4. Hey, thanks again for pointing that out.
    Not sure when 'GetPlayerMoney' ceased to exist but 'Balance' is working here, for me.

    I've changed the way PR saves, so Economics (along with PlayTime, last active date etc) all get updated every time the plug saves.
     
  5. Perfect!
    Do you have upcoming date for the new version of PR ?

    Again, thanks for your reply!
     
  6. I've gone for a full rewrite with a much more developed UI, clans support, and SQL that actually works. :p
    Want to test it to death first so it may be a little while.

    If you were to remove the following, economics will either update, or do nothing.
    Might help in the mean time?

    Code:
    else               
    data.PlayerRankData[player.userID].Economics = 0;