add fuel efficiency info for mmodebug

This commit is contained in:
nossr50 2020-08-25 14:33:31 -07:00
parent e3f21195c8
commit bfa092a67c
2 changed files with 16 additions and 2 deletions

View File

@ -1,6 +1,7 @@
Version 2.1.144 Version 2.1.144
Fixed a NPE that would happen involving taming in combat processing Fixed a NPE that would happen involving taming in combat processing
Updated hu_HU locale (thanks andris155) Updated hu_HU locale (thanks andris155)
mmodebug mode now prints some information when fuel efficiency is applied to a furnace

View File

@ -72,9 +72,22 @@ public class InventoryListener implements Listener {
return; return;
} }
// Bukkit.broadcastMessage("Debug: Modifying burn time from - "+event.getBurnTime());
boolean debugMode = player.isOnline() && UserManager.getPlayer(player).isDebugMode();
if(debugMode) {
player.sendMessage("FURNACE FUEL EFFICIENCY DEBUG REPORT");
player.sendMessage("Furnace - "+furnace.hashCode());
player.sendMessage("Furnace Type: "+furnaceBlock.getType().toString());
player.sendMessage("Burn Length before Fuel Efficiency is applied - "+event.getBurnTime());
}
event.setBurnTime(UserManager.getPlayer(player).getSmeltingManager().fuelEfficiency(event.getBurnTime())); event.setBurnTime(UserManager.getPlayer(player).getSmeltingManager().fuelEfficiency(event.getBurnTime()));
// Bukkit.broadcastMessage("Debug: New burn time "+event.getBurnTime());
if(debugMode) {
player.sendMessage("New Furnace Burn Length (after applying fuel efficiency) "+event.getBurnTime());
player.sendMessage("");
}
} }
} }