diff --git a/src/main/java/com/pahimar/ee3/command/CommandRegenEnergyValues.java b/src/main/java/com/pahimar/ee3/command/CommandRegenEnergyValues.java index 8e291685..d09634c4 100644 --- a/src/main/java/com/pahimar/ee3/command/CommandRegenEnergyValues.java +++ b/src/main/java/com/pahimar/ee3/command/CommandRegenEnergyValues.java @@ -28,7 +28,7 @@ public class CommandRegenEnergyValues extends CommandBase { @Override public int getRequiredPermissionLevel() { - return 4; + return 2; } @Override diff --git a/src/main/java/com/pahimar/ee3/command/CommandSyncEnergyValues.java b/src/main/java/com/pahimar/ee3/command/CommandSyncEnergyValues.java index 9eccb7dc..b1a58eca 100644 --- a/src/main/java/com/pahimar/ee3/command/CommandSyncEnergyValues.java +++ b/src/main/java/com/pahimar/ee3/command/CommandSyncEnergyValues.java @@ -11,7 +11,6 @@ import net.minecraft.command.CommandBase; import net.minecraft.command.ICommandSender; import net.minecraft.command.WrongUsageException; import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; import net.minecraft.util.ChatComponentTranslation; import java.util.HashMap; @@ -62,8 +61,8 @@ public class CommandSyncEnergyValues extends CommandBase } if (shouldSync) { - LogHelper.info(EnergyValueRegistry.ENERGY_VALUE_MARKER, "Syncing energy values with player '{}' at their request", commandSender.getCommandSenderName()); - PacketHandler.INSTANCE.sendTo(new MessageSyncEnergyValues(), (EntityPlayerMP) commandSender); + LogHelper.info(EnergyValueRegistry.ENERGY_VALUE_MARKER, "Syncing energy values with all players at {}'s request", commandSender.getCommandSenderName()); + PacketHandler.INSTANCE.sendToAll(new MessageSyncEnergyValues()); commandSender.addChatMessage(new ChatComponentTranslation(Messages.Commands.SYNC_ENERGY_VALUES_SUCCESS)); } else {