예제 #1
0
 public Inventory getLastInventory() {
   JsonConfig conf = getPlayerConfig();
   if (!conf.contains("lastinventory")) {
     return null;
   }
   return InventoryUtil.convertStringToInventory(
       conf.getString("lastinventory"), r.mes("inventoryOfflineTitle", "%Name", name));
 }
예제 #2
0
 public void updateLastInventory() {
   JsonConfig conf = getPlayerConfig();
   conf.set(
       "lastinventory", InventoryUtil.convertInventoryToString(getOnlinePlayer().getInventory()));
   conf.save();
 }