Solved Would anyone happen to have a player database class?

Discussion in 'Plugin Development' started by megasaad44, Aug 26, 2014.

Thread Status:
Not open for further replies.
  1. Offline

    megasaad44

    I've been trying to create a player database file that creates a yml for each player and me able to get and set stuff for each player. But i couldn't work it out.
    Would anyone happen to have a class with methods such as getpdb(Player p); setpdb(Player p); etc..
     
  2. Offline

    _LB

    You should use UUIDs. Other than that I'm not sure what has you stuck.
     
  3. Offline

    megasaad44

    _LB Making a new file for every player and then getting and setting from and to that config for each player.
    I've tried at least 7 times in different manners and they all simply errored with sporadic/constant errors.
     
  4. Offline

    _LB

    Really? It shouldn't be that difficult, especially not with using YamlConfiguration.
     
  5. Offline

    megasaad44

    _LB If it isn't too difficult, then mind providing the class please? I'm sick and tired from this problem though it seemed simple...
     
  6. Offline

    _LB

    I can get a simple example set up in a bit, but asking for a full library is a bit overkill for such a trivial task.
     
  7. Offline

    megasaad44

    _LB Full library? Who said anything about that? I just need a simple class that will create a player yml for each player in a folder called player database. Would also contain getting and setting for each player ex: I'm in an interact event, i could do PlayerDatabase.getpdb(player).getBoolean/Int/String/etc(stuff);
     
  8. Offline

    mine-care

    I have such a class but I need to update it a bit :3
    Start a conversation if you want it because I will et Offtopic trying to explain how to use it plus I don't want it publicly available yet :)
     
  9. Offline

    megasaad44

    mine-care Thanks ^_^ and if _LB 's method is better / has an enhancement, I'll merge it with yours.
     
  10. Offline

    _LB

  11. Offline

    megasaad44

    _LB That looks AMAZING!
    I'll try that out. <3

    EDIT: It's PERFECT! Thank you SO much. ^-^
     
Thread Status:
Not open for further replies.

Share This Page