mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
More fixes
Turns out, pseudomultiblocks are pretty complicated
This commit is contained in:
parent
1f073d570c
commit
1bb88b176a
@ -4,6 +4,7 @@ import java.util.Random;
|
|||||||
|
|
||||||
import com.hbm.blocks.BlockDummyable;
|
import com.hbm.blocks.BlockDummyable;
|
||||||
import com.hbm.main.MainRegistry;
|
import com.hbm.main.MainRegistry;
|
||||||
|
import com.hbm.tileentity.TileEntityProxyCombo;
|
||||||
import com.hbm.tileentity.machine.TileEntityMachineEPress;
|
import com.hbm.tileentity.machine.TileEntityMachineEPress;
|
||||||
import com.hbm.world.gen.INBTTransformable;
|
import com.hbm.world.gen.INBTTransformable;
|
||||||
|
|
||||||
@ -24,6 +25,7 @@ public class MachineEPress extends BlockDummyable implements INBTTransformable {
|
|||||||
@Override
|
@Override
|
||||||
public TileEntity createNewTileEntity(World world, int meta) {
|
public TileEntity createNewTileEntity(World world, int meta) {
|
||||||
if(meta >= 12) return new TileEntityMachineEPress();
|
if(meta >= 12) return new TileEntityMachineEPress();
|
||||||
|
if(meta >= 6) return new TileEntityProxyCombo(true, false, false);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -65,7 +67,7 @@ public class MachineEPress extends BlockDummyable implements INBTTransformable {
|
|||||||
if(entity == null)
|
if(entity == null)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
FMLNetworkHandler.openGui(player, MainRegistry.instance, 0, world, x, y, z);
|
FMLNetworkHandler.openGui(player, MainRegistry.instance, 0, world, pos[0], pos[1], pos[2]);
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@ -4,6 +4,7 @@ import java.util.Random;
|
|||||||
|
|
||||||
import com.hbm.blocks.BlockDummyable;
|
import com.hbm.blocks.BlockDummyable;
|
||||||
import com.hbm.main.MainRegistry;
|
import com.hbm.main.MainRegistry;
|
||||||
|
import com.hbm.tileentity.TileEntityProxyCombo;
|
||||||
import com.hbm.tileentity.machine.TileEntityMachinePress;
|
import com.hbm.tileentity.machine.TileEntityMachinePress;
|
||||||
import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
|
import cpw.mods.fml.common.network.internal.FMLNetworkHandler;
|
||||||
import net.minecraft.block.material.Material;
|
import net.minecraft.block.material.Material;
|
||||||
@ -20,6 +21,7 @@ public class MachinePress extends BlockDummyable {
|
|||||||
@Override
|
@Override
|
||||||
public TileEntity createNewTileEntity(World world, int meta) {
|
public TileEntity createNewTileEntity(World world, int meta) {
|
||||||
if(meta >= 12) return new TileEntityMachinePress();
|
if(meta >= 12) return new TileEntityMachinePress();
|
||||||
|
if(meta >= 6) return new TileEntityProxyCombo(true, false, false);
|
||||||
return null;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -46,7 +48,7 @@ public class MachinePress extends BlockDummyable {
|
|||||||
if(entity == null)
|
if(entity == null)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
FMLNetworkHandler.openGui(player, MainRegistry.instance, 0, world, x, y, z);
|
FMLNetworkHandler.openGui(player, MainRegistry.instance, 0, world, pos[0], pos[1], pos[2]);
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
@ -2,6 +2,7 @@ package com.hbm.render.tileentity;
|
|||||||
|
|
||||||
import org.lwjgl.opengl.GL11;
|
import org.lwjgl.opengl.GL11;
|
||||||
|
|
||||||
|
import com.hbm.blocks.BlockDummyable;
|
||||||
import com.hbm.main.ResourceManager;
|
import com.hbm.main.ResourceManager;
|
||||||
import com.hbm.render.util.RenderDecoItem;
|
import com.hbm.render.util.RenderDecoItem;
|
||||||
import com.hbm.tileentity.machine.TileEntityMachineEPress;
|
import com.hbm.tileentity.machine.TileEntityMachineEPress;
|
||||||
@ -28,7 +29,7 @@ public class RenderEPress extends TileEntitySpecialRenderer {
|
|||||||
GL11.glEnable(GL11.GL_LIGHTING);
|
GL11.glEnable(GL11.GL_LIGHTING);
|
||||||
GL11.glRotatef(180, 0F, 1F, 0F);
|
GL11.glRotatef(180, 0F, 1F, 0F);
|
||||||
|
|
||||||
switch(tileentity.getBlockMetadata()) {
|
switch(tileentity.getBlockMetadata() - BlockDummyable.offset) {
|
||||||
case 2: GL11.glRotatef(270, 0F, 1F, 0F); break;
|
case 2: GL11.glRotatef(270, 0F, 1F, 0F); break;
|
||||||
case 4: GL11.glRotatef(0, 0F, 1F, 0F); break;
|
case 4: GL11.glRotatef(0, 0F, 1F, 0F); break;
|
||||||
case 3: GL11.glRotatef(90, 0F, 1F, 0F); break;
|
case 3: GL11.glRotatef(90, 0F, 1F, 0F); break;
|
||||||
@ -50,7 +51,7 @@ public class RenderEPress extends TileEntitySpecialRenderer {
|
|||||||
GL11.glEnable(GL11.GL_LIGHTING);
|
GL11.glEnable(GL11.GL_LIGHTING);
|
||||||
GL11.glRotatef(180, 0F, 1F, 0F);
|
GL11.glRotatef(180, 0F, 1F, 0F);
|
||||||
|
|
||||||
switch(tileentity.getBlockMetadata()) {
|
switch(tileentity.getBlockMetadata() - BlockDummyable.offset) {
|
||||||
case 2: GL11.glRotatef(270, 0F, 1F, 0F); break;
|
case 2: GL11.glRotatef(270, 0F, 1F, 0F); break;
|
||||||
case 4: GL11.glRotatef(0, 0F, 1F, 0F); break;
|
case 4: GL11.glRotatef(0, 0F, 1F, 0F); break;
|
||||||
case 3: GL11.glRotatef(90, 0F, 1F, 0F); break;
|
case 3: GL11.glRotatef(90, 0F, 1F, 0F); break;
|
||||||
@ -78,7 +79,7 @@ public class RenderEPress extends TileEntitySpecialRenderer {
|
|||||||
GL11.glEnable(GL11.GL_LIGHTING);
|
GL11.glEnable(GL11.GL_LIGHTING);
|
||||||
GL11.glRotatef(180, 0F, 1F, 0F);
|
GL11.glRotatef(180, 0F, 1F, 0F);
|
||||||
|
|
||||||
switch(tileentity.getBlockMetadata()) {
|
switch(tileentity.getBlockMetadata() - BlockDummyable.offset) {
|
||||||
case 2:
|
case 2:
|
||||||
GL11.glRotatef(270, 0F, 1F, 0F); break;
|
GL11.glRotatef(270, 0F, 1F, 0F); break;
|
||||||
case 4:
|
case 4:
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user