mirror of
https://github.com/HbmMods/Hbm-s-Nuclear-Tech-GIT.git
synced 2026-01-25 10:32:49 +00:00
attempts to merge
This commit is contained in:
parent
e0433a3174
commit
9be7a1f378
@ -21,7 +21,7 @@ public class GasCentrifugeRecipes {
|
|||||||
MEUF6 (200, 100, "HEUF6", "Medium Enriched UF6", false, new ItemStack(ModItems.nugget_u238, 1)),
|
MEUF6 (200, 100, "HEUF6", "Medium Enriched UF6", false, new ItemStack(ModItems.nugget_u238, 1)),
|
||||||
HEUF6 (300, 0, "NONE", "High Enriched UF6", true, new ItemStack(ModItems.nugget_u238, 2), new ItemStack(ModItems.nugget_u235, 1), new ItemStack(ModItems.fluorite, 1)),
|
HEUF6 (300, 0, "NONE", "High Enriched UF6", true, new ItemStack(ModItems.nugget_u238, 2), new ItemStack(ModItems.nugget_u235, 1), new ItemStack(ModItems.fluorite, 1)),
|
||||||
|
|
||||||
PF6 (300, 0, "NONE", "Plutonium Hexafluoride", true, new ItemStack(ModItems.nugget_pu238, 1), new ItemStack(ModItems.nugget_pu_mix, 2), new ItemStack(ModItems.fluorite, 1));
|
PF6 (300, 0, "NONE", "Plutonium Hexafluoride", false, new ItemStack(ModItems.nugget_pu238, 1), new ItemStack(ModItems.nugget_pu_mix, 2), new ItemStack(ModItems.fluorite, 1));
|
||||||
|
|
||||||
int fluidConsumed;
|
int fluidConsumed;
|
||||||
int fluidProduced;
|
int fluidProduced;
|
||||||
|
|||||||
@ -1,29 +1,22 @@
|
|||||||
package com.hbm.tileentity.machine;
|
package com.hbm.tileentity.machine;
|
||||||
|
|
||||||
import com.hbm.inventory.recipes.CentrifugeRecipes;
|
import com.hbm.inventory.recipes.CentrifugeRecipes;
|
||||||
import com.hbm.inventory.recipes.GasCentrifugeRecipes.PseudoFluidType;
|
|
||||||
import com.hbm.lib.Library;
|
import com.hbm.lib.Library;
|
||||||
import com.hbm.packet.AuxElectricityPacket;
|
import com.hbm.packet.AuxElectricityPacket;
|
||||||
import com.hbm.packet.AuxGaugePacket;
|
|
||||||
import com.hbm.packet.LoopedSoundPacket;
|
import com.hbm.packet.LoopedSoundPacket;
|
||||||
import com.hbm.packet.PacketDispatcher;
|
import com.hbm.packet.PacketDispatcher;
|
||||||
import com.hbm.tileentity.TileEntityMachineBase;
|
import com.hbm.tileentity.TileEntityMachineBase;
|
||||||
|
|
||||||
import api.hbm.energy.IBatteryItem;
|
|
||||||
import api.hbm.energy.IEnergyUser;
|
import api.hbm.energy.IEnergyUser;
|
||||||
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
import cpw.mods.fml.common.network.NetworkRegistry.TargetPoint;
|
||||||
import cpw.mods.fml.relauncher.Side;
|
import cpw.mods.fml.relauncher.Side;
|
||||||
import cpw.mods.fml.relauncher.SideOnly;
|
import cpw.mods.fml.relauncher.SideOnly;
|
||||||
import net.minecraft.entity.player.EntityPlayer;
|
|
||||||
import net.minecraft.init.Items;
|
|
||||||
import net.minecraft.inventory.ISidedInventory;
|
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.nbt.NBTTagCompound;
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
import net.minecraft.nbt.NBTTagList;
|
|
||||||
import net.minecraft.tileentity.TileEntity;
|
import net.minecraft.tileentity.TileEntity;
|
||||||
import net.minecraft.util.AxisAlignedBB;
|
import net.minecraft.util.AxisAlignedBB;
|
||||||
|
|
||||||
public class TileEntityMachineCentrifuge extends TileEntityMachineBase implements ISidedInventory, IEnergyUser {
|
public class TileEntityMachineCentrifuge extends TileEntityMachineBase implements IEnergyUser {
|
||||||
|
|
||||||
public int progress;
|
public int progress;
|
||||||
public long power;
|
public long power;
|
||||||
@ -31,9 +24,12 @@ public class TileEntityMachineCentrifuge extends TileEntityMachineBase implement
|
|||||||
public static final int maxPower = 100000;
|
public static final int maxPower = 100000;
|
||||||
public static final int processingSpeed = 200;
|
public static final int processingSpeed = 200;
|
||||||
|
|
||||||
private static final int[] slots_top = new int[] { 0 };
|
/*
|
||||||
private static final int[] slots_bottom = new int[] { 2, 3, 4, 5 };
|
* So why do we do this now? You have a funny mekanism/thermal/whatever pipe and you want to output stuff from a side
|
||||||
private static final int[] slots_side = new int[] { 0, 1 };
|
* that isn't the bottom, what do? Answer: make all slots accessible from all sides and regulate in/output in the
|
||||||
|
* dedicated methods. Duh.
|
||||||
|
*/
|
||||||
|
private static final int[] slot_io = new int[] { 0, 2, 3, 4, 5 };
|
||||||
|
|
||||||
public TileEntityMachineCentrifuge() {
|
public TileEntityMachineCentrifuge() {
|
||||||
super(6);
|
super(6);
|
||||||
@ -43,22 +39,14 @@ public class TileEntityMachineCentrifuge extends TileEntityMachineBase implement
|
|||||||
return "container.centrifuge";
|
return "container.centrifuge";
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
|
||||||
public int[] getAccessibleSlotsFromSide(int side) {
|
|
||||||
return side == 0 ? slots_bottom : (side == 1 ? slots_top : slots_side);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean isItemValidForSlot(int i, ItemStack itemStack) {
|
public boolean isItemValidForSlot(int i, ItemStack itemStack) {
|
||||||
if(i == 2 || i == 3 || i == 4 || i == 5) {
|
return i == 0;
|
||||||
return false;
|
}
|
||||||
}
|
|
||||||
|
|
||||||
if(i == 1) {
|
@Override
|
||||||
return itemStack.getItem() instanceof IBatteryItem;
|
public int[] getAccessibleSlotsFromSide(int side) {
|
||||||
}
|
return slot_io;
|
||||||
|
|
||||||
return !(itemStack.getItem() instanceof IBatteryItem);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
@ -77,7 +65,7 @@ public class TileEntityMachineCentrifuge extends TileEntityMachineBase implement
|
|||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean canExtractItem(int i, ItemStack itemStack, int j) {
|
public boolean canExtractItem(int i, ItemStack itemStack, int j) {
|
||||||
return j != 0 || i != 1;
|
return i > 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
public int getCentrifugeProgressScaled(int i) {
|
public int getCentrifugeProgressScaled(int i) {
|
||||||
@ -223,4 +211,4 @@ public class TileEntityMachineCentrifuge extends TileEntityMachineBase implement
|
|||||||
public long getMaxPower() {
|
public long getMaxPower() {
|
||||||
return maxPower;
|
return maxPower;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
Loading…
x
Reference in New Issue
Block a user