Some hologram changes, the button wont work.
This commit is contained in:
parent
13ed4d1c22
commit
5e19889c96
8 changed files with 48 additions and 40 deletions
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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());
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -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);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue