little cleanup and error killing
This commit is contained in:
parent
ce11ee36cc
commit
77183651d0
5 changed files with 21 additions and 53 deletions
|
@ -1,7 +1,5 @@
|
|||
package assemblyline.client;
|
||||
|
||||
import java.net.URL;
|
||||
|
||||
import net.minecraftforge.client.event.sound.SoundLoadEvent;
|
||||
import net.minecraftforge.event.ForgeSubscribe;
|
||||
import assemblyline.common.AssemblyLine;
|
||||
|
@ -17,13 +15,7 @@ public class SoundHandler
|
|||
{
|
||||
for (int i = 0; i < SOUND_FILES.length; i++)
|
||||
{
|
||||
URL url = this.getClass().getResource(AssemblyLine.DIRECTORY + AssemblyLine.SOUND_PATH + SOUND_FILES[i]);
|
||||
event.manager.soundPoolSounds.addSound(AssemblyLine.DIRECTORY_NO_SLASH + SOUND_FILES[i], url);
|
||||
|
||||
if (url == null)
|
||||
{
|
||||
System.out.println("Invalid sound file: " + SOUND_FILES[i]);
|
||||
}
|
||||
event.manager.soundPoolSounds.addSound(AssemblyLine.DIRECTORY_NO_SLASH + SOUND_FILES[i]);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -1,6 +1,7 @@
|
|||
package assemblyline.client.gui;
|
||||
|
||||
import net.minecraft.client.gui.inventory.GuiContainer;
|
||||
import net.minecraft.client.resources.ResourceLocation;
|
||||
import net.minecraft.entity.player.InventoryPlayer;
|
||||
import net.minecraft.inventory.ContainerWorkbench;
|
||||
import net.minecraft.util.StatCollector;
|
||||
|
@ -15,33 +16,26 @@ import cpw.mods.fml.relauncher.SideOnly;
|
|||
@SideOnly(Side.CLIENT)
|
||||
public class GuiAutoCrafting extends GuiContainer
|
||||
{
|
||||
private static final ResourceLocation gui_pic = new ResourceLocation(AssemblyLine.GUI_TEXTURES_PATH + "gui_crafting.png");
|
||||
|
||||
public GuiAutoCrafting(InventoryPlayer par1InventoryPlayer, World par2World, int par3, int par4, int par5)
|
||||
{
|
||||
super(new ContainerWorkbench(par1InventoryPlayer, par2World, par3, par4, par5));
|
||||
// TODO on opening if the user is not the
|
||||
// owner they can see the crafting recipes
|
||||
// but if
|
||||
// the machine is locked they can't do
|
||||
// anything with it
|
||||
// Also the need to add a locking button
|
||||
// can only be activate by the owner
|
||||
}
|
||||
|
||||
/**
|
||||
* Draw the foreground layer for the GuiContainer (everything in front of the items)
|
||||
*/
|
||||
protected void drawGuiContainerForegroundLayer()
|
||||
/** Draw the foreground layer for the GuiContainer (everything in front of the items) */
|
||||
@Override
|
||||
protected void drawGuiContainerForegroundLayer(int par1, int par2)
|
||||
{
|
||||
this.fontRenderer.drawString(StatCollector.translateToLocal("AutoCrafter"), 28, 6, 4210752);
|
||||
this.fontRenderer.drawString(StatCollector.translateToLocal("container.inventory"), 8, this.ySize - 96 + 2, 4210752);
|
||||
}
|
||||
|
||||
/**
|
||||
* Draw the background layer for the GuiContainer (everything behind the items)
|
||||
*/
|
||||
/** Draw the background layer for the GuiContainer (everything behind the items) */
|
||||
@Override
|
||||
protected void drawGuiContainerBackgroundLayer(float par1, int par2, int par3)
|
||||
{
|
||||
int var4 = this.mc.renderEngine.getTexture(AssemblyLine.GUI_TEXTURES_PATH + "gui_crafting.png");
|
||||
this.mc.func_110434_K().func_110577_a(gui_pic);
|
||||
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
|
||||
int var5 = (this.width - this.xSize) / 2;
|
||||
int var6 = (this.height - this.ySize) / 2;
|
||||
|
|
|
@ -13,8 +13,6 @@ import org.modstats.ModstatInfo;
|
|||
import org.modstats.Modstats;
|
||||
|
||||
import universalelectricity.prefab.TranslationHelper;
|
||||
import universalelectricity.prefab.multiblock.BlockMulti;
|
||||
import universalelectricity.prefab.multiblock.TileEntityMulti;
|
||||
import universalelectricity.prefab.network.PacketManager;
|
||||
import assemblyline.common.armbot.BlockArmbot;
|
||||
import assemblyline.common.armbot.TileEntityArmbot;
|
||||
|
@ -44,10 +42,9 @@ import cpw.mods.fml.common.FMLCommonHandler;
|
|||
import cpw.mods.fml.common.FMLLog;
|
||||
import cpw.mods.fml.common.Loader;
|
||||
import cpw.mods.fml.common.Mod;
|
||||
import cpw.mods.fml.common.Mod.Init;
|
||||
import cpw.mods.fml.common.Mod.EventHandler;
|
||||
import cpw.mods.fml.common.Mod.Instance;
|
||||
import cpw.mods.fml.common.Mod.Metadata;
|
||||
import cpw.mods.fml.common.Mod.PreInit;
|
||||
import cpw.mods.fml.common.ModMetadata;
|
||||
import cpw.mods.fml.common.SidedProxy;
|
||||
import cpw.mods.fml.common.event.FMLInitializationEvent;
|
||||
|
@ -56,6 +53,8 @@ import cpw.mods.fml.common.network.NetworkMod;
|
|||
import cpw.mods.fml.common.network.NetworkRegistry;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import dark.library.machine.BlockMulti;
|
||||
import dark.library.machine.TileEntityMulti;
|
||||
|
||||
@ModstatInfo(prefix = "asmline")
|
||||
@Mod(modid = AssemblyLine.CHANNEL, name = AssemblyLine.MOD_NAME, version = AssemblyLine.VERSION, dependencies = "after:BasicComponents; after:IC2", useMetadata = true)
|
||||
|
@ -129,7 +128,7 @@ public class AssemblyLine
|
|||
public static boolean REQUIRE_NO_POWER = false;
|
||||
public static boolean VINALLA_RECIPES = false;
|
||||
|
||||
@PreInit
|
||||
@EventHandler
|
||||
public void preInit(FMLPreInitializationEvent event)
|
||||
{
|
||||
FMLog.setParent(FMLLog.getLogger());
|
||||
|
@ -193,7 +192,7 @@ public class AssemblyLine
|
|||
proxy.preInit();
|
||||
}
|
||||
|
||||
@Init
|
||||
@EventHandler
|
||||
public void load(FMLInitializationEvent evt)
|
||||
{
|
||||
proxy.init();
|
||||
|
|
|
@ -11,22 +11,12 @@ import net.minecraft.entity.player.EntityPlayer;
|
|||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.vector.Vector3;
|
||||
import universalelectricity.prefab.multiblock.TileEntityMulti;
|
||||
import assemblyline.common.armbot.TileEntityArmbot;
|
||||
import assemblyline.common.imprinter.ContainerImprinter;
|
||||
import assemblyline.common.imprinter.TileEntityImprinter;
|
||||
import assemblyline.common.machine.TileEntityCrate;
|
||||
import assemblyline.common.machine.TileEntityManipulator;
|
||||
import assemblyline.common.machine.TileEntityRejector;
|
||||
import assemblyline.common.machine.belt.TileEntityConveyorBelt;
|
||||
import assemblyline.common.machine.crane.TileEntityCraneController;
|
||||
import assemblyline.common.machine.crane.TileEntityCraneRail;
|
||||
import assemblyline.common.machine.detector.TileEntityDetector;
|
||||
import assemblyline.common.machine.encoder.ContainerEncoder;
|
||||
import assemblyline.common.machine.encoder.TileEntityEncoder;
|
||||
import cpw.mods.fml.common.FMLCommonHandler;
|
||||
import cpw.mods.fml.common.network.IGuiHandler;
|
||||
import cpw.mods.fml.common.registry.GameRegistry;
|
||||
|
||||
public class CommonProxy implements IGuiHandler
|
||||
{
|
||||
|
@ -40,7 +30,7 @@ public class CommonProxy implements IGuiHandler
|
|||
|
||||
public void init()
|
||||
{
|
||||
|
||||
|
||||
}
|
||||
|
||||
private void extractZipToLocation(File zipFile, String sourceFolder, String destFolder)
|
||||
|
@ -136,16 +126,14 @@ public class CommonProxy implements IGuiHandler
|
|||
{
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Renders a laser beam from one power to another by a set color for a set time
|
||||
|
||||
/** Renders a laser beam from one power to another by a set color for a set time
|
||||
*
|
||||
* @param world - world this laser is to be rendered in
|
||||
* @param position - start vector3
|
||||
* @param target - end vector3
|
||||
* @param color - color of the beam
|
||||
* @param age - life of the beam in 1/20 secs
|
||||
*/
|
||||
* @param age - life of the beam in 1/20 secs */
|
||||
public void renderBeam(World world, Vector3 position, Vector3 target, Color color, int age)
|
||||
{
|
||||
}
|
||||
|
|
|
@ -2,23 +2,18 @@ package assemblyline.common.machine;
|
|||
|
||||
import net.minecraft.block.material.Material;
|
||||
import net.minecraft.client.renderer.texture.IconRegister;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.tileentity.TileEntity;
|
||||
import net.minecraft.util.Icon;
|
||||
import net.minecraft.world.IBlockAccess;
|
||||
import net.minecraft.world.World;
|
||||
import universalelectricity.core.electricity.ElectricityDisplay;
|
||||
import universalelectricity.core.electricity.ElectricityDisplay.ElectricUnit;
|
||||
import universalelectricity.prefab.block.BlockAdvanced;
|
||||
import assemblyline.common.AssemblyLine;
|
||||
import assemblyline.common.TabAssemblyLine;
|
||||
import cpw.mods.fml.relauncher.Side;
|
||||
import cpw.mods.fml.relauncher.SideOnly;
|
||||
import dark.core.api.INetworkPart;
|
||||
import dark.library.machine.BlockMachine;
|
||||
|
||||
public class BlockAssembly extends BlockAdvanced
|
||||
public class BlockAssembly extends BlockMachine
|
||||
{
|
||||
public Icon machine_icon;
|
||||
|
||||
|
|
Loading…
Reference in a new issue