From 84a6dabdcc9936aaeece6d74952157996fc6bc58 Mon Sep 17 00:00:00 2001 From: boubou19 Date: Tue, 2 Jul 2024 20:48:44 +0200 Subject: Removal of the GT Arrows (#2692) * remove arrows * remove arrow classes * remove arrow usages in ItemList * less bullshit * sa --------- Co-authored-by: Martin Robertz --- src/main/java/gregtech/GT_Mod.java | 6 - src/main/java/gregtech/api/enums/ItemList.java | 27 -- src/main/java/gregtech/api/enums/OrePrefixes.java | 20 - src/main/java/gregtech/api/util/GT_Utility.java | 80 ---- src/main/java/gregtech/common/GT_Client.java | 5 - src/main/java/gregtech/common/GT_Proxy.java | 28 +- .../gregtech/common/entities/GT_Entity_Arrow.java | 438 --------------------- .../common/entities/GT_Entity_Arrow_Potion.java | 78 ---- .../common/items/GT_MetaGenerated_Item_01.java | 349 ---------------- .../common/items/GT_MetaGenerated_Item_02.java | 57 +-- .../java/gregtech/common/items/ID_MetaItem_01.java | 27 -- .../common/items/behaviors/Behaviour_Arrow.java | 141 ------- .../items/behaviors/Behaviour_Arrow_Potion.java | 71 ---- .../common/render/GT_Renderer_Entity_Arrow.java | 23 -- .../loaders/oreprocessing/ProcessingArrows.java | 135 ------- .../loaders/oreprocessing/ProcessingToolHead.java | 25 -- .../loaders/postload/GT_BookAndLootLoader.java | 21 - .../loaders/postload/GT_CraftingRecipeLoader.java | 4 - .../postload/recipes/FormingPressRecipes.java | 8 - .../preload/GT_Loader_Item_Block_And_Fluid.java | 122 ------ .../loaders/preload/GT_Loader_OreProcessing.java | 2 - 21 files changed, 14 insertions(+), 1653 deletions(-) delete mode 100644 src/main/java/gregtech/common/entities/GT_Entity_Arrow.java delete mode 100644 src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java delete mode 100644 src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow.java delete mode 100644 src/main/java/gregtech/common/items/behaviors/Behaviour_Arrow_Potion.java delete mode 100644 src/main/java/gregtech/common/render/GT_Renderer_Entity_Arrow.java delete mode 100644 src/main/java/gregtech/loaders/oreprocessing/ProcessingArrows.java (limited to 'src/main/java/gregtech') diff --git a/src/main/java/gregtech/GT_Mod.java b/src/main/java/gregtech/GT_Mod.java index 8b55f0a73f..f515a21a45 100644 --- a/src/main/java/gregtech/GT_Mod.java +++ b/src/main/java/gregtech/GT_Mod.java @@ -46,7 +46,6 @@ import cpw.mods.fml.common.event.FMLServerAboutToStartEvent; import cpw.mods.fml.common.event.FMLServerStartedEvent; import cpw.mods.fml.common.event.FMLServerStartingEvent; import cpw.mods.fml.common.event.FMLServerStoppingEvent; -import cpw.mods.fml.common.registry.EntityRegistry; import gregtech.api.GregTech_API; import gregtech.api.enchants.Enchantment_EnderDamage; import gregtech.api.enchants.Enchantment_Hazmat; @@ -80,8 +79,6 @@ import gregtech.common.GT_Network; import gregtech.common.GT_Proxy; import gregtech.common.GT_RecipeAdder; import gregtech.common.covers.GT_Cover_FacadeAE; -import gregtech.common.entities.GT_Entity_Arrow; -import gregtech.common.entities.GT_Entity_Arrow_Potion; import gregtech.common.misc.GT_Command; import gregtech.common.misc.spaceprojects.commands.SPM_Command; import gregtech.common.misc.spaceprojects.commands.SP_Command; @@ -271,9 +268,6 @@ public class GT_Mod implements IGT_Mod { .getParentFile()); GT_PreLoad.adjustScrap(); - EntityRegistry.registerModEntity(GT_Entity_Arrow.class, "GT_Entity_Arrow", 1, GT_Values.GT, 160, 1, true); - EntityRegistry - .registerModEntity(GT_Entity_Arrow_Potion.class, "GT_Entity_Arrow_Potion", 2, GT_Values.GT, 160, 1, true); AEApi.instance() .registries() .interfaceTerminal() diff --git a/src/main/java/gregtech/api/enums/ItemList.java b/src/main/java/gregtech/api/enums/ItemList.java index ac810f8eaf..03446092fc 100644 --- a/src/main/java/gregtech/api/enums/ItemList.java +++ b/src/main/java/gregtech/api/enums/ItemList.java @@ -100,33 +100,6 @@ public enum ItemList implements IItemContainer { IC2_AdvBattery, IC2_EnergyCrystal, IC2_LapotronCrystal, - Arrow_Head_Glass_Emtpy, - Arrow_Head_Glass_Poison, - Arrow_Head_Glass_Poison_Long, - Arrow_Head_Glass_Poison_Strong, - Arrow_Head_Glass_Slowness, - Arrow_Head_Glass_Slowness_Long, - Arrow_Head_Glass_Weakness, - Arrow_Head_Glass_Weakness_Long, - Arrow_Head_Glass_Holy_Water, - Arrow_Wooden_Glass_Emtpy, - Arrow_Wooden_Glass_Poison, - Arrow_Wooden_Glass_Poison_Long, - Arrow_Wooden_Glass_Poison_Strong, - Arrow_Wooden_Glass_Slowness, - Arrow_Wooden_Glass_Slowness_Long, - Arrow_Wooden_Glass_Weakness, - Arrow_Wooden_Glass_Weakness_Long, - Arrow_Wooden_Glass_Holy_Water, - Arrow_Plastic_Glass_Emtpy, - Arrow_Plastic_Glass_Poison, - Arrow_Plastic_Glass_Poison_Long, - Arrow_Plastic_Glass_Poison_Strong, - Arrow_Plastic_Glass_Slowness, - Arrow_Plastic_Glass_Slowness_Long, - Arrow_Plastic_Glass_Weakness, - Arrow_Plastic_Glass_Weakness_Long, - Arrow_Plastic_Glass_Holy_Water, Shape_Empty, Shape_Mold_Bottle, diff --git a/src/main/java/gregtech/api/enums/OrePrefixes.java b/src/main/java/gregtech/api/enums/OrePrefixes.java index 6f7c347884..a703e8690a 100644 --- a/src/main/java/gregtech/api/enums/OrePrefixes.java +++ b/src/main/java/gregtech/api/enums/OrePrefixes.java @@ -261,16 +261,6 @@ public enum OrePrefixes { false, B[6] | B[8], M / 6, 64, -1), bulletGtLarge("Large Bullets", "Large ", " Bullet", true, true, false, false, true, false, true, false, true, false, B[6] | B[8], M / 3, 64, -1), - /** Arrow made of 1/4 Ingot/Dust + Wooden Stick. */ - arrowGtWood("Regular Arrows", "", " Arrow", true, true, false, false, true, false, true, false, true, false, B[6], - M / 4, 64, 57), - /** Arrow made of 1/4 Ingot/Dust + Plastic Stick. */ - arrowGtPlastic("Light Arrows", "Light ", " Arrow", true, true, false, false, true, false, true, false, true, false, - B[6], M / 4, 64, 58), - arrow("Arrows", "", "", false, false, true, false, false, false, false, false, true, false, B[6], -1, 64, 57), - /** consisting out of 1/4 Ingot. */ - toolHeadArrow("Arrow Heads", "", " Arrow Head", true, true, false, false, false, false, true, true, false, false, - B[6], M / 4, 64, 46), /** consisting out of 2 Ingots. */ toolHeadSword("Sword Blades", "", " Sword Blade", true, true, false, false, false, false, true, true, false, false, B[6], M * 2, 64, 32), @@ -780,11 +770,6 @@ public enum OrePrefixes { block.mNotGeneratedItems.add(Materials.Redstone); block.mNotGeneratedItems.add(Materials.Diamond); block.mNotGeneratedItems.add(Materials.Coal); - toolHeadArrow.mNotGeneratedItems.add(Materials.Glass); - toolHeadArrow.mNotGeneratedItems.add(MaterialsUEVplus.TranscendentMetal); - arrowGtPlastic.mNotGeneratedItems.add(MaterialsUEVplus.TranscendentMetal); - arrow.mNotGeneratedItems.add(MaterialsUEVplus.TranscendentMetal); - arrowGtWood.mNotGeneratedItems.add(MaterialsUEVplus.TranscendentMetal); stickLong.mNotGeneratedItems.add(Materials.Obsidian); dust.mNotGeneratedItems.add(Materials.CertusQuartzCharged); @@ -979,8 +964,6 @@ public enum OrePrefixes { toolHeadWrench.mSecondaryMaterial = new MaterialStack( Materials.Steel, ring.mMaterialAmount + screw.mMaterialAmount * 2); - arrowGtWood.mSecondaryMaterial = new MaterialStack(Materials.Wood, stick.mMaterialAmount); - arrowGtPlastic.mSecondaryMaterial = new MaterialStack(Materials.Plastic, stick.mMaterialAmount); bulletGtSmall.mSecondaryMaterial = new MaterialStack(Materials.Brass, ingot.mMaterialAmount / 9); bulletGtMedium.mSecondaryMaterial = new MaterialStack(Materials.Brass, ingot.mMaterialAmount / 6); bulletGtLarge.mSecondaryMaterial = new MaterialStack(Materials.Brass, ingot.mMaterialAmount / 3); @@ -1046,7 +1029,6 @@ public enum OrePrefixes { OrePrefixes.toolHeadUniversalSpade, OrePrefixes.toolHeadSense, OrePrefixes.toolHeadPlow, - OrePrefixes.toolHeadArrow, OrePrefixes.toolHeadBuzzSaw, OrePrefixes.turbineBlade, OrePrefixes.wireFine, @@ -1055,8 +1037,6 @@ public enum OrePrefixes { OrePrefixes.stickLong, OrePrefixes.springSmall, OrePrefixes.spring, - OrePrefixes.arrowGtWood, - OrePrefixes.arrowGtPlastic, OrePrefixes.gemChipped, OrePrefixes.gemFlawed, OrePrefixes.gemFlawless, diff --git a/src/main/java/gregtech/api/util/GT_Utility.java b/src/main/java/gregtech/api/util/GT_Utility.java index e09901b03b..72b74c3f97 100644 --- a/src/main/java/gregtech/api/util/GT_Utility.java +++ b/src/main/java/gregtech/api/util/GT_Utility.java @@ -4411,86 +4411,6 @@ public class GT_Utility { } } - /** - * THIS IS BULLSHIT!!! WHY DO I HAVE TO DO THIS SHIT JUST TO HAVE ENCHANTS PROPERLY!?! - */ - public static class GT_EnchantmentHelper { - - private static final BullshitIteratorA mBullshitIteratorA = new BullshitIteratorA(); - private static final BullshitIteratorB mBullshitIteratorB = new BullshitIteratorB(); - - private static void applyBullshit(IBullshit aBullshitModifier, ItemStack aStack) { - if (aStack != null) { - NBTTagList nbttaglist = aStack.getEnchantmentTagList(); - if (nbttaglist != null) { - try { - for (int i = 0; i < nbttaglist.tagCount(); ++i) { - short short1 = nbttaglist.getCompoundTagAt(i) - .getShort("id"); - short short2 = nbttaglist.getCompoundTagAt(i) - .getShort("lvl"); - if (Enchantment.enchantmentsList[short1] != null) - aBullshitModifier.calculateModifier(Enchantment.enchantmentsList[short1], short2); - } - } catch (Throwable e) { - /**/ - } - } - } - } - - private static void applyArrayOfBullshit(IBullshit aBullshitModifier, ItemStack[] aStacks) { - for (ItemStack itemstack : aStacks) { - applyBullshit(aBullshitModifier, itemstack); - } - } - - public static void applyBullshitA(EntityLivingBase aPlayer, Entity aEntity, ItemStack aStack) { - mBullshitIteratorA.mPlayer = aPlayer; - mBullshitIteratorA.mEntity = aEntity; - if (aPlayer != null) applyArrayOfBullshit(mBullshitIteratorA, aPlayer.getLastActiveItems()); - if (aStack != null) applyBullshit(mBullshitIteratorA, aStack); - } - - public static void applyBullshitB(EntityLivingBase aPlayer, Entity aEntity, ItemStack aStack) { - mBullshitIteratorB.mPlayer = aPlayer; - mBullshitIteratorB.mEntity = aEntity; - if (aPlayer != null) applyArrayOfBullshit(mBullshitIteratorB, aPlayer.getLastActiveItems()); - if (aStack != null) applyBullshit(mBullshitIteratorB, aStack); - } - - interface IBullshit { - - void calculateModifier(Enchantment aEnchantment, int aLevel); - } - - static final class BullshitIteratorA implements IBullshit { - - public EntityLivingBase mPlayer; - public Entity mEntity; - - BullshitIteratorA() {} - - @Override - public void calculateModifier(Enchantment aEnchantment, int aLevel) { - aEnchantment.func_151367_b(mPlayer, mEntity, aLevel); - } - } - - static final class BullshitIteratorB implements IBullshit { - - public EntityLivingBase mPlayer; - public Entity mEntity; - - BullshitIteratorB() {} - - @Override - public void calculateModifier(Enchantment aEnchantment, int aLevel) { - aEnchantment.func_151368_a(mPlayer, mEntity, aLevel); - } - } - } - public static String toSubscript(long no) { char[] chars = Long.toString(no) .toCharArray(); diff --git a/src/main/java/gregtech/common/GT_Client.java b/src/main/java/gregtech/common/GT_Client.java index 4cb063b3b5..d7bd2ad53f 100644 --- a/src/main/java/gregtech/common/GT_Client.java +++ b/src/main/java/gregtech/common/GT_Client.java @@ -88,8 +88,6 @@ import gregtech.api.util.GT_PlayedSound; import gregtech.api.util.GT_Utility; import gregtech.api.util.WorldSpawnedEventBuilder; import gregtech.common.blocks.GT_Item_Machines; -import gregtech.common.entities.GT_Entity_Arrow; -import gregtech.common.entities.GT_Entity_Arrow_Potion; import gregtech.common.render.GT_CapeRenderer; import gregtech.common.render.GT_FlaskRenderer; import gregtech.common.render.GT_FluidDisplayStackRenderer; @@ -98,7 +96,6 @@ import gregtech.common.render.GT_MultiTile_Renderer; import gregtech.common.render.GT_PollutionRenderer; import gregtech.common.render.GT_RenderDrone; import gregtech.common.render.GT_Renderer_Block; -import gregtech.common.render.GT_Renderer_Entity_Arrow; import gregtech.common.render.items.GT_MetaGenerated_Item_Renderer; import gregtech.common.tileentities.debug.GT_MetaTileEntity_AdvDebugStructureWriter; import gregtech.loaders.ExtraIcons; @@ -633,8 +630,6 @@ public class GT_Client extends GT_Proxy implements Runnable { metaGeneratedItemRenderer.registerItem(GT_Bees.combs); } new GT_MetaGenerated_Tool_Renderer(); - new GT_Renderer_Entity_Arrow(GT_Entity_Arrow.class, "arrow"); - new GT_Renderer_Entity_Arrow(GT_Entity_Arrow_Potion.class, "arrow_potions"); new GT_FlaskRenderer(); new GT_FluidDisplayStackRenderer(); MinecraftForge.EVENT_BUS.register(new NEI_GT_Config()); diff --git a/src/main/java/gregtech/common/GT_Proxy.java b/src/main/java/gregtech/common/GT_Proxy.java index bfd47d5c2c..4cd49429c3 100644 --- a/src/main/java/gregtech/common/GT_Proxy.java +++ b/src/main/java/gregtech/common/GT_Proxy.java @@ -67,7 +67,6 @@ import net.minecraft.entity.Entity; import net.minecraft.entity.EntityLivingBase; import net.minecraft.entity.item.EntityItem; import net.minecraft.entity.monster.EntityEnderman; -import net.minecraft.entity.monster.EntitySkeleton; import net.minecraft.entity.player.EntityPlayer; import net.minecraft.entity.projectile.EntityArrow; import net.minecraft.init.Blocks; @@ -169,7 +168,6 @@ import gregtech.api.util.GT_Shaped_Recipe; import gregtech.api.util.GT_Shapeless_Recipe; import gregtech.api.util.GT_Utility; import gregtech.api.util.WorldSpawnedEventBuilder; -import gregtech.common.entities.GT_Entity_Arrow; import gregtech.common.items.GT_MetaGenerated_Item_98; import gregtech.common.items.GT_MetaGenerated_Tool_01; import gregtech.common.items.ID_MetaTool_01; @@ -1551,21 +1549,17 @@ public abstract class GT_Proxy implements IGT_Mod, IGuiHandler, IFuelHandler { @SubscribeEvent public void onEntitySpawningEvent(EntityJoinWorldEvent aEvent) { - if ((aEvent.entity != null) && (!aEvent.entity.worldObj.isRemote)) { - if ((aEvent.entity instanceof EntityItem)) { - ((EntityItem) aEvent.entity).setEntityItemStack( - GT_OreDictUnificator.get(true, ((EntityItem) aEvent.entity).getEntityItem(), true)); - } - if ((this.mSkeletonsShootGTArrows > 0) && (aEvent.entity.getClass() == EntityArrow.class) - && (aEvent.entity.worldObj.rand.nextInt(this.mSkeletonsShootGTArrows) == 0) - && ((((EntityArrow) aEvent.entity).shootingEntity instanceof EntitySkeleton))) { - aEvent.entity.worldObj.spawnEntityInWorld( - new GT_Entity_Arrow( - (EntityArrow) aEvent.entity, - OrePrefixes.arrowGtWood.mPrefixedItems - .get(aEvent.entity.worldObj.rand.nextInt(OrePrefixes.arrowGtWood.mPrefixedItems.size())))); - aEvent.entity.setDead(); - } + if (aEvent.entity == null) { + return; + } + + if (aEvent.entity.worldObj.isRemote) { + return; + } + + if ((aEvent.entity instanceof EntityItem)) { + ((EntityItem) aEvent.entity) + .setEntityItemStack(GT_OreDictUnificator.get(true, ((EntityItem) aEvent.entity).getEntityItem(), true)); } } diff --git a/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java b/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java deleted file mode 100644 index 758888c720..0000000000 --- a/src/main/java/gregtech/common/entities/GT_Entity_Arrow.java +++ /dev/null @@ -1,438 +0,0 @@ -package gregtech.common.entities; - -import java.util.List; -import java.util.UUID; - -import net.minecraft.block.Block; -import net.minecraft.block.material.Material; -import net.minecraft.enchantment.Enchantment; -import net.minecraft.enchantment.EnchantmentHelper; -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.entity.monster.EntityCreeper; -import net.minecraft.entity.monster.EntityEnderman; -import net.minecraft.entity.player.EntityPlayer; -import net.minecraft.entity.player.EntityPlayerMP; -import net.minecraft.entity.projectile.EntityArrow; -import net.minecraft.init.Blocks; -import net.minecraft.init.Items; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.network.play.server.S2BPacketChangeGameState; -import net.minecraft.potion.Potion; -import net.minecraft.util.AxisAlignedBB; -import net.minecraft.util.DamageSource; -import net.minecraft.util.MathHelper; -import net.minecraft.util.MovingObjectPosition; -import net.minecraft.util.Vec3; -import net.minecraft.world.World; -import net.minecraft.world.WorldServer; -import net.minecraftforge.common.util.FakePlayerFactory; - -import com.mojang.authlib.GameProfile; - -import gregtech.api.enums.ParticleFX; -import gregtech.api.objects.ItemData; -import gregtech.api.util.GT_OreDictUnificator; -import gregtech.api.util.GT_Utility; -import gregtech.api.util.WorldSpawnedEventBuilder; - -public class GT_Entity_Arrow extends EntityArrow { - - private int mHitBlockX = -1; - private int mHitBlockY = -1; - private int mHitBlockZ = -1; - private Block mHitBlock = Blocks.air; - private int mHitBlockMeta = 0; - private boolean inGround = false; - private int mTicksAlive = 0; - private int ticksInAir = 0; - private int mKnockback = 0; - private ItemStack mArrow = null; - - public GT_Entity_Arrow(World aWorld) { - super(aWorld); - } - - public GT_Entity_Arrow(World aWorld, double aX, double aY, double aZ) { - super(aWorld, aX, aY, aZ); - } - - public GT_Entity_Arrow(World aWorld, EntityLivingBase aEntity, float aSpeed) { - super(aWorld, aEntity, aSpeed); - } - - public GT_Entity_Arrow(EntityArrow aArrow, ItemStack aStack) { - super(aArrow.worldObj); - NBTTagCompound tNBT = new NBTTagCompound(); - aArrow.writeToNBT(tNBT); - readFromNBT(tNBT); - setArrowItem(aStack); - } - - @Override - public void onUpdate() { - onEntityUpdate(); - if ((this.mArrow == null) && (!this.worldObj.isRemote)) { - setDead(); - return; - } - Entity tShootingEntity = this.shootingEntity; - if ((this.prevRotationPitch == 0.0F) && (this.prevRotationYaw == 0.0F)) { - float f = MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ); - this.prevRotationYaw = (this.rotationYaw = (float) (Math.atan2(this.motionX, this.motionZ) * 180.0D - / Math.PI)); - this.prevRotationPitch = (this.rotationPitch = (float) (Math.atan2(this.motionY, f) * 180.0D / Math.PI)); - } - if (this.mTicksAlive++ == 3000) { - setDead(); - } - Block tBlock = this.worldObj.getBlock(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - if (tBlock.getMaterial() != Material.air) { - tBlock.setBlockBoundsBasedOnState(this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - AxisAlignedBB axisalignedbb = tBlock - .getCollisionBoundingBoxFromPool(this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - if ((axisalignedbb != null) - && (axisalignedbb.isVecInside(Vec3.createVectorHelper(this.posX, this.posY, this.posZ)))) { - this.inGround = true; - } - } - if (this.arrowShake > 0) { - this.arrowShake -= 1; - } - if (this.inGround) { - int j = this.worldObj.getBlockMetadata(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - if ((tBlock != this.mHitBlock) || (j != this.mHitBlockMeta)) { - this.inGround = false; - this.motionX *= this.rand.nextFloat() * 0.2F; - this.motionY *= this.rand.nextFloat() * 0.2F; - this.motionZ *= this.rand.nextFloat() * 0.2F; - this.mTicksAlive = 0; - this.ticksInAir = 0; - } - } else { - this.ticksInAir += 1; - Vec3 vec31 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ); - Vec3 vec3 = Vec3 - .createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - MovingObjectPosition tVector = this.worldObj.func_147447_a(vec31, vec3, false, true, false); - vec31 = Vec3.createVectorHelper(this.posX, this.posY, this.posZ); - vec3 = Vec3 - .createVectorHelper(this.posX + this.motionX, this.posY + this.motionY, this.posZ + this.motionZ); - if (tVector != null) { - vec3 = Vec3.createVectorHelper(tVector.hitVec.xCoord, tVector.hitVec.yCoord, tVector.hitVec.zCoord); - } - Entity tHitEntity = null; - List tAllPotentiallyHitEntities = this.worldObj.getEntitiesWithinAABBExcludingEntity( - this, - this.boundingBox.addCoord(this.motionX, this.motionY, this.motionZ) - .expand(1.0D, 1.0D, 1.0D)); - double tLargestDistance = Double.MAX_VALUE; - for (Entity potentiallyHitEntity : tAllPotentiallyHitEntities) { - if ((potentiallyHitEntity.canBeCollidedWith()) - && ((potentiallyHitEntity != tShootingEntity) || (this.ticksInAir >= 5))) { - AxisAlignedBB axisalignedbb1 = potentiallyHitEntity.boundingBox.expand(0.3D, 0.3D, 0.3D); - MovingObjectPosition movingobjectposition1 = axisalignedbb1.calculateIntercept(vec31, vec3); - if (movingobjectposition1 != null) { - double tDistance = vec31.distanceTo(movingobjectposition1.hitVec); - if (tDistance < tLargestDistance) { - tHitEntity = potentiallyHitEntity; - tLargestDistance = tDistance; - } - } - } - } - if (tHitEntity != null) { - tVector = new MovingObjectPosition(tHitEntity); - } - if ((tVector != null) && ((tVector.entityHit instanceof EntityPlayer entityplayer))) { - if ((entityplayer.capabilities.disableDamage) || (((tShootingEntity instanceof EntityPlayer)) - && (!((EntityPlayer) tShootingEntity).canAttackPlayer(entityplayer)))) { - tVector = null; - } - } - if (tVector != null) { - if (tVector.entityHit != null) { - ItemData tData = GT_OreDictUnificator.getItemData(this.mArrow); - - float tMagicDamage = (tVector.entityHit instanceof EntityLivingBase) - ? EnchantmentHelper - .func_152377_a(this.mArrow, ((EntityLivingBase) tVector.entityHit).getCreatureAttribute()) - : 0.0F; - float tDamage = MathHelper.ceiling_double_int( - MathHelper.sqrt_double( - this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ) - * (getDamage() - + ((tData != null) && (tData.mMaterial != null) && (tData.mMaterial.mMaterial != null) - ? tData.mMaterial.mMaterial.mToolQuality / 2.0F - 1.0F - : 0.0F))); - if (getIsCritical()) { - tDamage += this.rand.nextInt((int) (tDamage / 2.0D + 2.0D)); - } - int tFireDamage = (isBurning() ? 5 : 0) - + 4 * EnchantmentHelper.getEnchantmentLevel(Enchantment.fireAspect.effectId, this.mArrow); - int tKnockback = this.mKnockback - + EnchantmentHelper.getEnchantmentLevel(Enchantment.knockback.effectId, this.mArrow); - int tHitTimer = -1; - - int[] tDamages = onHitEntity( - tVector.entityHit, - tShootingEntity == null ? this : tShootingEntity, - this.mArrow == null ? new ItemStack(Items.arrow, 1) : this.mArrow, - (int) (tDamage * 2.0F), - (int) (tMagicDamage * 2.0F), - tKnockback, - tFireDamage, - tHitTimer); - if (tDamages != null) { - tDamage = tDamages[0] / 2.0F; - tMagicDamage = tDamages[1] / 2.0F; - tKnockback = tDamages[2]; - tFireDamage = tDamages[3]; - tHitTimer = tDamages[4]; - if ((tFireDamage > 0) && (!(tVector.entityHit instanceof EntityEnderman))) { - tVector.entityHit.setFire(tFireDamage); - } - if ((!(tHitEntity instanceof EntityPlayer)) - && (EnchantmentHelper.getEnchantmentLevel(Enchantment.looting.effectId, this.mArrow) > 0)) { - EntityPlayer tPlayer = null; - if ((this.worldObj instanceof WorldServer)) { - tPlayer = FakePlayerFactory.get( - (WorldServer) this.worldObj, - new GameProfile( - new UUID(0L, 0L), - (tShootingEntity instanceof EntityLivingBase) - ? tShootingEntity.getCommandSenderName() - : "Arrow")); - } - if (tPlayer != null) { - tPlayer.inventory.currentItem = 0; - tPlayer.inventory.setInventorySlotContents(0, getArrowItem()); - tShootingEntity = tPlayer; - tPlayer.setDead(); - } - } - DamageSource tDamageSource = DamageSource - .causeArrowDamage(this, tShootingEntity == null ? this : tShootingEntity); - if ((tDamage + tMagicDamage > 0.0F) - && (tVector.entityHit.attackEntityFrom(tDamageSource, tDamage + tMagicDamage))) { - if ((tVector.entityHit instanceof EntityLivingBase tHitLivingEntity)) { - if (tHitTimer >= 0) { - tVector.entityHit.hurtResistantTime = tHitTimer; - } - if (((tVector.entityHit instanceof EntityCreeper)) && (EnchantmentHelper - .getEnchantmentLevel(Enchantment.fireAspect.effectId, this.mArrow) > 0)) { - ((EntityCreeper) tVector.entityHit).func_146079_cb(); - } - if (!this.worldObj.isRemote) { - tHitLivingEntity - .setArrowCountInEntity(tHitLivingEntity.getArrowCountInEntity() + 1); - } - if (tKnockback > 0) { - float tKnockbackDivider = MathHelper - .sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ); - if (tKnockbackDivider > 0.0F) { - tHitLivingEntity.addVelocity( - this.motionX * tKnockback * 0.6000000238418579D / tKnockbackDivider, - 0.1D, - this.motionZ * tKnockback * 0.6000000238418579D / tKnockbackDivider); - } - } - GT_Utility.GT_EnchantmentHelper.applyBullshitA( - tHitLivingEntity, - tShootingEntity == null ? this : tShootingEntity, - this.mArrow); - GT_Utility.GT_EnchantmentHelper.applyBullshitB( - (tShootingEntity instanceof EntityLivingBase) ? (EntityLivingBase) tShootingEntity - : null, - tHitLivingEntity, - this.mArrow); - if ((tHitLivingEntity != tShootingEntity) - && ((tHitLivingEntity instanceof EntityPlayer)) - && ((tShootingEntity instanceof EntityPlayerMP))) { - ((EntityPlayerMP) tShootingEntity).playerNetServerHandler - .sendPacket(new S2BPacketChangeGameState(6, 0.0F)); - } - } - if (((tShootingEntity instanceof EntityPlayer)) && (tMagicDamage > 0.0F)) { - ((EntityPlayer) tShootingEntity).onEnchantmentCritical(tVector.entityHit); - } - if ((!(tVector.entityHit instanceof EntityEnderman)) - || (((EntityEnderman) tVector.entityHit).getActivePotionEffect(Potion.weakness) - != null)) { - if (tFireDamage > 0) { - tVector.entityHit.setFire(tFireDamage); - } - playSound("random.bowhit", 1.0F, 1.2F / (this.rand.nextFloat() * 0.2F + 0.9F)); - setDead(); - } - } else { - this.motionX *= -0.1000000014901161D; - this.motionY *= -0.1000000014901161D; - this.motionZ *= -0.1000000014901161D; - this.rotationYaw += 180.0F; - this.prevRotationYaw += 180.0F; - this.ticksInAir = 0; - } - } - } else { - this.mHitBlockX = tVector.blockX; - this.mHitBlockY = tVector.blockY; - this.mHitBlockZ = tVector.blockZ; - this.mHitBlock = this.worldObj.getBlock(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - this.mHitBlockMeta = this.worldObj - .getBlockMetadata(this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ); - this.motionX = ((float) (tVector.hitVec.xCoord - this.posX)); - this.motionY = ((float) (tVector.hitVec.yCoord - this.posY)); - this.motionZ = ((float) (tVector.hitVec.zCoord - this.posZ)); - float f2 = MathHelper.sqrt_double( - this.motionX * this.motionX + this.motionY * this.motionY + this.motionZ * this.motionZ); - this.posX -= this.motionX / f2 * 0.0500000007450581D; - this.posY -= this.motionY / f2 * 0.0500000007450581D; - this.posZ -= this.motionZ / f2 * 0.0500000007450581D; - playSound("random.bowhit", 1.0F, 1.2F / (this.rand.nextFloat() * 0.2F + 0.9F)); - this.inGround = true; - this.arrowShake = 7; - setIsCritical(false); - if (this.mHitBlock.getMaterial() != Material.air) { - this.mHitBlock.onEntityCollidedWithBlock( - this.worldObj, - this.mHitBlockX, - this.mHitBlockY, - this.mHitBlockZ, - this); - } - if ((!this.worldObj.isRemote) - && (EnchantmentHelper.getEnchantmentLevel(Enchantment.fireAspect.effectId, this.mArrow) > 2)) { - GT_Utility - .setCoordsOnFire(this.worldObj, this.mHitBlockX, this.mHitBlockY, this.mHitBlockZ, true); - } - if (breaksOnImpact()) { - setDead(); - } - } - } - WorldSpawnedEventBuilder.ParticleEventBuilder events = new WorldSpawnedEventBuilder.ParticleEventBuilder() - .setWorld(this.worldObj); - - if (getIsCritical()) { - events.setIdentifier(ParticleFX.CRIT) - .setMotion(-this.motionX, -this.motionY + 0.2D, -this.motionZ).times( - 4, - (x, i) -> x - .setPosition( - this.posX + this.motionX * i / 4.0D, - this.posY + this.motionY * i / 4.0D, - this.posZ + this.motionZ * i / 4.0D) - .run()); - } - this.posX += this.motionX; - this.posY += this.motionY; - this.posZ += this.motionZ; - - this.rotationYaw = ((float) (Math.atan2(this.motionX, this.motionZ) * 180.0D / Math.PI)); - for (this.rotationPitch = ((float) (Math - .atan2(this.motionY, MathHelper.sqrt_double(this.motionX * this.motionX + this.motionZ * this.motionZ)) - * 180.0D - / Math.PI)); this.rotationPitch - this.prevRotationPitch < -180.0F; this.prevRotationPitch -= 360.0F) {} - while (this.rotationPitch - this.prevRotationPitch >= 180.0F) { - this.prevRotationPitch += 360.0F; - } - while (this.rotationYaw - this.prevRotationYaw < -180.0F) { - this.prevRotationYaw -= 360.0F; - } - while (this.rotationYaw - this.prevRotationYaw >= 180.0F) { - this.prevRotationYaw += 360.0F; - } - this.rotationPitch = (this.prevRotationPitch + (this.rotationPitch - this.prevRotationPitch) * 0.2F); - this.rotationYaw = (this.prevRotationYaw + (this.rotationYaw - this.prevRotationYaw) * 0.2F); - float tFrictionMultiplier = 0.99F; - if (isInWater()) { - events.setMotion(-this.motionX, -this.motionY + 0.2D, -this.motionZ) - .setIdentifier(ParticleFX.BUBBLE) - .setPosition( - this.posX - this.motionX * 0.25D, - this.posY - this.motionY * 0.25D, - this.posZ - this.motionZ * 0.25D) - .times(4, Runnable::run); - tFrictionMultiplier = 0.8F; - } - if (isWet()) { - extinguish(); - } - this.motionX *= tFrictionMultiplier; - this.motionY *= tFrictionMultiplier; - this.motionZ *= tFrictionMultiplier; - this.motionY -= 0.0500000007450581D; - setPosition(this.posX, this.posY, this.posZ); - func_145775_I(); - } - } - - @Override - public void writeEntityToNBT(NBTTagCompound aNBT) { - super.writeEntityToNBT(aNBT); - aNBT.setShort("xTile", (short) this.mHitBlockX); - aNBT.setShort("yTile", (short) this.mHitBlockY); - aNBT.setShort("zTile", (short) this.mHitBlockZ); - aNBT.setShort("life", (short) this.mTicksAlive); - aNBT.setByte("inTile", (byte) Block.getIdFromBlock(this.mHitBlock)); - aNBT.setByte("inData", (byte) this.mHitBlockMeta); - aNBT.setByte("shake", (byte) this.arrowShake); - aNBT.setByte("inGround", (byte) (this.inGround ? 1 : 0)); - aNBT.setByte("pickup", (byte) this.canBePickedUp); - aNBT.setDouble("damage", getDamage()); - aNBT.setTag("mArrow", this.mArrow == null ? null : this.mArrow.writeToNBT(new NBTTagCompound())); - } - - @Override - public void readEntityFromNBT(NBTTagCompound aNBT) { - super.readEntityFromNBT(aNBT); - this.mHitBlockX = aNBT.getShort("xTile"); - this.mHitBlockY = aNBT.getShort("yTile"); - this.mHitBlockZ = aNBT.getShort("zTile"); - this.mTicksAlive = aNBT.getShort("life"); - this.mHitBlock = Block.getBlockById(aNBT.getByte("inTile") & 0xFF); - this.mHitBlockMeta = (aNBT.getByte("inData") & 0xFF); - this.arrowShake = (aNBT.getByte("shake") & 0xFF); - this.inGround = (aNBT.getByte("inGround") == 1); - setDamage(aNBT.getDouble("damage")); - this.canBePickedUp = aNBT.getByte("pickup"); - this.mArrow = GT_Utility.loadItem(aNBT, "mArrow"); - } - - @Override - public void onCollideWithPlayer(EntityPlayer aPlayer) { - if ((!this.worldObj.isRemote) && (this.inGround) - && (this.arrowShake <= 0) - && (this.canBePickedUp == 1) - && (aPlayer.inventory.addItemStackToInventory(getArrowItem()))) { - playSound("random.pop", 0.2F, ((this.rand.nextFloat() - this.rand.nextFloat()) * 0.7F + 1.0F) * 2.0F); - aPlayer.onItemPickup(this, 1); - setDead(); - } - } - - public int[] onHitEntity(Entity aHitEntity, Entity aShootingEntity, ItemStack aArrow, int aRegularDamage, - int aMagicDamage, int aKnockback, int aFireDamage, int aHitTimer) { - return new int[] { aRegularDamage, aMagicDamage, aKnockback, aFireDamage, aHitTimer }; - } - - public ItemStack getArrowItem() { - return GT_Utility.copyOrNull(this.mArrow); - } - - public void setArrowItem(ItemStack aStack) { - this.mArrow = GT_Utility.updateItemStack(GT_Utility.copyAmount(1, aStack)); - } - - public boolean breaksOnImpact() { - return false; - } - - @Override - public void setKnockbackStrength(int aKnockback) { - this.mKnockback = aKnockback; - } -} diff --git a/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java b/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java deleted file mode 100644 index 9b520831b6..0000000000 --- a/src/main/java/gregtech/common/entities/GT_Entity_Arrow_Potion.java +++ /dev/null @@ -1,78 +0,0 @@ -package gregtech.common.entities; - -import net.minecraft.entity.Entity; -import net.minecraft.entity.EntityLivingBase; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NBTTagCompound; -import net.minecraft.potion.PotionEffect; -import net.minecraft.world.World; - -public class GT_Entity_Arrow_Potion extends GT_Entity_Arrow { - - private int[] mPotions = new int[0]; - - public GT_Entity_Arrow_Potion(World aWorld) { - super(aWorld); - } - - public GT_Entity_Arrow_Potion(World aWorld, double aX, double aY, double aZ) { - super(aWorld, aX, aY, aZ); - } - - public GT_Entity_Arrow_Potion(World aWorld, EntityLivingBase aEntity, float aSpeed) { - super(aWorld, aEntity, aSpeed); - } - - @Override - public void writeEntityToNBT(NBTTagCompound aNBT) { - super.writeEntityToNBT(aNBT); - aNBT.setIntArray("mPotions", this.mPotions); - } - - @Override - public void readEntityFromNBT(NBTTagCompound aNBT) { - super.readEntityFromNBT(aNBT); - setPotions(aNBT.getIntArray("mPotions")); - } - - @Override - public boolean breaksOnImpact() { - return true; - } - - public int[] getPotions() { - return this.mPotions; - } - - public void setPotions(int... aPotions) { - if (aPotions != null) { - this.mPotions = aPotions; - } - } - - @Override - public int[] onHitEntity(Entity aHitEntity, Entity aShootingEntity, ItemStack aArrow, int aRegularDamage, - int aMagicDamage, int aKnockback, int aFireDamage, int aHitTimer) { - if ((aHitEntity instanceof EntityLivingBase)) { - for (int i = 3; i < this.mPotions.length; i += 4) { - if (aHitEntity.worldObj.rand.nextInt(100) < this.mPotions[i]) { - ((EntityLivingBase) aHitEntity).addPotionEffect( - new PotionEffect( - this.mPotions[(i - 3)], - this.mPotions[(i - 2)], - this.mPotions[(i - 1)], - false)); - } - } - } - return super.onHitEntity( - aHitEntity, - aShootingEntity, - aArrow, - 1, - aMagicDamage, - aKnockback, - aFireDamage, - aHitTimer); - } -} diff --git a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java index 6b9ee54767..dbd6d7404b 100644 --- a/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java +++ b/src/main/java/gregtech/common/items/GT_MetaGenerated_Item_01.java @@ -52,33 +52,6 @@ import static gregtech.client.GT_TooltipHandler.Tier.UV; import static gregtech.client.GT_TooltipHandler.Tier.UXV; import static gregtech.client.GT_TooltipHandler.Tier.ZPM; import static gregtech.client.GT_TooltipHandler.registerTieredTooltip; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Empty; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Holy_Water; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Poison; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Poison_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Poison_Strong; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Slowness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Slowness_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Weakness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Head_Glass_Weakness_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Empty; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Holy_Water; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Poison; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Poison_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Poison_Strong; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Slowness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Slowness_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Weakness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Plastic_Glass_Weakness_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Empty; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Holy_Water; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Poison; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Poison_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Poison_Strong; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Slowness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Slowness_Long; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Weakness; -import static gregtech.common.items.ID_MetaItem_01.Arrow_Wooden_Glass_Weakness_Long; import static gregtech.common.items.ID_MetaItem_01.Battery_Hull_HV; import static gregtech.common.items.ID_MetaItem_01.Battery_Hull_LV; import static gregtech.common.items.ID_MetaItem_01.Battery_Hull_MV; @@ -520,7 +493,6 @@ import gregtech.common.covers.GT_Cover_Shutter; import gregtech.common.covers.GT_Cover_SolarPanel; import gregtech.common.covers.GT_Cover_SteamRegulator; import gregtech.common.covers.GT_Cover_SteamValve; -import gregtech.common.items.behaviors.Behaviour_Arrow_Potion; import gregtech.common.items.behaviors.Behaviour_Cover_Tool; import gregtech.common.items.behaviors.Behaviour_DataOrb; import gregtech.common.items.behaviors.Behaviour_DataStick; @@ -698,216 +670,6 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 { ItemList.CompressedFireclay.set(addItem(Compressed_Fireclay.ID, "Compressed Fireclay", "Brick-shaped")); ItemList.Firebrick.set(addItem(Firebrick.ID, "Firebrick", "Heat resistant")); - ItemList.Arrow_Head_Glass_Emtpy.set( - addItem( - Arrow_Head_Glass_Empty.ID, - "Empty Glass Arrow Head", - "Fill with Potions before use", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L))); - ItemList.Arrow_Head_Glass_Poison.set( - addItem( - Arrow_Head_Glass_Poison.ID, - "Poison Glass Arrow Head", - "Glass Arrow filled with Poison", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Poison_Long.set( - addItem( - Arrow_Head_Glass_Poison_Long.ID, - "Poison Glass Arrow Head", - "Glass Arrow filled with stretched Poison", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Poison_Strong.set( - addItem( - Arrow_Head_Glass_Poison_Strong.ID, - "Poison Glass Arrow Head", - "Glass Arrow filled with strong Poison", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Slowness.set( - addItem( - Arrow_Head_Glass_Slowness.ID, - "Slowness Glass Arrow Head", - "Glass Arrow filled with Laming Brew", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Slowness_Long.set( - addItem( - Arrow_Head_Glass_Slowness_Long.ID, - "Slowness Glass Arrow Head", - "Glass Arrow filled with stretched Laming Brew", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Weakness.set( - addItem( - Arrow_Head_Glass_Weakness.ID, - "Weakness Glass Arrow Head", - "Glass Arrow filled with Weakening Brew", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Weakness_Long.set( - addItem( - Arrow_Head_Glass_Weakness_Long.ID, - "Weakness Glass Arrow Head", - "Glass Arrow filled with stretched Weakening Brew", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Head_Glass_Holy_Water.set( - addItem( - Arrow_Head_Glass_Holy_Water.ID, - "Holy Water Glass Arrow Head", - "Glass Arrow filled with Holy Water", - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L))); - - ItemList.Arrow_Wooden_Glass_Emtpy.set( - addItem( - Arrow_Wooden_Glass_Empty.ID, - "Regular Glass Vial Arrow", - "Empty Glass Arrow", - new Behaviour_Arrow_Potion(1.0F, 6.0F), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L))); - ItemList.Arrow_Wooden_Glass_Poison.set( - addItem( - Arrow_Wooden_Glass_Poison.ID, - "Regular Poison Arrow", - "Glass Arrow filled with Poison", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Poison_Long.set( - addItem( - Arrow_Wooden_Glass_Poison_Long.ID, - "Regular Poison Arrow", - "Glass Arrow filled with stretched Poison", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Poison_Strong.set( - addItem( - Arrow_Wooden_Glass_Poison_Strong.ID, - "Regular Poison Arrow", - "Glass Arrow filled with strong Poison", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.poison.id, 450, 1, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Slowness.set( - addItem( - Arrow_Wooden_Glass_Slowness.ID, - "Regular Slowness Arrow", - "Glass Arrow filled with Laming Brew", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Slowness_Long.set( - addItem( - Arrow_Wooden_Glass_Slowness_Long.ID, - "Regular Slowness Arrow", - "Glass Arrow filled with stretched Laming Brew", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Weakness.set( - addItem( - Arrow_Wooden_Glass_Weakness.ID, - "Regular Weakness Arrow", - "Glass Arrow filled with Weakening Brew", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Weakness_Long.set( - addItem( - Arrow_Wooden_Glass_Weakness_Long.ID, - "Regular Weakness Arrow", - "Glass Arrow filled with stretched Weakening Brew", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Potion.weakness.id, 1800, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Wooden_Glass_Holy_Water.set( - addItem( - Arrow_Wooden_Glass_Holy_Water.ID, - "Regular Holy Water Arrow", - "Glass Arrow filled with Holy Water", - new Behaviour_Arrow_Potion(1.0F, 6.0F, Enchantment.smite, 10), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L))); - - ItemList.Arrow_Plastic_Glass_Emtpy.set( - addItem( - Arrow_Plastic_Glass_Empty.ID, - "Light Glass Vial Arrow", - "Empty Glass Arrow", - new Behaviour_Arrow_Potion(1.5F, 6.0F), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VACUOS, 1L))); - ItemList.Arrow_Plastic_Glass_Poison.set( - addItem( - Arrow_Plastic_Glass_Poison.ID, - "Light Poison Arrow", - "Glass Arrow filled with Poison", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Poison_Long.set( - addItem( - Arrow_Plastic_Glass_Poison_Long.ID, - "Light Poison Arrow", - "Glass Arrow filled with stretched Poison", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Poison_Strong.set( - addItem( - Arrow_Plastic_Glass_Poison_Strong.ID, - "Light Poison Arrow", - "Glass Arrow filled with strong Poison", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.poison.id, 450, 1, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Slowness.set( - addItem( - Arrow_Plastic_Glass_Slowness.ID, - "Light Slowness Arrow", - "Glass Arrow filled with Laming Brew", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Slowness_Long.set( - addItem( - Arrow_Plastic_Glass_Slowness_Long.ID, - "Light Slowness Arrow", - "Glass Arrow filled with stretched Laming Brew", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.moveSlowdown.id, 1800, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Weakness.set( - addItem( - Arrow_Plastic_Glass_Weakness.ID, - "Light Weakness Arrow", - "Glass Arrow filled with Weakening Brew", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 900, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Weakness_Long.set( - addItem( - Arrow_Plastic_Glass_Weakness_Long.ID, - "Light Weakness Arrow", - "Glass Arrow filled with stretched Weakening Brew", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Potion.weakness.id, 1800, 0, 100), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.VENENUM, 1L))); - ItemList.Arrow_Plastic_Glass_Holy_Water.set( - addItem( - Arrow_Plastic_Glass_Holy_Water.ID, - "Light Holy Water Arrow", - "Glass Arrow filled with Holy Water", - new Behaviour_Arrow_Potion(1.5F, 6.0F, Enchantment.smite, 10), - new TC_Aspects.TC_AspectStack(TC_Aspects.TELUM, 1L), - new TC_Aspects.TC_AspectStack(TC_Aspects.AURAM, 1L))); - ItemList.Shape_Empty.set( addItem( Shape_Empty.ID, @@ -4744,117 +4506,6 @@ public class GT_MetaGenerated_Item_01 extends GT_MetaGenerated_Item_X32 { new Object[] { "PSP", "PCP", "PBP", 'P', OrePrefixes.plate.get(Materials.Aluminium), 'S', ItemList.Tool_DataStick.get(1L), 'C', ItemList.Cover_Screen.get(1L), 'B', ItemList.Battery_RE_MV_Lithium.get(1L) }); - - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Emtpy.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Emtpy, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Poison.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Poison_Long.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Long, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Poison_Strong.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Strong, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Slowness.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Slowness_Long.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness_Long, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Weakness.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Weakness_Long.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Weakness_Long, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Wooden_Glass_Holy_Water.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Holy_Water, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Wood) }); - - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Glass_Emtpy.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Emtpy, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Glass_Poison.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Glass_Poison_Long.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Long, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Glass_Poison_Strong.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Poison_Strong, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Glass_Slowness.get(1L), - GT_ModHandler.RecipeBits.BUFFERED | GT_ModHandler.RecipeBits.NOT_REMOVABLE - | GT_ModHandler.RecipeBits.REVERSIBLE, - new Object[] { aTextArrow, aTextStick, aTextFeather, 'A', ItemList.Arrow_Head_Glass_Slowness, 'F', - OreDictNames.craftingFeather, 'S', OrePrefixes.stick.get(Materials.Plastic) }); - GT_ModHandler.addCraftingRecipe( - ItemList.Arrow_Plastic_Gla