From 5e19889c966e54ded2a773e05c785b8fcbbb111b Mon Sep 17 00:00:00 2001 From: modmuss50 Date: Mon, 29 Jul 2019 15:22:48 +0100 Subject: [PATCH] Some hologram changes, the button wont work. --- .../java/techreborn/client/gui/GuiBlastFurnace.java | 11 ++++++----- .../techreborn/client/gui/GuiDistillationTower.java | 11 ++++++----- .../techreborn/client/gui/GuiFluidReplicator.java | 11 ++++++----- .../java/techreborn/client/gui/GuiFusionReactor.java | 11 ++++++----- .../techreborn/client/gui/GuiImplosionCompressor.java | 11 ++++++----- .../techreborn/client/gui/GuiIndustrialGrinder.java | 11 ++++++----- .../techreborn/client/gui/GuiIndustrialSawmill.java | 11 ++++++----- .../java/techreborn/client/gui/GuiVacuumFreezer.java | 11 ++++++----- 8 files changed, 48 insertions(+), 40 deletions(-) diff --git a/src/main/java/techreborn/client/gui/GuiBlastFurnace.java b/src/main/java/techreborn/client/gui/GuiBlastFurnace.java index 5aa086c76..60deb9fd1 100644 --- a/src/main/java/techreborn/client/gui/GuiBlastFurnace.java +++ b/src/main/java/techreborn/client/gui/GuiBlastFurnace.java @@ -30,6 +30,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -53,7 +54,7 @@ public class GuiBlastFurnace extends GuiBase { public void init() { super.init(); this.hasMultiBlock = this.blockEntity.getCachedHeat() != 0; - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -97,7 +98,7 @@ public class GuiBlastFurnace extends GuiBase { public void onClick(GuiButtonExtended button, Double x, Double y){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -142,15 +143,15 @@ public class GuiBlastFurnace extends GuiBase { this.addComponent(1, 3, 1, standardCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos( blockEntity.getPos().getX() - Direction.byId(blockEntity.getFacingInt()).getOffsetX() * 2, blockEntity.getPos().getY() - 1, blockEntity.getPos().getZ() - Direction.byId(blockEntity.getFacingInt()).getOffsetZ() * 2); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiDistillationTower.java b/src/main/java/techreborn/client/gui/GuiDistillationTower.java index 524e3c74e..c17818c0c 100644 --- a/src/main/java/techreborn/client/gui/GuiDistillationTower.java +++ b/src/main/java/techreborn/client/gui/GuiDistillationTower.java @@ -30,6 +30,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -51,7 +52,7 @@ public class GuiDistillationTower extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -91,7 +92,7 @@ public class GuiDistillationTower extends GuiBase { public void onClick(GuiButtonExtended button, Double x, Double y){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -137,15 +138,15 @@ public class GuiDistillationTower extends GuiBase { addComponent(1, 3, 1, advancedCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos( blockEntity.getPos().getX() - Direction.byId(blockEntity.getFacingInt()).getOffsetX() * 2, blockEntity.getPos().getY() - 1, blockEntity.getPos().getZ() - Direction.byId(blockEntity.getFacingInt()).getOffsetZ() * 2); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiFluidReplicator.java b/src/main/java/techreborn/client/gui/GuiFluidReplicator.java index fe41b2861..993e1c82d 100644 --- a/src/main/java/techreborn/client/gui/GuiFluidReplicator.java +++ b/src/main/java/techreborn/client/gui/GuiFluidReplicator.java @@ -29,6 +29,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -59,7 +60,7 @@ public class GuiFluidReplicator extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -101,7 +102,7 @@ public class GuiFluidReplicator extends GuiBase { // GuiScreen public void onClick(GuiButtonExtended button, Double x, Double y){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -117,8 +118,8 @@ public class GuiFluidReplicator extends GuiBase { addComponent(1, 0, 1, reinforcedCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos( this.blockEntity.getPos().getX() - Direction.byId(this.blockEntity.getFacingInt()).getOffsetX() * 2, @@ -126,7 +127,7 @@ public class GuiFluidReplicator extends GuiBase { - Direction.byId(this.blockEntity.getFacingInt()).getOffsetZ() * 2); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiFusionReactor.java b/src/main/java/techreborn/client/gui/GuiFusionReactor.java index c2651f6e3..06b796751 100644 --- a/src/main/java/techreborn/client/gui/GuiFusionReactor.java +++ b/src/main/java/techreborn/client/gui/GuiFusionReactor.java @@ -30,6 +30,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import org.apache.commons.lang3.tuple.Pair; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.builder.widget.GuiButtonUpDown; @@ -114,10 +115,10 @@ public class GuiFusionReactor extends GuiBase { public void hologramToggle(GuiButtonExtended button, double x, double y){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { updateMultiBlockRender(); } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } @@ -125,7 +126,7 @@ public class GuiFusionReactor extends GuiBase { private void sendSizeChange(int sizeDelta){ NetworkManager.sendToServer(ServerboundPackets.createPacketFusionControlSize(sizeDelta, blockEntity.getPos())); //Reset the multiblock as it will be wrong now. - if(ClientProxy.multiblockRenderEvent.currentMultiblock != null){ + if(RebornCoreClient.multiblockRenderEvent.currentMultiblock != null){ updateMultiBlockRender(); } } @@ -138,8 +139,8 @@ public class GuiFusionReactor extends GuiBase { coils.forEach(pos -> addComponent(pos.getX(), pos.getY(), pos.getZ(), coil, multiblock)); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos(blockEntity.getPos().getX(), blockEntity.getPos().getY() - 1, blockEntity.getPos().getZ()); } diff --git a/src/main/java/techreborn/client/gui/GuiImplosionCompressor.java b/src/main/java/techreborn/client/gui/GuiImplosionCompressor.java index 1195221c1..26ae2b7b8 100644 --- a/src/main/java/techreborn/client/gui/GuiImplosionCompressor.java +++ b/src/main/java/techreborn/client/gui/GuiImplosionCompressor.java @@ -29,6 +29,7 @@ import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -50,7 +51,7 @@ public class GuiImplosionCompressor extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -93,7 +94,7 @@ public class GuiImplosionCompressor extends GuiBase { public void onClick(GuiButtonExtended button, Double mouseX, Double mouseY){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -108,12 +109,12 @@ public class GuiImplosionCompressor extends GuiBase { } final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos(blockEntity.getPos().getX(), blockEntity.getPos().getY(), blockEntity.getPos().getZ()); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiIndustrialGrinder.java b/src/main/java/techreborn/client/gui/GuiIndustrialGrinder.java index f701b6311..d6d884180 100644 --- a/src/main/java/techreborn/client/gui/GuiIndustrialGrinder.java +++ b/src/main/java/techreborn/client/gui/GuiIndustrialGrinder.java @@ -30,6 +30,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -51,7 +52,7 @@ public class GuiIndustrialGrinder extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -98,7 +99,7 @@ public class GuiIndustrialGrinder extends GuiBase { public void onClick(GuiButtonExtended button, double mouseX, double mouseY){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -137,8 +138,8 @@ public class GuiIndustrialGrinder extends GuiBase { addComponent(1, 1, 1, standardCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos( this.blockEntity.getPos().getX() - Direction.byId(this.blockEntity.getFacingInt()).getOffsetX() * 2, @@ -146,7 +147,7 @@ public class GuiIndustrialGrinder extends GuiBase { - Direction.byId(this.blockEntity.getFacingInt()).getOffsetZ() * 2); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiIndustrialSawmill.java b/src/main/java/techreborn/client/gui/GuiIndustrialSawmill.java index 8b186acae..5e1628cee 100644 --- a/src/main/java/techreborn/client/gui/GuiIndustrialSawmill.java +++ b/src/main/java/techreborn/client/gui/GuiIndustrialSawmill.java @@ -30,6 +30,7 @@ import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import net.minecraft.util.math.Direction; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -51,7 +52,7 @@ public class GuiIndustrialSawmill extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -97,7 +98,7 @@ public class GuiIndustrialSawmill extends GuiBase { public void onClick(GuiButtonExtended button, Double mouseX, Double mouseY){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -136,8 +137,8 @@ public class GuiIndustrialSawmill extends GuiBase { addComponent(1, 1, 1, standardCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = new BlockPos( this.blockEntity.getPos().getX() - Direction.byId(this.blockEntity.getFacingInt()).getOffsetY() * 2, @@ -145,7 +146,7 @@ public class GuiIndustrialSawmill extends GuiBase { - Direction.byId(this.blockEntity.getFacingInt()).getOffsetY() * 2); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } } diff --git a/src/main/java/techreborn/client/gui/GuiVacuumFreezer.java b/src/main/java/techreborn/client/gui/GuiVacuumFreezer.java index a9c5a69a2..a7876afc1 100644 --- a/src/main/java/techreborn/client/gui/GuiVacuumFreezer.java +++ b/src/main/java/techreborn/client/gui/GuiVacuumFreezer.java @@ -28,6 +28,7 @@ import net.minecraft.block.BlockState; import net.minecraft.entity.player.PlayerEntity; import net.minecraft.util.math.BlockPos; import reborncore.ClientProxy; +import reborncore.RebornCoreClient; import reborncore.client.gui.builder.GuiBase; import reborncore.client.gui.builder.widget.GuiButtonExtended; import reborncore.client.gui.guibuilder.GuiBuilder; @@ -49,7 +50,7 @@ public class GuiVacuumFreezer extends GuiBase { @Override public void init() { super.init(); - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } @Override @@ -89,7 +90,7 @@ public class GuiVacuumFreezer extends GuiBase { public void onClick(GuiButtonExtended button, Double mouseX, Double mouseY){ if (GuiBase.slotConfigType == SlotConfigType.NONE) { - if (ClientProxy.multiblockRenderEvent.currentMultiblock == null) { + if (RebornCoreClient.multiblockRenderEvent.currentMultiblock == null) { { // This code here makes a basic multiblock and then sets to the selected one. final Multiblock multiblock = new Multiblock(); @@ -126,12 +127,12 @@ public class GuiVacuumFreezer extends GuiBase { addComponent(1, -3, 1, advancedCasing, multiblock); final MultiblockSet set = new MultiblockSet(multiblock); - ClientProxy.multiblockRenderEvent.setMultiblock(set); - ClientProxy.multiblockRenderEvent.parent = blockEntity.getPos(); + RebornCoreClient.multiblockRenderEvent.setMultiblock(set); + RebornCoreClient.multiblockRenderEvent.parent = blockEntity.getPos(); MultiblockRenderEvent.anchor = blockEntity.getPos().down(); } } else { - ClientProxy.multiblockRenderEvent.setMultiblock(null); + RebornCoreClient.multiblockRenderEvent.setMultiblock(null); } } }