Skip to content

Commit

Permalink
Fix debug messages
Browse files Browse the repository at this point in the history
  • Loading branch information
LXGaming committed Sep 11, 2018
1 parent 5d42ed2 commit c81c1bf
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ public static CommandResult process(AbstractCommand abstractCommand, CommandSour
return CommandResult.empty();
}

Sledgehammer.getInstance().getLogger().debug("Processing {} for {}", command.get().getPrimaryAlias().orElse("Unknown"), commandSource.getName());
Sledgehammer.getInstance().debugMessage("Processing {} for {}", command.get().getPrimaryAlias().orElse("Unknown"), commandSource.getName());
return command.get().execute(commandSource, arguments.get());
}

Expand All @@ -71,7 +71,7 @@ public static boolean registerCommand(Class<? extends AbstractCommand> commandCl

getCommands().add(command.get());
Sponge.getCommandManager().register(Sledgehammer.getInstance().getPluginContainer(), command.get(), command.get().getAliases().toArray(new String[0]));
Sledgehammer.getInstance().getLogger().debug("{} registered", commandClass.getSimpleName());
Sledgehammer.getInstance().debugMessage("{} registered", commandClass.getSimpleName());
return true;
}

Expand All @@ -82,7 +82,7 @@ public static boolean registerAlias(AbstractCommand command, String alias) {
}

command.getAliases().add(alias);
Sledgehammer.getInstance().getLogger().debug("{} registered for {}", alias, command.getClass().getSimpleName());
Sledgehammer.getInstance().debugMessage("{} registered for {}", alias, command.getClass().getSimpleName());
return true;
}

Expand All @@ -105,7 +105,7 @@ public static boolean registerCommand(AbstractCommand parentCommand, Class<? ext
}

parentCommand.getChildren().add(command.get());
Sledgehammer.getInstance().getLogger().debug("{} registered for {}", commandClass.getSimpleName(), parentCommand.getClass().getSimpleName());
Sledgehammer.getInstance().debugMessage("{} registered for {}", commandClass.getSimpleName(), parentCommand.getClass().getSimpleName());
return true;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,7 +68,7 @@ public static boolean registerIntegration(Class<? extends AbstractIntegration> i
return false;
}

Sledgehammer.getInstance().getLogger().debug("{} registered", integrationClass.getSimpleName());
Sledgehammer.getInstance().debugMessage("{} registered", integrationClass.getSimpleName());
return true;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -42,7 +42,7 @@ private static void onCanHarvestBlock(Block block, EntityPlayer entityPlayer, IB
// Prevents ClassCastException caused by Sponge assuming the IBlockAccess is an instanceof IMixinWorld
if (!PhaseTracker.getInstance().getCurrentPhaseData().state.isInteraction() && !(blockAccess instanceof World)) {
callbackInfoReturnable.setReturnValue(false);
Sledgehammer.getInstance().getLogger().debug("Harvest denied at {}, {}, {}", blockPos.getX(), blockPos.getY(), blockPos.getZ());
Sledgehammer.getInstance().debugMessage("Harvest denied at {}, {}, {}", blockPos.getX(), blockPos.getY(), blockPos.getZ());
}
}
}

0 comments on commit c81c1bf

Please sign in to comment.