示例#1
0
 public static void setScore(String name, Integer score) {
   if (Main.me.getConfig().getBoolean("MySQL.Enable")) setMySQLStats(name, "Score", score);
   else {
     Files.getPlayers().set("Players." + name + ".Score", score);
     Files.savePlayers();
   }
 }
示例#2
0
 public static void setDeaths(String name, Integer deaths) {
   if (Main.me.getConfig().getBoolean("MySQL.Enable")) setMySQLStats(name, "Deaths", deaths);
   else {
     Files.getPlayers().set("Players." + name + ".Deaths", deaths);
     Files.savePlayers();
   }
 }
示例#3
0
 public static int getScore(String name) {
   if (Main.me.getConfig().getBoolean("MySQL.Enable"))
     return Integer.valueOf(getMySQLStats(name, "Score"));
   else return Files.getPlayers().getInt("Players." + name + ".Score");
 }