removed imports of NetworkMod, changed getCollidingBoundingBoxes to addCollidingBlockToList

This commit is contained in:
Krapht 2012-08-11 23:36:38 +02:00
parent f7c5262c09
commit d8b4f0d552
17 changed files with 34 additions and 31 deletions

View file

@ -31,7 +31,7 @@ import net.minecraft.src.StringTranslate;
import net.minecraft.src.World; import net.minecraft.src.World;
import net.minecraft.src.WorldClient; import net.minecraft.src.WorldClient;
import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraft.src.forge.NetworkMod;
import cpw.mods.fml.client.SpriteHelper; import cpw.mods.fml.client.SpriteHelper;
import cpw.mods.fml.common.FMLCommonHandler; import cpw.mods.fml.common.FMLCommonHandler;

View file

@ -12,7 +12,7 @@ package buildcraft;
import buildcraft.BuildCraftBuilders; import buildcraft.BuildCraftBuilders;
import buildcraft.builders.ClientBuilderHook; import buildcraft.builders.ClientBuilderHook;
import buildcraft.core.DefaultProps; import buildcraft.core.DefaultProps;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftBuilders extends NetworkMod { public class mod_BuildCraftBuilders extends NetworkMod {

View file

@ -21,7 +21,7 @@ import net.minecraft.src.RenderBlocks;
import net.minecraft.src.RenderItem; import net.minecraft.src.RenderItem;
import net.minecraft.src.Tessellator; import net.minecraft.src.Tessellator;
import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraft.src.forge.NetworkMod;
import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL11;

View file

@ -22,7 +22,7 @@ import buildcraft.mod_BuildCraftCore.EntityRenderIndex;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.World; import net.minecraft.src.World;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftEnergy extends NetworkMod { public class mod_BuildCraftEnergy extends NetworkMod {

View file

@ -26,7 +26,7 @@ import buildcraft.factory.TileTank;
import buildcraft.mod_BuildCraftCore.EntityRenderIndex; import buildcraft.mod_BuildCraftCore.EntityRenderIndex;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftFactory extends NetworkMod { public class mod_BuildCraftFactory extends NetworkMod {

View file

@ -13,7 +13,7 @@ import net.minecraft.src.Block;
import net.minecraft.src.IBlockAccess; import net.minecraft.src.IBlockAccess;
import net.minecraft.src.RenderBlocks; import net.minecraft.src.RenderBlocks;
import net.minecraft.src.Tessellator; import net.minecraft.src.Tessellator;
import net.minecraft.src.forge.NetworkMod;
import org.lwjgl.opengl.GL11; import org.lwjgl.opengl.GL11;

View file

@ -23,7 +23,7 @@ import net.minecraft.src.ModLoader;
import net.minecraft.src.RenderBlocks; import net.minecraft.src.RenderBlocks;
import net.minecraft.src.TileEntity; import net.minecraft.src.TileEntity;
import net.minecraftforge.client.MinecraftForgeClient; import net.minecraftforge.client.MinecraftForgeClient;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftTransport extends NetworkMod { public class mod_BuildCraftTransport extends NetworkMod {

View file

@ -26,7 +26,7 @@ import net.minecraft.src.ItemStack;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.Packet; import net.minecraft.src.Packet;
import net.minecraft.src.World; import net.minecraft.src.World;
import net.minecraft.src.forge.NetworkMod;
public class CoreProxy { public class CoreProxy {

View file

@ -10,7 +10,7 @@
package buildcraft; package buildcraft;
import buildcraft.core.DefaultProps; import buildcraft.core.DefaultProps;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftBuilders extends NetworkMod { public class mod_BuildCraftBuilders extends NetworkMod {

View file

@ -16,7 +16,7 @@ import buildcraft.core.DefaultProps;
import net.minecraft.server.MinecraftServer; import net.minecraft.server.MinecraftServer;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftCore extends NetworkMod { public class mod_BuildCraftCore extends NetworkMod {

View file

@ -16,7 +16,7 @@ import buildcraft.energy.TileEngine;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.World; import net.minecraft.src.World;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftEnergy extends NetworkMod { public class mod_BuildCraftEnergy extends NetworkMod {

View file

@ -10,7 +10,7 @@
package buildcraft; package buildcraft;
import buildcraft.core.DefaultProps; import buildcraft.core.DefaultProps;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftFactory extends NetworkMod { public class mod_BuildCraftFactory extends NetworkMod {

View file

@ -10,7 +10,7 @@
package buildcraft; package buildcraft;
import buildcraft.core.DefaultProps; import buildcraft.core.DefaultProps;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftSilicon extends NetworkMod { public class mod_BuildCraftSilicon extends NetworkMod {

View file

@ -12,7 +12,7 @@ package buildcraft;
import buildcraft.core.DefaultProps; import buildcraft.core.DefaultProps;
import net.minecraft.src.ModLoader; import net.minecraft.src.ModLoader;
import net.minecraft.src.TileEntity; import net.minecraft.src.TileEntity;
import net.minecraft.src.forge.NetworkMod;
public class mod_BuildCraftTransport extends NetworkMod { public class mod_BuildCraftTransport extends NetworkMod {

View file

@ -8,7 +8,7 @@ import buildcraft.core.DefaultProps;
import net.minecraft.src.Packet; import net.minecraft.src.Packet;
import net.minecraft.src.Packet250CustomPayload; import net.minecraft.src.Packet250CustomPayload;
import net.minecraft.src.forge.packets.ForgePacket;
public abstract class BuildCraftPacket extends ForgePacket { public abstract class BuildCraftPacket extends ForgePacket {

View file

@ -10,6 +10,7 @@
package buildcraft.factory; package buildcraft.factory;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List;
import java.util.Random; import java.util.Random;
import buildcraft.BuildCraftCore; import buildcraft.BuildCraftCore;
@ -19,6 +20,7 @@ import buildcraft.core.Utils;
import net.minecraft.src.AxisAlignedBB; import net.minecraft.src.AxisAlignedBB;
import net.minecraft.src.Block; import net.minecraft.src.Block;
import net.minecraft.src.Entity;
import net.minecraft.src.IBlockAccess; import net.minecraft.src.IBlockAccess;
import net.minecraft.src.ItemStack; import net.minecraft.src.ItemStack;
import net.minecraft.src.Material; import net.minecraft.src.Material;
@ -108,38 +110,38 @@ public class BlockFrame extends Block implements IFramePipeConnection {
@SuppressWarnings("rawtypes") @SuppressWarnings("rawtypes")
@Override @Override
public void getCollidingBoundingBoxes(World world, int i, int j, int k, AxisAlignedBB axisalignedbb, ArrayList arraylist) { public void addCollidingBlockToList(World world, int i, int j, int k, AxisAlignedBB axisalignedbb, List arraylist, Entity par7Entity) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
if (Utils.checkLegacyPipesConnections(world, i, j, k, i - 1, j, k)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i - 1, j, k)) {
setBlockBounds(0.0F, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(0.0F, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkLegacyPipesConnections(world, i, j, k, i + 1, j, k)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i + 1, j, k)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, 1.0F, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, 1.0F, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j - 1, k)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j - 1, k)) {
setBlockBounds(Utils.pipeMinPos, 0.0F, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, 0.0F, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j + 1, k)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j + 1, k)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, 1.0F, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, 1.0F, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j, k - 1)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j, k - 1)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, 0.0F, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, 0.0F, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j, k + 1)) { if (Utils.checkLegacyPipesConnections(world, i, j, k, i, j, k + 1)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, 1.0F); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, 1.0F);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F); setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);

View file

@ -10,6 +10,7 @@
package buildcraft.transport; package buildcraft.transport;
import java.util.ArrayList; import java.util.ArrayList;
import java.util.List;
import java.util.Random; import java.util.Random;
import java.util.TreeMap; import java.util.TreeMap;
@ -65,40 +66,40 @@ public class BlockGenericPipe extends BlockContainer {
@SuppressWarnings("rawtypes") @SuppressWarnings("rawtypes")
@Override @Override
public void getCollidingBoundingBoxes(World world, int i, int j, int k, AxisAlignedBB axisalignedbb, ArrayList arraylist) { public void addCollidingBlockToList(World world, int i, int j, int k, AxisAlignedBB axisalignedbb, List arraylist, Entity par7Entity) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
TileEntity tile1 = world.getBlockTileEntity(i, j, k); TileEntity tile1 = world.getBlockTileEntity(i, j, k);
if (Utils.checkPipesConnections(world, tile1, i - 1, j, k)) { if (Utils.checkPipesConnections(world, tile1, i - 1, j, k)) {
setBlockBounds(0.0F, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(0.0F, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkPipesConnections(world, tile1, i + 1, j, k)) { if (Utils.checkPipesConnections(world, tile1, i + 1, j, k)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, 1.0F, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, 1.0F, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkPipesConnections(world, tile1, i, j - 1, k)) { if (Utils.checkPipesConnections(world, tile1, i, j - 1, k)) {
setBlockBounds(Utils.pipeMinPos, 0.0F, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, 0.0F, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkPipesConnections(world, tile1, i, j + 1, k)) { if (Utils.checkPipesConnections(world, tile1, i, j + 1, k)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, 1.0F, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, 1.0F, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkPipesConnections(world, tile1, i, j, k - 1)) { if (Utils.checkPipesConnections(world, tile1, i, j, k - 1)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, 0.0F, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, 0.0F, Utils.pipeMaxPos, Utils.pipeMaxPos, Utils.pipeMaxPos);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
if (Utils.checkPipesConnections(world, tile1, i, j, k + 1)) { if (Utils.checkPipesConnections(world, tile1, i, j, k + 1)) {
setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, 1.0F); setBlockBounds(Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMinPos, Utils.pipeMaxPos, Utils.pipeMaxPos, 1.0F);
super.getCollidingBoundingBoxes(world, i, j, k, axisalignedbb, arraylist); super.addCollidingBlockToList(world, i, j, k, axisalignedbb, arraylist, par7Entity);
} }
setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F); setBlockBounds(0.0F, 0.0F, 0.0F, 1.0F, 1.0F, 1.0F);