[Not Solved] Currency Code Help

Discussion in 'Plugin Development' started by AdityaTD, Feb 25, 2015.

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

    AdityaTD

    Hey guyz I was making a Economy but idk what but the config.yml isn't saving the UUID's and The Balance!

    Code: http://pastebin.com/ZSwaBPhk

    Thanks in Advance,
    - Aditya
     
  2. You never created a config file
     
  3. Offline

    AdityaTD

    It auto creates itself once someone interact with the Gold Block or if they /givecoins
    @bramhaag
     
  4. Offline

    Bluesocks

    @AdityaTD I'm not seeing any configuration file creation in the areas specified.
     
    bramhaag likes this.
  5. Offline

    AdityaTD

    Check this out! You see the Getconfig() thing? That's how it makes the config!

    Code:
            @EventHandler
            public void onJoin(PlayerJoinEvent e) {
                    Player p = e.getPlayer();
                    if (!getConfig().contains(p.getUniqueId().toString())) {
                            getConfig().set(p.getUniqueId() + ".NovaCoin", 0);
                            money.put(p.getUniqueId(), 0);
                    } else {
                            money.put(p.getUniqueId(), getConfig().getInt(p.getUniqueId() + ".NovaCoin"));
                    }
            }
     
  6. Offline

    Fuzzybear04

    Any stacktraces?
     
  7. Offline

    Gingerbreadman

    @AdityaTD You might want to do p.getUniqueId().toString()?
     
Thread Status:
Not open for further replies.

Share This Page