aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/gtPlusPlus/core/client
diff options
context:
space:
mode:
authormiozune <miozune@gmail.com>2023-05-17 00:01:01 +0900
committerGitHub <noreply@github.com>2023-05-16 17:01:01 +0200
commit04514282c08ebefdb3e68a46db34092f72be2316 (patch)
tree0c9bc99f480f7e7f45a99a55a5b6619ebb5b014b /src/main/java/gtPlusPlus/core/client
parentcd58ff7cd4dc4b5ffe917a24a4b4c6da577f462d (diff)
downloadGT5-Unofficial-04514282c08ebefdb3e68a46db34092f72be2316.tar.gz
GT5-Unofficial-04514282c08ebefdb3e68a46db34092f72be2316.tar.bz2
GT5-Unofficial-04514282c08ebefdb3e68a46db34092f72be2316.zip
Remove a lot of unused classes (#629)
Diffstat (limited to 'src/main/java/gtPlusPlus/core/client')
-rw-r--r--src/main/java/gtPlusPlus/core/client/model/ModelEggBox.java68
-rw-r--r--src/main/java/gtPlusPlus/core/client/model/tabula/ModelTabulaBase.java36
-rw-r--r--src/main/java/gtPlusPlus/core/client/renderer/RenderPotionthrow.java98
-rw-r--r--src/main/java/gtPlusPlus/core/client/renderer/tabula/RenderTabulaBase.java50
4 files changed, 0 insertions, 252 deletions
diff --git a/src/main/java/gtPlusPlus/core/client/model/ModelEggBox.java b/src/main/java/gtPlusPlus/core/client/model/ModelEggBox.java
deleted file mode 100644
index 49a0878678..0000000000
--- a/src/main/java/gtPlusPlus/core/client/model/ModelEggBox.java
+++ /dev/null
@@ -1,68 +0,0 @@
-package gtPlusPlus.core.client.model;
-
-import net.minecraft.client.model.ModelRenderer;
-import net.minecraft.entity.Entity;
-
-import gtPlusPlus.api.objects.data.AutoMap;
-import gtPlusPlus.api.objects.data.Pair;
-import gtPlusPlus.core.client.model.tabula.ModelTabulaBase;
-import gtPlusPlus.core.client.renderer.tabula.RenderTabulaBase;
-import gtPlusPlus.core.tileentities.general.TileEntityEggBox;
-
-/**
- * ModelEggBox - Alkalus Created using Tabula 4.1.1
- */
-public class ModelEggBox extends ModelTabulaBase {
-
- private final AutoMap<Pair<ModelRenderer, Float>> mParts = new AutoMap<Pair<ModelRenderer, Float>>();
-
- private static RenderTabulaBase mRendererInstance;
-
- public ModelRenderer bottom;
- // EggBox_full.png
-
- public ModelEggBox() {
- super(64, 64);
- this.textureWidth = 64;
- this.textureHeight = 64;
-
- this.bottom = new ModelRenderer(this, 0, 19);
- this.bottom.setRotationPoint(1.0F, 6.0F, 1.0F);
- this.bottom.addBox(0.0F, 0.0F, 0.0F, 14, 10, 14, 0.0F);
- mParts.add(new Pair<ModelRenderer, Float>(bottom, 0f));
- }
-
- @Override
- public void render(Entity entity, float f, float f1, float f2, float f3, float f4, float f5) {
- // Logger.INFO("Rendering EggBox");
- this.bottom.render(f5);
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- @Override
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z) {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-
- @Override
- protected AutoMap<Pair<ModelRenderer, Float>> getModelParts() {
- AutoMap<Pair<ModelRenderer, Float>> aParts = new AutoMap<Pair<ModelRenderer, Float>>();
- aParts.add(new Pair<ModelRenderer, Float>(bottom, 0.0625F));
- return aParts;
- // return mParts;
- }
-
- public static RenderTabulaBase getRenderer() {
- if (mRendererInstance == null) {
- mRendererInstance = new RenderTabulaBase(
- new ModelEggBox(),
- "textures/blocks/TileEntities/EggBox_full.png",
- TileEntityEggBox.class);
- }
- return mRendererInstance;
- }
-}
diff --git a/src/main/java/gtPlusPlus/core/client/model/tabula/ModelTabulaBase.java b/src/main/java/gtPlusPlus/core/client/model/tabula/ModelTabulaBase.java
deleted file mode 100644
index 3c13c83391..0000000000
--- a/src/main/java/gtPlusPlus/core/client/model/tabula/ModelTabulaBase.java
+++ /dev/null
@@ -1,36 +0,0 @@
-package gtPlusPlus.core.client.model.tabula;
-
-import net.minecraft.client.model.ModelBase;
-import net.minecraft.client.model.ModelRenderer;
-
-import gtPlusPlus.api.objects.data.AutoMap;
-import gtPlusPlus.api.objects.data.Pair;
-
-/**
- * ModelEggBox - Alkalus Created using Tabula 4.1.1
- */
-public abstract class ModelTabulaBase extends ModelBase {
-
- public ModelTabulaBase(int aTexWidth, int aTexHeight) {
- this.textureWidth = aTexWidth;
- this.textureHeight = aTexHeight;
- }
-
- protected abstract AutoMap<Pair<ModelRenderer, Float>> getModelParts();
-
- public void renderAll() {
- for (Pair<ModelRenderer, Float> part : getModelParts()) {
- // Logger.INFO("Rendering EggBox");
- part.getKey().render(part.getValue());
- }
- }
-
- /**
- * This is a helper function from Tabula to set the rotation of model parts
- */
- public void setRotateAngle(ModelRenderer modelRenderer, float x, float y, float z) {
- modelRenderer.rotateAngleX = x;
- modelRenderer.rotateAngleY = y;
- modelRenderer.rotateAngleZ = z;
- }
-}
diff --git a/src/main/java/gtPlusPlus/core/client/renderer/RenderPotionthrow.java b/src/main/java/gtPlusPlus/core/client/renderer/RenderPotionthrow.java
deleted file mode 100644
index 0f962df641..0000000000
--- a/src/main/java/gtPlusPlus/core/client/renderer/RenderPotionthrow.java
+++ /dev/null
@@ -1,98 +0,0 @@
-package gtPlusPlus.core.client.renderer;
-
-import net.minecraft.client.renderer.Tessellator;
-import net.minecraft.client.renderer.entity.Render;
-import net.minecraft.client.renderer.texture.TextureMap;
-import net.minecraft.entity.Entity;
-import net.minecraft.entity.projectile.EntityPotion;
-import net.minecraft.item.Item;
-import net.minecraft.item.ItemPotion;
-import net.minecraft.potion.PotionHelper;
-import net.minecraft.util.IIcon;
-import net.minecraft.util.ResourceLocation;
-
-import org.lwjgl.opengl.GL11;
-import org.lwjgl.opengl.GL12;
-
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-
-@SideOnly(Side.CLIENT)
-public class RenderPotionthrow extends Render {
-
- private Item mRenderItem;
- private int mDamage;
-
- public RenderPotionthrow(Item p_i1259_1_, int p_i1259_2_) {
- this.mRenderItem = p_i1259_1_;
- this.mDamage = p_i1259_2_;
- }
-
- public RenderPotionthrow(Item p_i1260_1_) {
- this(p_i1260_1_, 0);
- }
-
- /**
- * Actually renders the given argument. This is a synthetic bridge method, always casting down its argument and then
- * handing it off to a worker function which does the actual work. In all probabilty, the class Render is generic
- * (Render<T extends Entity) and this method has signature public void func_76986_a(T entity, double d, double d1,
- * double d2, float f, float f1). But JAD is pre 1.5 so doesn't do that.
- */
- @Override
- public void doRender(Entity p_76986_1_, double p_76986_2_, double p_76986_4_, double p_76986_6_, float p_76986_8_,
- float p_76986_9_) {
- IIcon iicon = this.mRenderItem.getIconFromDamage(this.mDamage);
-
- if (iicon != null) {
- GL11.glPushMatrix();
- GL11.glTranslatef((float) p_76986_2_, (float) p_76986_4_, (float) p_76986_6_);
- GL11.glEnable(GL12.GL_RESCALE_NORMAL);
- GL11.glScalef(0.5F, 0.5F, 0.5F);
- this.bindEntityTexture(p_76986_1_);
- Tessellator tessellator = Tessellator.instance;
-
- if (iicon == ItemPotion.func_94589_d("bottle_splash")) {
- int i = PotionHelper.func_77915_a(((EntityPotion) p_76986_1_).getPotionDamage(), false);
- float f2 = (i >> 16 & 255) / 255.0F;
- float f3 = (i >> 8 & 255) / 255.0F;
- float f4 = (i & 255) / 255.0F;
- GL11.glColor3f(f2, f3, f4);
- GL11.glPushMatrix();
- this.func_77026_a(tessellator, ItemPotion.func_94589_d("overlay"));
- GL11.glPopMatrix();
- GL11.glColor3f(1.0F, 1.0F, 1.0F);
- }
-
- this.func_77026_a(tessellator, iicon);
- GL11.glDisable(GL12.GL_RESCALE_NORMAL);
- GL11.glPopMatrix();
- }
- }
-
- /**
- * Returns the location of an entity's texture. Doesn't seem to be called unless you call Render.bindEntityTexture.
- */
- @Override
- protected ResourceLocation getEntityTexture(Entity p_110775_1_) {
- return TextureMap.locationItemsTexture;
- }
-
- private void func_77026_a(Tessellator p_77026_1_, IIcon p_77026_2_) {
- float f = p_77026_2_.getMinU();
- float f1 = p_77026_2_.getMaxU();
- float f2 = p_77026_2_.getMinV();
- float f3 = p_77026_2_.getMaxV();
- float f4 = 1.0F;
- float f5 = 0.5F;
- float f6 = 0.25F;
- GL11.glRotatef(180.0F - this.renderManager.playerViewY, 0.0F, 1.0F, 0.0F);
- GL11.glRotatef(-this.renderManager.playerViewX, 1.0F, 0.0F, 0.0F);
- p_77026_1_.startDrawingQuads();
- p_77026_1_.setNormal(0.0F, 1.0F, 0.0F);
- p_77026_1_.addVertexWithUV(0.0F - f5, 0.0F - f6, 0.0D, f, f3);
- p_77026_1_.addVertexWithUV(f4 - f5, 0.0F - f6, 0.0D, f1, f3);
- p_77026_1_.addVertexWithUV(f4 - f5, f4 - f6, 0.0D, f1, f2);
- p_77026_1_.addVertexWithUV(0.0F - f5, f4 - f6, 0.0D, f, f2);
- p_77026_1_.draw();
- }
-}
diff --git a/src/main/java/gtPlusPlus/core/client/renderer/tabula/RenderTabulaBase.java b/src/main/java/gtPlusPlus/core/client/renderer/tabula/RenderTabulaBase.java
deleted file mode 100644
index ed3808e815..0000000000
--- a/src/main/java/gtPlusPlus/core/client/renderer/tabula/RenderTabulaBase.java
+++ /dev/null
@@ -1,50 +0,0 @@
-package gtPlusPlus.core.client.renderer.tabula;
-
-import static gregtech.api.enums.Mods.GTPlusPlus;
-
-import net.minecraft.client.renderer.tileentity.TileEntitySpecialRenderer;
-import net.minecraft.tileentity.TileEntity;
-import net.minecraft.util.ResourceLocation;
-
-import cpw.mods.fml.client.registry.RenderingRegistry;
-import cpw.mods.fml.relauncher.Side;
-import cpw.mods.fml.relauncher.SideOnly;
-import gtPlusPlus.core.client.model.tabula.ModelTabulaBase;
-
-@SideOnly(Side.CLIENT)
-public class RenderTabulaBase extends TileEntitySpecialRenderer {
-
- private final ModelTabulaBase mModel;
- private final ResourceLocation mTexture;
- private final Class mTileClass;
-
- public final int mRenderID;
- public final RenderTabulaBase mInstance;
-
- public RenderTabulaBase(ModelTabulaBase aModel, String aTexturePath, Class aTileClass) {
- mModel = aModel;
- mTexture = new ResourceLocation(GTPlusPlus.ID, aTexturePath);
- mTileClass = aTileClass;
- this.mRenderID = RenderingRegistry.getNextAvailableRenderId();
- mInstance = this;
- }
-
- public void renderTileEntityAt(Object aTile, double p_147500_2_, double p_147500_4_, double p_147500_6_,
- float p_147500_8_) {
- if (mTileClass.isInstance(aTile)) {
- // Logger.INFO("Rendering EggBox");
- this.bindTexture(mTexture);
- mModel.renderAll();
- }
- }
-
- @Override
- public void renderTileEntityAt(TileEntity aTile, double p_147500_2_, double p_147500_4_, double p_147500_6_,
- float p_147500_8_) {
- if (mTileClass != null && aTile != null) {
- if (mTileClass.isInstance(aTile)) {
- this.renderTileEntityAt((Object) aTile, p_147500_2_, p_147500_4_, p_147500_6_, p_147500_8_);
- }
- }
- }
-}