Cleaup
This commit is contained in:
parent
edafda5fce
commit
f4f053679b
50 changed files with 65 additions and 79 deletions
|
@ -5,7 +5,7 @@ import dark.api.save.ISaveObj;
|
|||
import dark.api.save.NBTFileHelper;
|
||||
|
||||
/** Wrapper for data to be sent threw a network to a device
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class DataPack implements ISaveObj, Cloneable
|
||||
{
|
||||
|
|
|
@ -4,7 +4,7 @@ import universalelectricity.core.vector.Vector3;
|
|||
|
||||
/** Applied to objects that can be aimed by yaw and pitch. This is used by things like sentry guns,
|
||||
* vehicles, or mining tools.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IAimable
|
||||
{
|
||||
|
@ -12,7 +12,7 @@ public interface IAimable
|
|||
* but no farther than that. */
|
||||
public Vector3 getLook();
|
||||
|
||||
/** X pitch, Y is yaw, z is roll. Roll is almost never used*/
|
||||
/** X pitch, Y is yaw, z is roll. Roll is almost never used */
|
||||
public Vector3 getRotation();
|
||||
|
||||
/** This does not set the rotation but rather moves the current rotation by the given values */
|
||||
|
|
|
@ -2,7 +2,6 @@ package dark.api;
|
|||
|
||||
import java.util.Set;
|
||||
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
||||
/** Prefab for creating commands that most terminal entities can use
|
||||
|
|
|
@ -16,7 +16,7 @@ import dark.api.save.SaveManager;
|
|||
/** Designed to be used as a container for AccessGroups and AccessUser. If you plan to use this make
|
||||
* sure to use it correctly. This is designed to be saved separate from the world save if marked for
|
||||
* global access. Which means it can save/load at will from the world file.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class AccessProfile implements ISpecialAccess, IVirtualObject
|
||||
{
|
||||
|
|
|
@ -5,11 +5,10 @@ import java.util.HashMap;
|
|||
import java.util.List;
|
||||
import java.util.Map.Entry;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import dark.api.ITerminal;
|
||||
import dark.api.ITerminalCommand;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
|
||||
/** @author DarkGuardsman */
|
||||
public class GroupRegistry
|
||||
{
|
||||
|
@ -18,7 +17,6 @@ public class GroupRegistry
|
|||
public static final HashMap<String, List<String>> groupDefaultNodes = new HashMap();
|
||||
public static final HashMap<String, String> groupDefaultExtends = new HashMap();
|
||||
|
||||
|
||||
static
|
||||
{
|
||||
List<String> list = new ArrayList<String>();
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package dark.api.access;
|
||||
|
||||
/** Applied to tileEntities that contain an access profile that describes how the tile interacts
|
||||
* with users
|
||||
/** Applied to tileEntities that contain an access profile that describes how the tile interacts with
|
||||
* users
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IProfileContainer
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package dark.api.access;
|
||||
|
||||
|
||||
/** Constants that represent nodes by which machines and entities used in combination with
|
||||
* ISpecialAccess to limit users on what they can do. These nodes should be used in the same way by
|
||||
* all machines, entities, and other mods. Too change the meaning of the node will make it difficult
|
||||
|
|
|
@ -4,7 +4,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import universalelectricity.core.electricity.ElectricityPack;
|
||||
|
||||
/** Wrapper for storing information about electricity packets
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ElecPack extends EnergyPack
|
||||
{
|
||||
|
|
|
@ -4,7 +4,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
import dark.api.DataPack;
|
||||
|
||||
/** Container for energy data
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class EnergyPack extends DataPack
|
||||
{
|
||||
|
|
|
@ -3,12 +3,12 @@ package dark.api.energy;
|
|||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
||||
/** Applied to objects that can accept energy. Normally TileEntities
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IEnergyAcceptor extends IEnergyDevice
|
||||
{
|
||||
/** Called when this machines receives energy
|
||||
*
|
||||
*
|
||||
* @param from - direction/side the energy came from
|
||||
* @param pack - packet of energy
|
||||
* @param doReceive - true to do the task, false to simulate
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
package dark.api.energy;
|
||||
|
||||
/** Applied to objects the store energy
|
||||
*
|
||||
*
|
||||
* @author DarkGaurdsman */
|
||||
public interface IEnergyBank
|
||||
{
|
||||
|
|
|
@ -5,5 +5,4 @@ import dark.api.tilenetwork.ITileConnector;
|
|||
public interface IEnergyDevice extends ITileConnector
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -3,7 +3,7 @@ package dark.api.energy;
|
|||
import net.minecraftforge.common.ForgeDirection;
|
||||
|
||||
/** Applied to objects that can provide energy
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IEnergyProvider extends IEnergyDevice
|
||||
{
|
||||
|
|
|
@ -2,7 +2,7 @@ package dark.api.energy;
|
|||
|
||||
/** Applied to devices that have the option to run without power. Normally this option is only shown
|
||||
* to creative mode players
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IPowerLess
|
||||
{
|
||||
|
|
|
@ -4,7 +4,7 @@ import java.io.File;
|
|||
|
||||
/** Used in combination with the save manager and other managers to say this object needs to be save
|
||||
* since its not connected with the world
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IVirtualObject extends ISaveObj
|
||||
{
|
||||
|
@ -15,5 +15,4 @@ public interface IVirtualObject extends ISaveObj
|
|||
* loaded from and decide if it wants to use the location as its getSaveFile return */
|
||||
public void setSaveFile(File file);
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -4,7 +4,7 @@ import net.minecraft.entity.Entity;
|
|||
import universalelectricity.core.vector.Vector3;
|
||||
|
||||
/** Use by tiles to control the path of motion of an item threw a tile network such as items pipes
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IMotionPath
|
||||
{
|
||||
|
@ -16,7 +16,7 @@ public interface IMotionPath
|
|||
* the tile as the controller doesn't know the range of control of the tile. Though it does
|
||||
* limit itself to blocks around the entity. So if your tile only effects entities above it
|
||||
* within its bound then make sure the tile is inside those bounds
|
||||
*
|
||||
*
|
||||
* @param entity - entity in question
|
||||
* @param from - direction the entity came from
|
||||
* @return true if it can, false if something is wrong like no power, or solid side */
|
||||
|
|
|
@ -4,7 +4,7 @@ import net.minecraftforge.common.ForgeDirection;
|
|||
|
||||
/** Used on tiles that want control over what can connect to there device. It is suggest that other
|
||||
* interfaces for connection be routed threw this to reduce the need to change things
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface ITileConnector
|
||||
{
|
||||
|
|
|
@ -5,7 +5,7 @@ import java.util.Set;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
|
||||
/** Applies to objects that act as a collection of tile entities.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface ITileNetwork
|
||||
{
|
||||
|
@ -16,7 +16,7 @@ public interface ITileNetwork
|
|||
public Set<INetworkPart> getMembers();
|
||||
|
||||
/** Called when something want the network to add the tile
|
||||
*
|
||||
*
|
||||
* @param entity - tile in question
|
||||
* @param member - add it as a member if true
|
||||
* @return true if added without issue */
|
||||
|
|
|
@ -29,7 +29,7 @@ import dark.core.prefab.machine.BlockMachine;
|
|||
import dark.machines.DarkMain;
|
||||
|
||||
/** Handler to make registering all parts of a mod's objects that are loaded into the game by forge
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ModObjectRegistry
|
||||
{
|
||||
|
@ -128,7 +128,7 @@ public class ModObjectRegistry
|
|||
}
|
||||
|
||||
/** Method to get block via name
|
||||
*
|
||||
*
|
||||
* @param blockName
|
||||
* @return Block requested */
|
||||
public static Block getBlock(String blockName)
|
||||
|
@ -145,7 +145,7 @@ public class ModObjectRegistry
|
|||
}
|
||||
|
||||
/** Method to get block via id
|
||||
*
|
||||
*
|
||||
* @param blockID
|
||||
* @return Block requested */
|
||||
public static Block getBlock(int blockID)
|
||||
|
@ -189,7 +189,7 @@ public class ModObjectRegistry
|
|||
|
||||
/** Creates a new item using reflection as well runs it threw some check to activate any
|
||||
* interface methods
|
||||
*
|
||||
*
|
||||
* @param name - name to register the item with
|
||||
* @param modid - mods that the item comes from
|
||||
* @param clazz - item class
|
||||
|
@ -283,7 +283,7 @@ public class ModObjectRegistry
|
|||
}
|
||||
|
||||
/** Adds a tileEntity to be registered when this block is registered
|
||||
*
|
||||
*
|
||||
* @param name - mod name for the tileEntity, should be unique
|
||||
* @param class1 - new instance of the TileEntity to register */
|
||||
public BlockBuildData addTileEntity(String name, Class<? extends TileEntity> class1)
|
||||
|
|
|
@ -9,7 +9,7 @@ import net.minecraft.nbt.NBTTagCompound;
|
|||
* automation. As well this is not designed to replace the need for IInventory support of a tile but
|
||||
* to make it easier to manage. Suggested use it to create a prefab manager for several tiles. Then
|
||||
* have those tiles use the prefab as an extermal inventory manager to reduce code size per class.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public interface IInvBox extends ISidedInventory
|
||||
{
|
||||
|
|
|
@ -2,7 +2,6 @@ package dark.core.prefab;
|
|||
|
||||
import net.minecraft.client.renderer.texture.IconRegister;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.util.Icon;
|
||||
import net.minecraftforge.common.Configuration;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
|
|
|
@ -10,9 +10,6 @@ import net.minecraftforge.common.MinecraftForge;
|
|||
|
||||
import org.modstats.Modstats;
|
||||
|
||||
import universalelectricity.compatibility.Compatibility;
|
||||
import universalelectricity.core.UniversalElectricity;
|
||||
|
||||
import com.builtbroken.common.Triple;
|
||||
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
|
@ -20,15 +17,8 @@ import cpw.mods.fml.common.Mod.EventHandler;
|
|||
import cpw.mods.fml.common.event.FMLInitializationEvent;
|
||||
import cpw.mods.fml.common.event.FMLPostInitializationEvent;
|
||||
import cpw.mods.fml.common.event.FMLPreInitializationEvent;
|
||||
import cpw.mods.fml.common.registry.TickRegistry;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import dark.api.save.SaveManager;
|
||||
import dark.core.CoreMachine;
|
||||
import dark.core.ExternalModHandler;
|
||||
import dark.core.ModObjectRegistry;
|
||||
import dark.core.PlayerKeyHandler;
|
||||
import dark.core.prefab.fluids.FluidHelper;
|
||||
import dark.core.prefab.tilenetwork.NetworkUpdateHandler;
|
||||
|
||||
public abstract class ModPrefab
|
||||
{
|
||||
|
|
|
@ -14,7 +14,7 @@ public enum EnumGas
|
|||
METHANE(ChemicalCompound.METHANE, true),
|
||||
NATURAL_GAS("Natural Gas", false),
|
||||
PROPANE("Propane", false);
|
||||
|
||||
|
||||
/** Name used when creating this as a fluid */
|
||||
public final String fluidName;
|
||||
/** Name used to display to the players */
|
||||
|
|
|
@ -70,8 +70,8 @@ public class GuiMessageBox extends GuiBase
|
|||
@Override
|
||||
protected void drawForegroundLayer(int var2, int var3, float var1)
|
||||
{
|
||||
this.fontRenderer.drawString("" + this.title, (int) (this.guiSize.intX() / 2 - 30), 5, 4210752);
|
||||
this.fontRenderer.drawString("\u00a77" + this.message, (int) ((this.guiSize.intX() / 2) - 50), 20, 4210752);
|
||||
this.fontRenderer.drawString("" + this.title, (this.guiSize.intX() / 2 - 30), 5, 4210752);
|
||||
this.fontRenderer.drawString("\u00a77" + this.message, ((this.guiSize.intX() / 2) - 50), 20, 4210752);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -34,7 +34,7 @@ import dark.machines.DarkMain;
|
|||
/** Basic TileEntity Container class designed to be used by generic machines. It is suggested that
|
||||
* each mod using this create there own basic block extending this to reduce need to use build data
|
||||
* per block.
|
||||
*
|
||||
*
|
||||
* @author Darkguardsman */
|
||||
public abstract class BlockMachine extends BlockTile implements IExtraBlockInfo
|
||||
{
|
||||
|
|
|
@ -19,9 +19,9 @@ import dark.api.energy.IPowerLess;
|
|||
import dark.core.ExternalModHandler;
|
||||
|
||||
/** Basic energy tile that can consume power
|
||||
*
|
||||
*
|
||||
* Based off both UE universal electrical tile, and electrical tile prefabs
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public abstract class TileEntityEnergyMachine extends TileEntityMachine implements IElectrical, IElectricalStorage, IPowerLess
|
||||
{
|
||||
|
@ -262,7 +262,7 @@ public abstract class TileEntityEnergyMachine extends TileEntityMachine implemen
|
|||
}
|
||||
|
||||
/** The electrical input direction.
|
||||
*
|
||||
*
|
||||
* @return The direction that electricity is entered into the tile. Return null for no input. By
|
||||
* default you can accept power from all sides. */
|
||||
public EnumSet<ForgeDirection> getInputDirections()
|
||||
|
@ -271,7 +271,7 @@ public abstract class TileEntityEnergyMachine extends TileEntityMachine implemen
|
|||
}
|
||||
|
||||
/** The electrical output direction.
|
||||
*
|
||||
*
|
||||
* @return The direction that electricity is output from the tile. Return null for no output. By
|
||||
* default it will return an empty EnumSet. */
|
||||
public EnumSet<ForgeDirection> getOutputDirections()
|
||||
|
|
|
@ -23,7 +23,7 @@ import dark.core.prefab.invgui.InvChest;
|
|||
import dark.core.prefab.tilenetwork.NetworkTileEntities;
|
||||
|
||||
/** Prefab for simple object who only need basic inv support and nothing more
|
||||
*
|
||||
*
|
||||
* @author Darkguardsman */
|
||||
public class TileEntityInv extends TileEntityAdvanced implements IExternalInv, ISidedInventory, ISpecialAccess
|
||||
{
|
||||
|
|
|
@ -18,8 +18,8 @@ import cpw.mods.fml.common.network.PacketDispatcher;
|
|||
import cpw.mods.fml.common.network.Player;
|
||||
import dark.api.IDisableable;
|
||||
import dark.core.interfaces.IExternalInv;
|
||||
import dark.core.interfaces.IInvBox;
|
||||
import dark.core.interfaces.IExtraInfo.IExtraTileEntityInfo;
|
||||
import dark.core.interfaces.IInvBox;
|
||||
import dark.core.network.ISimplePacketReceiver;
|
||||
import dark.core.network.PacketHandler;
|
||||
import dark.machines.DarkMain;
|
||||
|
|
|
@ -16,7 +16,7 @@ import dark.core.interfaces.IMultiBlock;
|
|||
import dark.core.network.PacketHandler;
|
||||
|
||||
/** This is a multiblock to be used for blocks that are bigger than one block.
|
||||
*
|
||||
*
|
||||
* @author Calclavia */
|
||||
public class TileEntityMulti extends TileEntity implements IPacketReceiver
|
||||
{
|
||||
|
@ -118,7 +118,7 @@ public class TileEntityMulti extends TileEntity implements IPacketReceiver
|
|||
}
|
||||
|
||||
/** Determines if this TileEntity requires update calls.
|
||||
*
|
||||
*
|
||||
* @return True if you want updateEntity() to be called, false if not */
|
||||
@Override
|
||||
public boolean canUpdate()
|
||||
|
|
|
@ -5,7 +5,7 @@ import net.minecraft.tileentity.TileEntity;
|
|||
|
||||
/** NBT Container blocks to use that don't really need a tileEntity for anything other than to record
|
||||
* a few values
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TileEntityNBTContainer extends TileEntity
|
||||
{
|
||||
|
|
|
@ -16,7 +16,7 @@ import dark.machines.DarkMain;
|
|||
/** Actual block that is the sentry gun. Mainly a place holder as the sentry guns need something to
|
||||
* exist threw that is not an entity. Renders need to still be handled by the respective mod.
|
||||
* Especial item renders as this just creates the block and reservers the meta slot
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class BlockSentryGun extends BlockMachine
|
||||
{
|
||||
|
|
|
@ -16,7 +16,6 @@ import dark.api.ITerminal;
|
|||
import dark.api.access.GroupRegistry;
|
||||
import dark.core.network.PacketHandler;
|
||||
import dark.core.prefab.machine.TileEntityEnergyMachine;
|
||||
import dark.core.prefab.machine.TileEntityMachine.SimplePacketTypes;
|
||||
|
||||
/** @author Calclavia, DarkGuardsman */
|
||||
public abstract class TileEntityTerminal extends TileEntityEnergyMachine implements ITerminal
|
||||
|
|
|
@ -9,7 +9,7 @@ import dark.api.tilenetwork.INetworkPart;
|
|||
|
||||
/** Used for tile networks that only need to share power or act like a group battery that doesn't
|
||||
* store power on world save
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class NetworkSharedPower extends NetworkTileEntities implements IElectricalStorage, IPowerLess
|
||||
{
|
||||
|
@ -31,7 +31,7 @@ public class NetworkSharedPower extends NetworkTileEntities implements IElectric
|
|||
{
|
||||
if (!this.runPowerLess && this.networkMembers.contains(source))
|
||||
{
|
||||
return this.receiveElectricity(power, doFill);
|
||||
return this.receiveElectricity(power, doFill);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
@ -116,7 +116,7 @@ public class NetworkSharedPower extends NetworkTileEntities implements IElectric
|
|||
public void setEnergyStored(float energy)
|
||||
{
|
||||
this.energy = energy;
|
||||
if(this.energy > this.getMaxEnergyStored())
|
||||
if (this.energy > this.getMaxEnergyStored())
|
||||
{
|
||||
this.energy = this.getMaxEnergyStored();
|
||||
}
|
||||
|
|
|
@ -160,17 +160,17 @@ public class NetworkTileEntities implements ITileNetwork
|
|||
|
||||
/** Processing that needs too be done before the network merges. Use this to do final network
|
||||
* merge calculations and to cause network merge failure
|
||||
*
|
||||
*
|
||||
* @param network the network that is to merge with this one
|
||||
* @param part the part at which started the network merge. Use this to cause damage if two
|
||||
* networks merge with real world style failures
|
||||
*
|
||||
*
|
||||
* @return false if the merge needs to be canceled.
|
||||
*
|
||||
*
|
||||
* Cases in which the network should fail to merge are were the two networks merge with error.
|
||||
* Or, in the case of pipes the two networks merge and the merge point was destroyed by
|
||||
* combination of liquids.
|
||||
*
|
||||
*
|
||||
* Ex Lava and water */
|
||||
public boolean preMergeProcessing(ITileNetwork network, INetworkPart part)
|
||||
{
|
||||
|
|
|
@ -11,13 +11,13 @@ import dark.api.IToolReadOut.EnumTools;
|
|||
import dark.api.reciepes.MachineRecipeHandler;
|
||||
import dark.api.reciepes.ProcessorType;
|
||||
import dark.core.basics.BlockOre;
|
||||
import dark.core.basics.BlockOre.OreData;
|
||||
import dark.core.basics.EnumMaterial;
|
||||
import dark.core.basics.EnumOrePart;
|
||||
import dark.core.basics.EnumTool;
|
||||
import dark.core.basics.ItemCommonTool;
|
||||
import dark.core.basics.ItemOreDirv;
|
||||
import dark.core.basics.ItemParts;
|
||||
import dark.core.basics.BlockOre.OreData;
|
||||
import dark.core.basics.ItemParts.Parts;
|
||||
import dark.core.prefab.RecipeLoader;
|
||||
import dark.machines.deco.BlockBasalt;
|
||||
|
|
|
@ -38,6 +38,7 @@ import dark.core.DMCreativeTab;
|
|||
import dark.core.ModObjectRegistry;
|
||||
import dark.core.basics.BlockGasOre;
|
||||
import dark.core.basics.BlockOre;
|
||||
import dark.core.basics.BlockOre.OreData;
|
||||
import dark.core.basics.EnumMaterial;
|
||||
import dark.core.basics.EnumOrePart;
|
||||
import dark.core.basics.GasOreGenerator;
|
||||
|
@ -45,7 +46,6 @@ import dark.core.basics.ItemBlockOre;
|
|||
import dark.core.basics.ItemCommonTool;
|
||||
import dark.core.basics.ItemOreDirv;
|
||||
import dark.core.basics.ItemParts;
|
||||
import dark.core.basics.BlockOre.OreData;
|
||||
import dark.core.basics.ItemParts.Parts;
|
||||
import dark.core.helpers.PacketDataWatcher;
|
||||
import dark.core.network.PacketHandler;
|
||||
|
|
|
@ -68,6 +68,7 @@ public class ModelElecFurnace extends ModelMachine
|
|||
setRotation(tube3, 0F, 0F, 0F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(float f5)
|
||||
{
|
||||
body.render(f5);
|
||||
|
|
|
@ -236,6 +236,7 @@ public class ModelSteamGen extends ModelMachine
|
|||
setRotation(gaugeNeedle, -0.0174533F, 0F, -0.5759587F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(float f5)
|
||||
{
|
||||
face.render(f5);
|
||||
|
|
|
@ -173,6 +173,7 @@ public class ModelSteamTurbine extends ModelMachine
|
|||
setRotation(gaugeDieal, 0F, 0F, -2.80998F);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void render(float f5)
|
||||
{
|
||||
base.render(f5);
|
||||
|
|
|
@ -76,7 +76,7 @@ public class ItemRenderFluidCan implements IItemRenderer
|
|||
FMLClientHandler.instance().getClient().renderEngine.bindTexture((RenderBlockFluid.getFluidSheet(liquid)));
|
||||
|
||||
int cap = ((ItemFluidCan) CoreRecipeLoader.itemFluidCan).getCapacity(item);
|
||||
if(liquid.getFluid().isGaseous())
|
||||
if (liquid.getFluid().isGaseous())
|
||||
{
|
||||
cap = liquid.amount;
|
||||
}
|
||||
|
|
|
@ -66,7 +66,7 @@ public class RenderSteamGen extends RenderTileMachine
|
|||
{
|
||||
if (((TileEntityMachine) tileEntity).isFunctioning())
|
||||
{
|
||||
GL11.glRotatef(this.rot1, 0f, 1f, 0f);
|
||||
GL11.glRotatef(RenderSteamGen.rot1, 0f, 1f, 0f);
|
||||
}
|
||||
((ModelSteamTurbine) model).renderFan(0.0625F);
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ public class BlockSmallSteamGen extends BlockMachine
|
|||
{
|
||||
super.onBlockPlacedBy(world, x, y, z, entityLiving, itemStack);
|
||||
int metadata = world.getBlockMetadata(x, y, z);
|
||||
int angle = MathHelper.floor_double((entityLiving.rotationYaw * 4.0F / 360.0F) + 0.5D) & 3;
|
||||
int angle = net.minecraft.util.MathHelper.floor_double((entityLiving.rotationYaw * 4.0F / 360.0F) + 0.5D) & 3;
|
||||
world.setBlockMetadataWithNotify(x, y, z, ((metadata / 4) * 4) + angle, 3);
|
||||
}
|
||||
|
||||
|
|
|
@ -15,7 +15,7 @@ import dark.core.prefab.machine.TileEntityMachine;
|
|||
* it. Doesn't actually make steam fluid but rather simple functions. The machines above it will
|
||||
* need to call to this machines and do a check for steam. If this machines is creating steam then
|
||||
* the machine above it should function
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TileEntitySteamGen extends TileEntityMachine implements IFluidHandler
|
||||
{
|
||||
|
|
|
@ -56,6 +56,7 @@ public class TileEntitySteamPiston extends TileEntityEnergyMachine
|
|||
return this.wattsOut;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean consumePower(float watts, boolean doDrain)
|
||||
{
|
||||
return true;
|
||||
|
@ -73,11 +74,13 @@ public class TileEntitySteamPiston extends TileEntityEnergyMachine
|
|||
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumSet<ForgeDirection> getInputDirections()
|
||||
{
|
||||
return EnumSet.noneOf(ForgeDirection.class);
|
||||
}
|
||||
|
||||
@Override
|
||||
public EnumSet<ForgeDirection> getOutputDirections()
|
||||
{
|
||||
return EnumSet.allOf(ForgeDirection.class);
|
||||
|
|
|
@ -20,7 +20,7 @@ import dark.machines.DarkMain;
|
|||
|
||||
/** Small fluid can that is designed to store up to one bucket of fluid. Doesn't work like a bucket
|
||||
* as it is sealed with a pressure cap. This can is designed to work with tools or machines only.
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class ItemFluidCan extends ItemFluidContainer
|
||||
{
|
||||
|
|
|
@ -25,7 +25,7 @@ import dark.machines.CommonProxy;
|
|||
import dark.machines.DarkMain;
|
||||
|
||||
/** Block for energy storage devices
|
||||
*
|
||||
*
|
||||
* @author Rseifert */
|
||||
public class BlockEnergyStorage extends BlockMachine
|
||||
{
|
||||
|
@ -35,6 +35,7 @@ public class BlockEnergyStorage extends BlockMachine
|
|||
this.setCreativeTab(DMCreativeTab.tabIndustrial);
|
||||
}
|
||||
|
||||
@Override
|
||||
public Icon getBlockTexture(IBlockAccess world, int x, int y, int z, int side)
|
||||
{
|
||||
Vector3 vec = new Vector3(x, y, z);
|
||||
|
|
|
@ -9,12 +9,11 @@ import net.minecraft.item.ItemStack;
|
|||
import net.minecraft.nbt.NBTTagCompound;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.fluids.FluidStack;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import dark.machines.CoreRecipeLoader;
|
||||
|
||||
/** Item version of the enrgy storage block
|
||||
*
|
||||
*
|
||||
* @author Darkguardsman */
|
||||
public class ItemBlockEnergyStorage extends ItemBlock
|
||||
{
|
||||
|
@ -90,6 +89,7 @@ public class ItemBlockEnergyStorage extends ItemBlock
|
|||
return itemStack;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int getItemStackLimit(ItemStack stack)
|
||||
{
|
||||
if (stack.getTagCompound() != null && stack.getTagCompound().hasKey("wrenched"))
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package dark.machines.machines;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import dark.core.prefab.machine.TileEntityEnergyMachine;
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ package dark.machines.machines;
|
|||
|
||||
import java.util.EnumSet;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import dark.core.prefab.machine.TileEntityEnergyMachine;
|
||||
|
||||
|
|
|
@ -2,7 +2,6 @@ package dark.machines.machines;
|
|||
|
||||
import java.util.HashMap;
|
||||
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraftforge.common.ForgeDirection;
|
||||
import net.minecraftforge.fluids.Fluid;
|
||||
|
@ -12,7 +11,7 @@ import net.minecraftforge.fluids.FluidTankInfo;
|
|||
import net.minecraftforge.fluids.IFluidHandler;
|
||||
|
||||
/** Designed to debug fluid devices by draining everything that comes in at one time
|
||||
*
|
||||
*
|
||||
* @author DarkGuardsman */
|
||||
public class TileEntityVoid extends TileEntity implements IFluidHandler
|
||||
{
|
||||
|
|
Loading…
Reference in a new issue