diff options
| author | miozune <miozune@gmail.com> | 2023-09-10 16:26:06 +0900 |
|---|---|---|
| committer | miozune <miozune@gmail.com> | 2023-09-10 16:35:17 +0900 |
| commit | 3dfd657c27f0efe2e20841a3e93a92c7881e8f6f (patch) | |
| tree | 748a964d016d8f5d0871793f82bad8de9f339396 /src/main/java/common | |
| parent | e4f9ba57233b2bcbf4dc54d08bee52e98ebbd285 (diff) | |
| download | GT5-Unofficial-3dfd657c27f0efe2e20841a3e93a92c7881e8f6f.tar.gz GT5-Unofficial-3dfd657c27f0efe2e20841a3e93a92c7881e8f6f.tar.bz2 GT5-Unofficial-3dfd657c27f0efe2e20841a3e93a92c7881e8f6f.zip | |
Remove Space Elevator things
Diffstat (limited to 'src/main/java/common')
10 files changed, 0 insertions, 612 deletions
diff --git a/src/main/java/common/Blocks.java b/src/main/java/common/Blocks.java index f43482b909..d2fb863968 100644 --- a/src/main/java/common/Blocks.java +++ b/src/main/java/common/Blocks.java @@ -23,9 +23,6 @@ public class Blocks { public static Block jarThaumiumReinforced; public static Block jarIchor; public static Block lscLapotronicEnergyUnit; - public static Block spaceElevatorStructure; - public static Block spaceElevatorCapacitor; - public static Block spaceElevatorTether; public static Block largeHexPlate; diff --git a/src/main/java/common/TileEntities.java b/src/main/java/common/TileEntities.java index 9ad4fdb99f..0825b872f0 100644 --- a/src/main/java/common/TileEntities.java +++ b/src/main/java/common/TileEntities.java @@ -3,7 +3,6 @@ package common; import common.tileentities.GTMTE_LapotronicSuperCapacitor; import common.tileentities.GTMTE_SOFuelCellMK1; import common.tileentities.GTMTE_SOFuelCellMK2; -import common.tileentities.GTMTE_SpaceElevator; import common.tileentities.GTMTE_TFFT; import common.tileentities.GTMTE_TFFTHatch; import common.tileentities.TE_IchorJar; @@ -21,7 +20,6 @@ public class TileEntities { // public static GTMTE_ModularNuclearReactor mdr; public static GTMTE_TFFT tfft; public static GTMTE_LapotronicSuperCapacitor lsc; - public static GTMTE_SpaceElevator se; // Singleblocks public static GTMTE_TFFTHatch tfftHatch; diff --git a/src/main/java/common/blocks/Block_SpaceElevator.java b/src/main/java/common/blocks/Block_SpaceElevator.java deleted file mode 100644 index 2f491db0a4..0000000000 --- a/src/main/java/common/blocks/Block_SpaceElevator.java +++ /dev/null @@ -1,62 +0,0 @@ -package common.blocks; - -import java.util.List; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IIconRegister; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.util.IIcon; - -import common.itemBlocks.IB_SpaceElevator; - -import cpw.mods.fml.common.registry.GameRegistry; - -public class Block_SpaceElevator extends BaseGTUpdateableBlock { - - private static final Block_SpaceElevator INSTANCE = new Block_SpaceElevator(); - - private IIcon baseTop; - private IIcon baseSide; - private IIcon coilHolder; - - private Block_SpaceElevator() { - super(Material.iron); - } - - public static Block registerBlock() { - final String blockName = "kekztech_spaceelevator_block"; - INSTANCE.setBlockName(blockName); - INSTANCE.setCreativeTab(CreativeTabs.tabMisc); - INSTANCE.setHardness(7.0f); - INSTANCE.setResistance(10.0f); - GameRegistry.registerBlock(INSTANCE, IB_SpaceElevator.class, blockName); - - return INSTANCE; - } - - @Override - public void registerBlockIcons(IIconRegister ir) { - baseTop = ir.registerIcon("kekztech:SpaceElevatorBase_top"); - baseSide = ir.registerIcon("kekztech:SpaceElevatorBase_side"); - coilHolder = ir.registerIcon("kekztech:CoilHolder"); - } - - @Override - @SuppressWarnings({ "unchecked" }) - public void getSubBlocks(Item par1, CreativeTabs par2CreativeTabs, List par3List) { - par3List.add(new ItemStack(par1, 1, 0)); - par3List.add(new ItemStack(par1, 1, 1)); - } - - @Override - public IIcon getIcon(int side, int meta) { - if (meta == 0) { - return (side < 2) ? baseTop : baseSide; - } else { - return coilHolder; - } - } -} diff --git a/src/main/java/common/blocks/Block_SpaceElevatorCapacitor.java b/src/main/java/common/blocks/Block_SpaceElevatorCapacitor.java deleted file mode 100644 index b6816ba7e8..0000000000 --- a/src/main/java/common/blocks/Block_SpaceElevatorCapacitor.java +++ /dev/null @@ -1,82 +0,0 @@ -package common.blocks; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IIconRegister; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.IIcon; -import net.minecraft.world.IBlockAccess; -import net.minecraft.world.World; - -import common.itemBlocks.IB_SpaceElevatorCapacitor; -import common.tileentities.TE_SpaceElevatorCapacitor; - -import cpw.mods.fml.common.registry.GameRegistry; -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class Block_SpaceElevatorCapacitor extends BaseGTUpdateableBlock { - - private static final Block_SpaceElevatorCapacitor INSTANCE = new Block_SpaceElevatorCapacitor(); - - private IIcon top; - private IIcon side; - - private Block_SpaceElevatorCapacitor() { - super(Material.iron); - } - - public static Block registerBlock() { - final String blockName = "kekztech_spaceelevatorcapacitor_block"; - INSTANCE.setBlockName(blockName); - INSTANCE.setCreativeTab(CreativeTabs.tabMisc); - INSTANCE.setHardness(5.0f); - INSTANCE.setResistance(3.0f); - GameRegistry.registerBlock(INSTANCE, IB_SpaceElevatorCapacitor.class, blockName); - - return INSTANCE; - } - - @Override - public void registerBlockIcons(IIconRegister ir) { - top = ir.registerIcon("kekztech:SpaceElevatorCapacitor_top_fullbase"); - side = ir.registerIcon("kekztech:SpaceElevatorCapacitor_side_fullbase"); - } - - @Override - public IIcon getIcon(int side, int meta) { - return (side < 2) ? this.top : this.side; - } - - @Override - public TileEntity createTileEntity(World world, int p_149915_2_) { - return new TE_SpaceElevatorCapacitor(); - } - - @Override - public boolean hasTileEntity(int metadata) { - return true; - } - - @Override - @SideOnly(Side.CLIENT) - public int getRenderBlockPass() { - return 0; - } - - @Override - public boolean renderAsNormalBlock() { - return false; - } - - @Override - public boolean shouldSideBeRendered(IBlockAccess world, int x, int y, int z, int side) { - return false; - } - - @Override - public int getLightValue() { - return 2; - } -} diff --git a/src/main/java/common/blocks/Block_SpaceElevatorTether.java b/src/main/java/common/blocks/Block_SpaceElevatorTether.java deleted file mode 100644 index c6ed0f54b0..0000000000 --- a/src/main/java/common/blocks/Block_SpaceElevatorTether.java +++ /dev/null @@ -1,67 +0,0 @@ -package common.blocks; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.client.renderer.texture.IIconRegister; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.IIcon; -import net.minecraft.world.World; - -import common.tileentities.TE_SpaceElevatorTether; - -import cpw.mods.fml.common.registry.GameRegistry; - -public class Block_SpaceElevatorTether extends BaseGTUpdateableBlock { - - private static final Block_SpaceElevatorTether INSTANCE = new Block_SpaceElevatorTether(); - - private IIcon top; - private IIcon side; - - private Block_SpaceElevatorTether() { - super(Material.glass); - } - - public static Block registerBlock() { - final String blockName = "kekztech_spaceelevatortether_block"; - INSTANCE.setBlockName(blockName); - INSTANCE.setCreativeTab(CreativeTabs.tabMisc); - INSTANCE.setHardness(15.0f); - INSTANCE.setResistance(15.0f); - GameRegistry.registerBlock(INSTANCE, blockName); - - return INSTANCE; - } - - @Override - public void registerBlockIcons(IIconRegister ir) { - top = ir.registerIcon("kekztech:Tether_top"); - side = ir.registerIcon("kekztech:Tether_side"); - } - - @Override - public IIcon getIcon(int side, int meta) { - return (side < 2) ? this.top : this.side; - } - - @Override - public TileEntity createTileEntity(World world, int p_149915_2_) { - return new TE_SpaceElevatorTether(); - } - - @Override - public boolean hasTileEntity(int metadata) { - return true; - } - - @Override - public boolean isOpaqueCube() { - return false; - } - - @Override - public boolean renderAsNormalBlock() { - return false; - } -} diff --git a/src/main/java/common/itemBlocks/IB_SpaceElevator.java b/src/main/java/common/itemBlocks/IB_SpaceElevator.java deleted file mode 100644 index 8b7668207b..0000000000 --- a/src/main/java/common/itemBlocks/IB_SpaceElevator.java +++ /dev/null @@ -1,37 +0,0 @@ -package common.itemBlocks; - -import java.util.List; - -import net.minecraft.block.Block; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.StatCollector; - -public class IB_SpaceElevator extends ItemBlock { - - public IB_SpaceElevator(Block block) { - super(block); - } - - @Override - public int getMetadata(int meta) { - return meta; - } - - @Override - public boolean getHasSubtypes() { - return true; - } - - @Override - public String getUnlocalizedName(ItemStack stack) { - return super.getUnlocalizedName() + "." + stack.getItemDamage(); - } - - @SuppressWarnings("unchecked") - @Override - public void addInformation(ItemStack stack, EntityPlayer player, List lines, boolean advancedTooltips) { - lines.add(StatCollector.translateToLocal("tile.kekztech_spaceelevator_block.desc")); - } -} diff --git a/src/main/java/common/itemBlocks/IB_SpaceElevatorCapacitor.java b/src/main/java/common/itemBlocks/IB_SpaceElevatorCapacitor.java deleted file mode 100644 index fc367ae6a5..0000000000 --- a/src/main/java/common/itemBlocks/IB_SpaceElevatorCapacitor.java +++ /dev/null @@ -1,22 +0,0 @@ -package common.itemBlocks; - -import java.util.List; - -import net.minecraft.block.Block; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.item.ItemBlock; -import net.minecraft.item.ItemStack; -import net.minecraft.util.StatCollector; - -public class IB_SpaceElevatorCapacitor extends ItemBlock { - - public IB_SpaceElevatorCapacitor(Block block) { - super(block); - } - - @SuppressWarnings("unchecked") - @Override - public void addInformation(ItemStack stack, EntityPlayer player, List lines, boolean advancedTooltips) { - lines.add(StatCollector.translateToLocal("tile.kekztech_spaceelevatorcapacitor_block.desc")); - } -} diff --git a/src/main/java/common/tileentities/GTMTE_SpaceElevator.java b/src/main/java/common/tileentities/GTMTE_SpaceElevator.java deleted file mode 100644 index 421a2e2760..0000000000 --- a/src/main/java/common/tileentities/GTMTE_SpaceElevator.java +++ /dev/null @@ -1,260 +0,0 @@ -package common.tileentities; - -import java.util.ArrayList; -import java.util.HashSet; - -import net.minecraft.block.Block; -import net.minecraft.item.ItemStack; -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.EnumChatFormatting; -import net.minecraftforge.common.util.ForgeDirection; - -import common.Blocks; - -import gregtech.api.enums.Dyes; -import gregtech.api.enums.Textures; -import gregtech.api.interfaces.ITexture; -import gregtech.api.interfaces.metatileentity.IMetaTileEntity; -import gregtech.api.interfaces.tileentity.IGregTechTileEntity; -import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_MultiBlockBase; -import gregtech.api.objects.GT_RenderedTexture; -import util.Vector3i; -import util.Vector3ic; - -public class GTMTE_SpaceElevator extends GT_MetaTileEntity_MultiBlockBase { - - private static final Block BASE_BLOCK = Blocks.spaceElevatorStructure; - private static final Block CAP_BLOCK = Blocks.spaceElevatorCapacitor; - private static final Block TETHER_BLOCK = Blocks.spaceElevatorTether; - private static final int BASE_META = 0; - private static final int COIL_HOLDER_META = 1; - private static final String glassNameBorosilicate = "BW_GlasBlocks"; - private static final int HATCH_OVERLAY_ID = 16; - - // Scan positions for capacitor banks - // Start with top left bank, clockwise - // Start with top middle pillar within bank, clockwise, middle last - private static final int[] bankOffsetsX = { -7, 5, 5, -7 }; - private static final int[] bankOffsetsY = { -7, -7, 5, 5 }; - private static final int[] scanOffsetsX = { 1, 2, 1, 0, 1 }; - private static final int[] scanOffsetsY = { 0, 1, 2, 1, 1 }; - - private final HashSet<TE_SpaceElevatorCapacitor> capacitors = new HashSet<>(); - private long lastLaunchEUCost = 0; - - public GTMTE_SpaceElevator(int aID, String aName, String aNameRegional) { - super(aID, aName, aNameRegional); - } - - public GTMTE_SpaceElevator(String aName) { - super(aName); - } - - @Override - public IMetaTileEntity newMetaEntity(IGregTechTileEntity var1) { - return new GTMTE_SpaceElevator((super.mName)); - } - - @Override - public String[] getDescription() { - return new String[] { "Disabled" }; - /* - * final MultiBlockTooltipBuilder b = new MultiBlockTooltipBuilder(); - * b.addInfo("Access for your Space Station!") - * .addInfo("Check out the wiki on my github if you are having trouble with the structure") - * .addInfo("Regenerative Breaking will recover up to X% of the energy spent on launch") - * .addInfo("Energy recovered depends on coil tier: +10% per coil tier, up to 90%") .addSeparator() - * .beginStructureBlock(15, 11, 15) .addController("Bottom Center") - * .addEnergyHatch("Instead of any casing in the bottom floor") - * .addMaintenanceHatch("Instead of any casing in the bottom floor") - * .addCasingInfo("Solid Steel Machine Casing", 320) .addOtherStructurePart("Any EBF coil", - * "40x, have to be all the same") .addOtherStructurePart("Space Elevator Tether", "4x") - * .addOtherStructurePart("Space Elevator Cabin Block", "42x") - * .addOtherStructurePart("Space Elevator Cabin Guide", "8x") .signAndFinalize("Kekzdealer"); - * if(!Keyboard.isKeyDown(Keyboard.KEY_LSHIFT)) { return b.getInformation(); } else { return - * b.getStructureInformation(); } - */ - } - - @Override - public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, ForgeDirection side, ForgeDirection facing, - int colorIndex, boolean aActive, boolean aRedstone) { - ITexture[] sTexture = new ITexture[] { new GT_RenderedTexture( - Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS, - Dyes.getModulation(-1, Dyes._NULL.mRGBa)) }; - if (side == facing && aActive) { - sTexture = new ITexture[] { new GT_RenderedTexture( - Textures.BlockIcons.MACHINE_CASING_FUSION_GLASS_YELLOW, - Dyes.getModulation(-1, Dyes._NULL.mRGBa)) }; - } - return sTexture; - } - - @Override - public boolean isCorrectMachinePart(ItemStack stack) { - return true; - } - - @Override - public boolean checkRecipe(ItemStack stack) { - this.mProgresstime = 1; - this.mMaxProgresstime = 1; - this.mEUt = 0; - this.mEfficiencyIncrease = 10000; - return true; - } - - public Vector3ic rotateOffsetVector(Vector3ic forgeDirection, int x, int y, int z) { - final Vector3i offset = new Vector3i(0, 0, 0); - // either direction on y-axis - if (forgeDirection.y() == -1) { - offset.x = x; - offset.y = z; - offset.z = y; - } - - return offset; - } - - @Override - public boolean checkMachine(IGregTechTileEntity thisController, ItemStack guiSlotItem) { - // Make sure the controller is either facing up or down - if (thisController.getFrontFacing().offsetY != 0) { - return false; - } - - // Figure out the vector for the direction the back face of the controller is facing - final Vector3ic forgeDirection = new Vector3i( - thisController.getBackFacing().offsetX, - thisController.getBackFacing().offsetY, - thisController.getBackFacing().offsetZ); - boolean formationChecklist = true; - int minCasingAmount = 320; - int firstCoilMeta = -1; - capacitors.clear(); - - // Base floor - for (int X = -7; X <= 7; X++) { - for (int Y = -7; Y <= 7; Y++) { - if (X == 0 && Y == 0) { - continue; // Skip controller - } - - final Vector3ic offset = rotateOffsetVector(forgeDirection, X, Y, 0); - final IGregTechTileEntity currentTE = thisController - .getIGregTechTileEntityOffset(offset.x(), offset.y(), offset.z()); - - // Tries to add TE as either of those kinds of hatches. - // The number is the texture index number for the texture that needs to be painted over the hatch - // texture - if (!super.addMaintenanceToMachineList(currentTE, HATCH_OVERLAY_ID) - && !this.addEnergyInputToMachineList(currentTE, HATCH_OVERLAY_ID)) { - - // If it's not a hatch, is it the right casing for this machine? Check block and block meta. - if ((thisController.getBlockOffset(offset.x(), offset.y(), offset.z()) == BASE_BLOCK) - && (thisController.getMetaIDOffset(offset.x(), offset.y(), offset.z()) == BASE_META)) { - // Seems to be valid casing. Decrement counter. - minCasingAmount--; - } else { - formationChecklist = false; - } - } - } - } - System.out.println(""); - // Capacitor banks - for (int bank = 0; bank < 4; bank++) { - for (int Z = 1; Z <= 5; Z++) { - for (int scan = 0; scan < 5; scan++) { - final Vector3ic offset = rotateOffsetVector( - forgeDirection, - bankOffsetsX[bank] + scanOffsetsX[scan], - bankOffsetsY[bank] + scanOffsetsY[scan], - Z); - if (Z == 1 || Z == 5) { - // Check for casings - if (thisController.getBlockOffset(offset.x(), offset.y(), offset.z()) == BASE_BLOCK - && thisController.getMetaIDOffset(offset.x(), offset.y(), offset.z()) == BASE_META) { - minCasingAmount--; - } else { - formationChecklist = false; - } - } else { - if (scan == 4) { - // Check for capacitors - final TileEntity te = thisController - .getTileEntityOffset(offset.x(), offset.y(), offset.z()); - if (thisController.getBlockOffset(offset.x(), offset.y(), offset.z()) == CAP_BLOCK - && te instanceof TE_SpaceElevatorCapacitor) { - capacitors.add((TE_SpaceElevatorCapacitor) te); - } else { - formationChecklist = false; - } - } else { - // Check for Glass - if (!thisController.getBlockOffset(offset.x(), offset.y(), offset.z()).getUnlocalizedName() - .equals(glassNameBorosilicate)) { - formationChecklist = false; - } - } - } - } - } - } - // Anchor - - // Coil holders - - // Coils - - if (minCasingAmount > 0) { - formationChecklist = false; - } - - for (TE_SpaceElevatorCapacitor cap : capacitors) { - cap.setIsDamaged(false); - } - - return formationChecklist; - } - - @Override - public String[] getInfoData() { - final ArrayList<String> ll = new ArrayList<>(); - ll.add(EnumChatFormatting.YELLOW + "Operational Data:" + EnumChatFormatting.RESET); - - ll.add( - "Maintenance Status: " + ((super.getRepairStatus() == super.getIdealStatus()) - ? EnumChatFormatting.GREEN + "Working perfectly" + EnumChatFormatting.RESET - : EnumChatFormatting.RED + "Has Problems" + EnumChatFormatting.RESET)); - ll.add("---------------------------------------------"); - - final String[] a = new String[ll.size()]; - return ll.toArray(a); - } - - @Override - public boolean isGivingInformation() { - return true; - } - - @Override - public int getMaxEfficiency(ItemStack stack) { - return 10000; - } - - @Override - public int getPollutionPerTick(ItemStack stack) { - return 0; - } - - @Override - public int getDamageToComponent(ItemStack stack) { - return 0; - } - - @Override - public boolean explodesOnComponentBreak(ItemStack stack) { - return false; - } -} diff --git a/src/main/java/common/tileentities/TE_SpaceElevatorCapacitor.java b/src/main/java/common/tileentities/TE_SpaceElevatorCapacitor.java deleted file mode 100644 index ea5211bfba..0000000000 --- a/src/main/java/common/tileentities/TE_SpaceElevatorCapacitor.java +++ /dev/null @@ -1,53 +0,0 @@ -package common.tileentities; - -import net.minecraft.tileentity.TileEntity; - -public class TE_SpaceElevatorCapacitor extends TileEntity { - - private float chargeLevel = 0.0F; - private boolean isDamaged = true; - - /** - * Called by {@link GTMTE_SpaceElevator} while charging - * - * @param charge Current elevator charge - * @param maxCharge Charge level it is trying to reach - */ - public void updateChargeLevel(int charge, int maxCharge) { - chargeLevel = ((float) charge) / ((float) maxCharge); - } - - /** - * Called by {@link client.renderer.TESR_SECapacitor} to calculate the block's colour saturation - * - * @return Charge level from 0.0F to 1.0F - */ - public float getChargeLevel() { - return chargeLevel; - } - - /** - * Called by {@link GTMTE_SpaceElevator} in case of power loss - */ - public void resetChargeLevel() { - chargeLevel = 0.0F; - } - - /** - * Called by {@link GTMTE_SpaceElevator} in case of maintenance issues - * - * @param isDamaged has maintenance issue - */ - public void setIsDamaged(boolean isDamaged) { - this.isDamaged = isDamaged; - } - - /** - * Called by {@link client.renderer.TESR_SECapacitor} to check whether the block should be rendered red - * - * @return should be rendered red - */ - public boolean isDamaged() { - return isDamaged; - } -} diff --git a/src/main/java/common/tileentities/TE_SpaceElevatorTether.java b/src/main/java/common/tileentities/TE_SpaceElevatorTether.java deleted file mode 100644 index 7e76a9c14d..0000000000 --- a/src/main/java/common/tileentities/TE_SpaceElevatorTether.java +++ /dev/null @@ -1,24 +0,0 @@ -package common.tileentities; - -import net.minecraft.tileentity.TileEntity; -import net.minecraft.util.AxisAlignedBB; - -import cpw.mods.fml.relauncher.Side; -import cpw.mods.fml.relauncher.SideOnly; - -public class TE_SpaceElevatorTether extends TileEntity { - - @SideOnly(Side.CLIENT) - @Override - public double getMaxRenderDistanceSquared() { - // 4k is standard, 65k is what the vanilla beacon uses - return 65536.0D; - } - - @Override - @SideOnly(Side.CLIENT) - public AxisAlignedBB getRenderBoundingBox() { - // Make it so the beam is still rendered even when the source block is out of sight - return INFINITE_EXTENT_AABB; - } -} |
