Bugfixes, improvements, and Katana upgrades.

This commit is contained in:
John Yorke committed 2016-10-30 00:20:56 -03:00
1 parent 015167ae96
commit bc8cc766f0
25 files changed
+667 -139

No files matched your search

@@ -1,7 +1,6 @@
package taintedmagic.client;
import net.minecraft.client.Minecraft;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.world.World;
import net.minecraftforge.client.MinecraftForgeClient;
@@ -10,11 +9,10 @@ import taintedmagic.client.handler.HUDHandler;
import taintedmagic.client.renderer.RenderItemKatana;
import taintedmagic.client.renderer.RenderTaintBubble;
import taintedmagic.common.CommonProxy;
import taintedmagic.common.TaintedMagic;
import taintedmagic.common.entities.EntityEldritchOrbAttack;
import taintedmagic.common.entities.EntityTaintBubble;
import taintedmagic.common.helper.TaintedMagicHelper;
import taintedmagic.common.helper.Vector3;
import taintedmagic.common.items.tools.ItemKatana;
import taintedmagic.common.registry.ItemRegistry;
import thaumcraft.client.fx.ParticleEngine;
import thaumcraft.client.fx.particles.FXWisp;
@@ -70,7 +68,7 @@ public class ClientProxy extends CommonProxy
ef.setGravity(0.0F);
ef.shrink = true;
ef.noClip = true;
Vector3 movement = getDistanceVectorBetween(ef, p);
Vector3 movement = TaintedMagicHelper.getDistanceBetween(ef, p);
ef.addVelocity(movement.x * 2.5, 0, movement.z * 2.5);
ParticleEngine.instance.addEffect(w, ef);
@@ -78,12 +76,30 @@ public class ClientProxy extends CommonProxy
}
}
public static Vector3 getDistanceVectorBetween (Entity e, Entity target)
@Override
public void spawnWindParticles (World w)
{
Vector3 fromPosition = new Vector3(e.posX, e.posY, e.posZ);
Vector3 toPosition = new Vector3(target.posX, target.posY, target.posZ);
Vector3 dist = fromPosition.sub(toPosition);
dist.normalize();
return dist;
EntityPlayer p = getClientPlayer();
for (int i = 1; i < 150; i++)
{
double xp = (-Math.random() * 5.0F) + (Math.random() * 5.0F);
double zp = (-Math.random() * 5.0F) + (Math.random() * 5.0F);
double yp = (-Math.random() * 5.0F) + (Math.random() * 5.0F);
double off = Math.random() * 0.1;
float red = (0.8F + p.worldObj.rand.nextFloat() * 0.5F);
float green = (0.8F + p.worldObj.rand.nextFloat() * 0.5F);
float blue = (0.6F + p.worldObj.rand.nextFloat() * 0.5F);
FXWisp ef = new FXWisp(w, p.posX + xp + off, p.posY + yp + off, p.posZ + zp + off, 0.25F + ((float) Math.random() * 0.25F), red, green, blue);
ef.setGravity(0.0F);
ef.shrink = true;
ef.noClip = true;
Vector3 movement = TaintedMagicHelper.getDistanceBetween(ef, p);
ef.addVelocity(movement.x * 0.5, 0, movement.z * 0.5);
ParticleEngine.instance.addEffect(w, ef);
}
}
}
@@ -1,9 +1,11 @@
package taintedmagic.client.handler;
import net.minecraft.client.Minecraft;
import net.minecraft.item.ItemStack;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraftforge.client.event.RenderGameOverlayEvent;
import net.minecraftforge.client.event.RenderGameOverlayEvent.ElementType;
import taintedmagic.common.items.tools.ItemKatana;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
public class HUDHandler
@@ -14,7 +16,14 @@ public class HUDHandler
if (event.type == ElementType.ALL)
{
Minecraft mc = Minecraft.getMinecraft();
ItemStack equippedStack = mc.thePlayer.getCurrentEquippedItem();
EntityPlayer p = mc.thePlayer;
ScaledResolution r = event.resolution;
float pt = event.partialTicks;
if (mc.currentScreen == null)
{
ItemKatana.renderHUD(r, p, pt);
}
}
}
}
@@ -0,0 +1,44 @@
package taintedmagic.client.helper;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.MathHelper;
import org.lwjgl.opengl.GL11;
import thaumcraft.client.lib.UtilsFX;
public class TaintedMagicClientHelper
{
/**
* TC method to draw runes on runed staves
*/
public static void drawRune (double x, double y, double z, int rune, EntityPlayer player)
{
GL11.glPushMatrix();
UtilsFX.bindTexture("textures/misc/script.png");
float r = MathHelper.sin( (player.ticksExisted + rune * 5) / 5.0F) * 0.1F + 0.88F;
float g = MathHelper.sin( (player.ticksExisted + rune * 5) / 7.0F) * 0.1F + 0.63F;
float alpha = MathHelper.sin( (player.ticksExisted + rune * 5) / 10.0F) * 0.3F;
GL11.glColor4f(r, g, 0.2F, alpha + 0.6F);
GL11.glRotated(90.0D, 0.0D, 0.0D, 1.0D);
GL11.glTranslated(x, y, z);
Tessellator tessellator = Tessellator.instance;
float f = 0.0625F * rune;
float f1 = f + 0.0625F;
float f2 = 0.0F;
float f3 = 1.0F;
tessellator.startDrawingQuads();
tessellator.setColorRGBA_F(r, g, 0.2F, alpha + 0.6F);
tessellator.addVertexWithUV(-0.06D - alpha / 40.0F, 0.06D + alpha / 40.0F, 0.0D, f1, f3);
tessellator.addVertexWithUV(0.06D + alpha / 40.0F, 0.06D + alpha / 40.0F, 0.0D, f1, f2);
tessellator.addVertexWithUV(0.06D + alpha / 40.0F, -0.06D - alpha / 40.0F, 0.0D, f, f2);
tessellator.addVertexWithUV(-0.06D - alpha / 40.0F, -0.06D - alpha / 40.0F, 0.0D, f, f3);
tessellator.draw();
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
GL11.glPopMatrix();
}
}
@@ -10,9 +10,9 @@ import net.minecraft.client.model.ModelRenderer;
*/
public class ModelKatana extends ModelBase
{
ModelRenderer blade;
ModelRenderer grip1;
ModelRenderer grip2;
public ModelRenderer blade;
public ModelRenderer grip1;
public ModelRenderer grip2;
public ModelKatana ()
{
@@ -2,19 +2,20 @@ package taintedmagic.client.renderer;
import net.minecraft.client.Minecraft;
import net.minecraft.client.renderer.OpenGlHelper;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.MathHelper;
import net.minecraftforge.client.IItemRenderer;
import net.minecraftforge.client.IItemRenderer.ItemRenderType;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL14;
import org.lwjgl.opengl.GL21;
import taintedmagic.client.model.ModelKatana;
import taintedmagic.client.model.ModelSaya;
import taintedmagic.client.helper.TaintedMagicClientHelper;
import taintedmagic.common.TaintedMagic;
import taintedmagic.common.items.tools.ItemKatana;
import thaumcraft.common.config.ConfigItems;
import thaumcraft.client.lib.UtilsFX;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@@ -44,41 +45,6 @@ public class RenderItemKatana implements IItemRenderer
GL11.glScalef(1.4F, 1.4F, 1.4F);
GL11.glPushMatrix();
if (t == ItemRenderType.ENTITY)
{
GL11.glScalef(0.5F, 0.5F, 0.5F);
GL11.glTranslatef(0F, 0.5F, 0F);
GL11.glRotatef(180F, 1.0F, 0.0F, 0.0F);
}
else if (t == ItemRenderType.EQUIPPED_FIRST_PERSON)
{
GL11.glScalef(2F, 2F, 2F);
GL11.glTranslatef(2.25F, 1.75F, -0.2F);
GL11.glRotatef(-10F, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(-10F, 0.0F, 0.0F, 1.0F);
}
else if (t == ItemRenderType.INVENTORY)
{
GL11.glScalef(0.4F, 0.4F, 0.4F);
GL11.glRotatef(-65, 1.0F, 0.0F, 0.0F);
GL11.glRotatef(-50, 0.0F, 1.0F, 0.0F);
GL11.glTranslatef(1F, 1F, 0.0F);
}
else
{
GL11.glRotatef(60, 0.0F, 0.0F, 1.0F);
GL11.glRotatef(-40, 1.0F, 0.0F, 0.0F);
GL11.glRotatef(70, 0.0F, 1.0F, 0.0F);
GL11.glTranslatef(0.0F, 2F, 0.65F);
}
Minecraft.getMinecraft().renderEngine.bindTexture(ItemKatana.getTexture(s));
ItemKatana.katana.render(0.0625F);
GL11.glPopMatrix();
if (p.getHeldItem() == null || ! (p.getHeldItem() == s))
{
GL11.glPushMatrix();
@@ -104,8 +70,82 @@ public class RenderItemKatana implements IItemRenderer
ItemKatana.saya.render(0.0625F);
GL11.glPopMatrix();
}
GL11.glScalef(1.0F, 1.0F, 1.0F);
GL11.glPushMatrix();
if (t == ItemRenderType.ENTITY)
{
GL11.glScalef(0.5F, 0.5F, 0.5F);
GL11.glTranslatef(0F, 0.5F, 0F);
GL11.glRotatef(180F, 1.0F, 0.0F, 0.0F);
}
else if (t == ItemRenderType.EQUIPPED_FIRST_PERSON)
{
if (p.isUsingItem())
{
GL11.glTranslatef(5.0F, 1.0F, -0.2F);
GL11.glRotatef(155.0F, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(-20.0F, 1.0F, 0.0F, 0.0F);
GL11.glTranslatef(0.0F, -0.25F, 0.0F);
}
GL11.glScalef(1.5F, 1.5F, 1.5F);
GL11.glTranslatef(2.0F, 1.85F, -0.25F);
GL11.glRotatef(-10F, 0.0F, 1.0F, 0.0F);
GL11.glRotatef(-10F, 0.0F, 0.0F, 1.0F);
}
else if (t == ItemRenderType.INVENTORY)
{
GL11.glScalef(0.4F, 0.4F, 0.4F);
GL11.glRotatef(-65, 1.0F, 0.0F, 0.0F);
GL11.glRotatef(-50, 0.0F, 1.0F, 0.0F);
GL11.glTranslatef(1F, 1F, 0.0F);
}
else
{
GL11.glRotatef(60, 0.0F, 0.0F, 1.0F);
GL11.glRotatef(-40, 1.0F, 0.0F, 0.0F);
GL11.glRotatef(70, 0.0F, 1.0F, 0.0F);
GL11.glTranslatef(0.0F, 2F, 0.65F);
}
Minecraft.getMinecraft().renderEngine.bindTexture(ItemKatana.getTexture(s));
ItemKatana.katana.render(0.0625F);
// Runes
if (ItemKatana.hasAnyInscription(s))
{
GL11.glPushMatrix();
int j = 200;
int k = j % 65536;
int l = j / 65536;
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, k / 1.0F, l / 1.0F);
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(770, 1);
GL11.glRotated(90.0D, 0.0D, 1.0D, 0.0D);
for (int a = 0; a < 14; a++)
{
int rune = (a * 3) % 16;
TaintedMagicClientHelper.drawRune(-1.65D + a * 0.14D, 0D, -0.03D, rune, p);
}
GL11.glRotated(180.0D, 0.0D, 1.0D, 0.0D);
for (int a = 0; a < 14; a++)
{
int rune = (a + 1 * 3) % 16;
TaintedMagicClientHelper.drawRune(-1.65D + a * 0.14D, 0D, -0.03D, rune, p);
}
GL11.glBlendFunc(770, 771);
GL11.glDisable(GL11.GL_BLEND);
GL11.glPopMatrix();
}
GL11.glPopMatrix();
GL11.glScalef(1.0F, 1.0F, 1.0F);
GL11.glEnable(GL11.GL_CULL_FACE);
GL11.glPopMatrix();
@@ -33,22 +33,21 @@ public class RenderTaintBubble extends Render
GL11.glEnable(GL11.GL_BLEND);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE);
GL11.glDepthMask(true);
GL11.glColor4f(1.0F, 1.0F, 1.0F, 0.75F);
Minecraft.getMinecraft().renderEngine.bindTexture(texture);
int p = (int) (8.0F * (bubble.ticksExisted / bubble.duration));
int p = (int) (7.0F * ((float) bubble.ticksExisted / (float) bubble.duration));
float f2 = 0;
float f3 = 1;
float f4 = (6 + p) / 16F;
float f5 = f4 + 0.125F;
float f4 = p / 8.0F;
float f5 = (p + 1) / 8.0F;
float f6 = 1.0F;
float f7 = 0.5F;
float f8 = 0.5F;
float fc = bubble.ticksExisted / bubble.duration;
float s = 0.25F + fc;
float s = 0.5F;
GL11.glScalef(s, s, s);
@@ -56,9 +55,9 @@ public class RenderTaintBubble extends Render
GL11.glRotatef(-this.renderManager.playerViewX, 1.0F, 0.0F, 0.0F);
t.startDrawingQuads();
t.setBrightness(220);
t.setBrightness(240);
t.setNormal(0.0F, 1.0F, 0.0F);
t.setColorRGBA_F(0.3F, 0.0F, 0.3F, 1F);
t.setColorRGBA_F(1.0F, 1.0F, 1.0F, 0.9F);
t.addVertexWithUV(-f7, -f8, 0.0D, f2, f5);
t.addVertexWithUV(f6 - f7, -f8, 0.0D, f3, f5);
@@ -68,7 +67,7 @@ public class RenderTaintBubble extends Render
t.draw();
GL11.glDisable(GL11.GL_BLEND);
GL11.glDisable(32826);
GL11.glPopMatrix();
}
@@ -30,4 +30,8 @@ public class CommonProxy
public void spawnShockwaveParticles (World w)
{
}
public void spawnWindParticles (World w)
{
}
}
@@ -20,6 +20,7 @@ import taintedmagic.common.handler.UpdateHandler;
import taintedmagic.common.lib.LibCreativeTab;
import taintedmagic.common.lib.LibRecipes;
import taintedmagic.common.lib.LibStrings;
import taintedmagic.common.network.PacketHandler;
import taintedmagic.common.registry.BlockRegistry;
import taintedmagic.common.registry.ItemRegistry;
import taintedmagic.common.registry.ModEntityRegistry;
@@ -63,6 +64,7 @@ public class TaintedMagic
proxy.registerClientHandlers();
PacketHandler.init();
ItemRegistry.init();
BlockRegistry.init();
ModEntityRegistry.init();
@@ -1,5 +1,6 @@
package taintedmagic.common.helper;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import taintedmagic.api.IBloodlust;
@@ -12,4 +13,21 @@ public class TaintedMagicHelper
{
return new AspectList().add(Aspect.FIRE, amount).add(Aspect.WATER, amount).add(Aspect.EARTH, amount).add(Aspect.AIR, amount).add(Aspect.ORDER, amount).add(Aspect.ENTROPY, amount);
}
public static Vector3 getDistanceBetween (Entity e, Entity target)
{
Vector3 fromPosition = new Vector3(e.posX, e.posY, e.posZ);
Vector3 toPosition = new Vector3(target.posX, target.posY, target.posZ);
Vector3 dist = fromPosition.sub(toPosition);
dist.normalize();
return dist;
}
public static double getDistanceTo (double x, double y, double z, EntityPlayer p)
{
double var7 = p.posX + 0.5D - x;
double var9 = p.posY + 0.5D - y;
double var11 = p.posZ + 0.5D - z;
return var7 * var7 + var9 * var9 + var11 * var11;
}
}
@@ -2,8 +2,11 @@ package taintedmagic.common.items.tools;
import java.util.List;
import net.minecraft.block.Block;
import net.minecraft.client.Minecraft;
import net.minecraft.client.gui.ScaledResolution;
import net.minecraft.client.renderer.OpenGlHelper;
import net.minecraft.client.renderer.Tessellator;
import net.minecraft.creativetab.CreativeTabs;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
@@ -12,11 +15,15 @@ import net.minecraft.item.EnumAction;
import net.minecraft.item.EnumRarity;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.potion.Potion;
import net.minecraft.potion.PotionEffect;
import net.minecraft.server.MinecraftServer;
import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.MathHelper;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.ResourceLocation;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
@@ -24,13 +31,21 @@ import net.minecraftforge.client.event.RenderPlayerEvent;
import net.minecraftforge.common.MinecraftForge;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import taintedmagic.client.model.ModelKatana;
import taintedmagic.client.model.ModelSaya;
import taintedmagic.common.TaintedMagic;
import taintedmagic.common.entities.EntityTaintBubble;
import taintedmagic.common.helper.TaintedMagicHelper;
import taintedmagic.common.helper.Vector3;
import taintedmagic.common.network.PacketAttackEntityFromClient;
import taintedmagic.common.network.PacketHandler;
import thaumcraft.api.IRepairable;
import thaumcraft.api.IWarpingGear;
import thaumcraft.api.wands.FocusUpgradeType;
import thaumcraft.common.config.Config;
import thaumcraft.common.entities.projectile.EntityEmber;
import cpw.mods.fml.common.eventhandler.SubscribeEvent;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
@@ -51,6 +66,7 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
this.setCreativeTab(TaintedMagic.tabTaintedMagic);
this.setUnlocalizedName("ItemKatana");
this.setHasSubtypes(true);
this.setMaxStackSize(1);
MinecraftForge.EVENT_BUS.register(this);
}
@@ -69,16 +85,54 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
}
if (s.getItemDamage() == 2)
{
e.addPotionEffect(new PotionEffect(Potion.wither.getId(), 60));
e.addPotionEffect(new PotionEffect(Potion.moveSlowdown.getId(), 120, 2));
e.addPotionEffect(new PotionEffect(Config.potionBlurredID, 120));
}
}
catch (Exception ex)
{
}
e.attackEntityFrom(DamageSource.causePlayerDamage((EntityPlayer) p), getAttackDamage(s));
if (hasAnyInscription(s))
{
switch (getInscription(s))
{
case 0 :
{
e.attackEntityFrom(DamageSource.causePlayerDamage((EntityPlayer) p).setFireDamage().setDamageBypassesArmor(), getAttackDamage(s));
e.setFire(5);
break;
}
case 1 :
{
e.attackEntityFrom(DamageSource.causePlayerDamage((EntityPlayer) p).setMagicDamage().setDamageBypassesArmor(), getAttackDamage(s));
try
{
e.addPotionEffect(new PotionEffect(Config.potionTaintPoisonID, 100));
}
catch (Exception ex)
{
}
break;
}
case 2 :
{
e.attackEntityFrom(new DamageSource("wind").setMagicDamage().setDamageBypassesArmor(), getAttackDamage(s));
try
{
e.addPotionEffect(new PotionEffect(Potion.wither.id, 60));
}
catch (Exception ex)
{
}
break;
}
}
}
else e.attackEntityFrom(DamageSource.causePlayerDamage((EntityPlayer) p), getAttackDamage(s));
}
p.worldObj.playSoundAtEntity(p, "thaumcraft:swing", 1.0F, 1.0F);
p.worldObj.playSoundAtEntity(p, "thaumcraft:swing", 0.5F + (float) Math.random(), 0.5F + (float) Math.random());
return super.hitEntity(s, e, p);
}
@@ -89,6 +143,18 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
return true;
}
@Override
public boolean canHarvestBlock (Block b, ItemStack s)
{
return false;
}
@Override
public EnumAction getItemUseAction (ItemStack s)
{
return EnumAction.bow;
}
@SideOnly (Side.CLIENT)
public void getSubItems (Item item, CreativeTabs c, List l)
{
@@ -107,12 +173,11 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
if (s.getItemDamage() == 1) l.add(EnumChatFormatting.GOLD + StatCollector.translateToLocal("enchantment.special.sapgreat"));
l.add(" ");
l.add("\u00A79+" + getAttackDamage(s) + " " + StatCollector.translateToLocal("text.attackdamage"));
}
@Override
public EnumAction getItemUseAction (ItemStack s)
{
return EnumAction.block;
if (s.hasTagCompound() && s.stackTagCompound.hasKey("inscription"))
{
l.add(EnumChatFormatting.GOLD + StatCollector.translateToLocal("text.katana.inscription." + s.stackTagCompound.getInteger("inscription")));
}
}
@Override
@@ -128,13 +193,119 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
case 0 :
return 14.25F;
case 1 :
return 17.75F;
return 17.55F;
case 2 :
return 20.5F;
return 20.75F;
}
return 0;
}
@Override
public int getMaxItemUseDuration (ItemStack s)
{
return 72000;
}
@Override
public ItemStack onItemRightClick (ItemStack s, World w, EntityPlayer p)
{
p.setItemInUse(s, getMaxItemUseDuration(s));
return s;
}
@Override
public void onUsingTick (ItemStack s, EntityPlayer p, int i)
{
super.onUsingTick(s, p, i);
float j = 1.0F + (Math.min(1.0F * (float) p.getItemInUseDuration() / 30, 1.0F) + ((float) Math.random() * 0.25F));
if (p.ticksExisted % 5 == 0) p.worldObj.playSoundAtEntity(p, "thaumcraft:wind", j * 0.1F, j);
}
@Override
public void onPlayerStoppedUsing (ItemStack s, World w, EntityPlayer p, int i)
{
super.onPlayerStoppedUsing(s, w, p, i);
if (!hasAnyInscription(s) || castType(p) == 0 || p.isSneaking())
{
if (w.isRemote)
{
MovingObjectPosition mop = Minecraft.getMinecraft().objectMouseOver;
float mul = Math.min(1.0F + (float) p.getItemInUseDuration() / 40.0F, 2.0F);
if (mop.entityHit != null) PacketHandler.INSTANCE.sendToServer(new PacketAttackEntityFromClient(mop.entityHit, p, this.getAttackDamage(s) * mul));
p.swingItem();
}
p.worldObj.playSoundAtEntity(p, "thaumcraft:swing", 0.5F + (float) Math.random(), 0.5F + (float) Math.random());
}
else if (hasAnyInscription(s) && castType(p) == 1 && !p.isSneaking())
{
switch (getInscription(s))
{
case 0 :
{
for (int a = 0; a < 50; a++)
{
EntityEmber proj = new EntityEmber(p.worldObj, p, 5.0F);
proj.posX += proj.motionX;
proj.posY += proj.motionY;
proj.posZ += proj.motionZ;
proj.damage = 10.0F;
p.worldObj.spawnEntityInWorld(proj);
p.swingItem();
}
break;
}
case 1 :
{
for (int a = 0; a < 50; a++)
{
EntityTaintBubble proj = new EntityTaintBubble(p.worldObj, p, 5.0F, false);
proj.posX += proj.motionX;
proj.posY += proj.motionY;
proj.posZ += proj.motionZ;
proj.damage = 10.0F;
p.worldObj.spawnEntityInWorld(proj);
p.swingItem();
}
break;
}
case 2 :
{
List<EntityLivingBase> ents = p.worldObj.getEntitiesWithinAABB(EntityLivingBase.class, AxisAlignedBB.getBoundingBox(p.posX, p.posY, p.posZ, p.posX + 1, p.posY + 1, p.posZ + 1).expand(5.0D, 5.0D, 5.0D));
if (ents != null && ents.size() > 0)
{
for (int a = 0; a < ents.size(); a++)
{
EntityLivingBase e = ents.get(a);
if (e != p && e.isEntityAlive() && !e.isEntityInvulnerable())
{
double dist = TaintedMagicHelper.getDistanceTo(e.posX, e.posY, e.posZ, p);
if (dist < 2) e.attackEntityFrom(DamageSource.causePlayerDamage(p).setMagicDamage().setDamageBypassesArmor(), 5.0F);
Vector3 movement = TaintedMagicHelper.getDistanceBetween(e, p);
e.addVelocity(movement.x * 3, 0.8, movement.z * 3);
}
}
}
p.swingItem();
TaintedMagic.proxy.spawnWindParticles(w);
break;
}
default :
break;
}
}
}
public int castType (EntityPlayer p)
{
float f = Math.min((float) p.getItemInUseDuration() / 15.0F, 2.0F);
if (f == 2.0F) return 1;
else return 0;
}
@SideOnly (Side.CLIENT)
@SubscribeEvent
public void onPlayerRender (RenderPlayerEvent.Specials.Post event)
@@ -155,7 +326,7 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
int lightmapX = light % 65536;
int lightmapY = light / 65536;
OpenGlHelper.setLightmapTextureCoords(OpenGlHelper.lightmapTexUnit, lightmapX, lightmapY);
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
if (p.getHeldItem() == null || p.getHeldItem().getItem() != this)
@@ -194,6 +365,86 @@ public class ItemKatana extends Item implements IWarpingGear, IRepairable
}
}
@SideOnly (Side.CLIENT)
public static void renderHUD (ScaledResolution r, EntityPlayer p, float pt)
{
Minecraft mc = Minecraft.getMinecraft();
ItemStack s = mc.thePlayer.getCurrentEquippedItem();
Tessellator t = Tessellator.instance;
if (s != null && s.getItem() instanceof ItemKatana)
{
float tickFract = Math.min((float) p.getItemInUseDuration() / 30.0F, 1.0F);
int x = r.getScaledWidth() / 2 + 725;
int x2 = x + 16;
int y = r.getScaledHeight() / 2 + (p.capabilities.isCreativeMode ? 810 : 755);
int y2 = y + 16;
GL11.glPushMatrix();
GL11.glEnable(GL11.GL_BLEND);
GL11.glEnable(GL12.GL_RESCALE_NORMAL);
GL11.glBlendFunc(GL11.GL_SRC_ALPHA, GL11.GL_ONE_MINUS_SRC_ALPHA);
float sc = 0.315F;
GL11.glScalef(sc, sc, sc);
mc.renderEngine.bindTexture(new ResourceLocation("thaumcraft:textures/misc/script.png"));
for (int rune = 0; rune < 16; rune++)
{
float red = MathHelper.sin( (p.ticksExisted + rune * 5) / 5.0F) * 0.1F + 0.8F;
float green = MathHelper.sin( (p.ticksExisted + rune * 5) / 7.0F) * 0.1F + 0.7F;
float alpha = MathHelper.sin( (p.ticksExisted + rune * 5) / 10.0F) * 0.3F;
float f = 0.0625F * rune;
float f1 = f + 0.0625F;
float f2 = 0.0F;
float f3 = 1.0F;
t.startDrawingQuads();
t.setBrightness(240);
t.setColorRGBA_F(red, green, 0.4F, alpha + 0.7F);
t.addVertexWithUV(x + (rune * 16) - alpha, y2 + alpha, 0, f, f3);
t.addVertexWithUV(x2 + (rune * 16) + alpha, y2 + alpha, 0, f1, f3);
t.addVertexWithUV(x2 + (rune * 16) + alpha, y - alpha, 0, f1, f2);
t.addVertexWithUV(x + (rune * 16) - alpha, y - alpha, 0, f, f2);
t.draw();
if ((int) (16 * tickFract) > rune)
{
t.startDrawingQuads();
t.setBrightness(240);
t.setColorRGBA_F(1.0F - (0.0625F * rune), 0.0F + (0.0625F * rune), 0.0F, 0.9F + alpha);
t.addVertexWithUV(x + (rune * 16) - alpha, y2 + alpha, 0, f, f3);
t.addVertexWithUV(x2 + (rune * 16) + alpha, y2 + alpha, 0, f1, f3);
t.addVertexWithUV(x2 + (rune * 16) + alpha, y - alpha, 0, f1, f2);
t.addVertexWithUV(x + (rune * 16) - alpha, y - alpha, 0, f, f2);
t.draw();
}
}
GL11.glDisable(GL11.GL_BLEND);
GL11.glDisable(GL12.GL_RESCALE_NORMAL);
GL11.glPopMatrix();
}
}
public static boolean hasAnyInscription (ItemStack s)
{
return s.hasTagCompound() && s.stackTagCompound.hasKey("inscription");
}
public static int getInscription (ItemStack s)
{
if (s.hasTagCompound() && s.stackTagCompound.hasKey("inscription")) return s.stackTagCompound.getInteger("inscription");
else return 0;
}
public static ResourceLocation getTexture (ItemStack s)
{
switch (s.getItemDamage())
@@ -45,10 +45,10 @@ public class ItemThaumicDisassembler extends Item
{
super.addInformation(s, p, l, b);
l.add(StatCollector.translateToLocal("text.mode") + ": " + EnumChatFormatting.BLUE + getModeName(s));
l.add(StatCollector.translateToLocal("text.efficiency") + ": " + EnumChatFormatting.BLUE + getEfficiency(s));
l.add("\u00A78" + StatCollector.translateToLocal("text.mode") + ": " + getModeName(s));
l.add("\u00A78" + StatCollector.translateToLocal("text.efficiency") + ": " + (getMode(s) == 3 ? "\u00A7c" : "\u00A7a") + getEfficiency(s));
l.add(" ");
l.add(EnumChatFormatting.BLUE + "+20 " + StatCollector.translateToLocal("text.attackdamage"));
l.add("\u00A79" + "+20 " + StatCollector.translateToLocal("text.attackdamage"));
}
@Override
@@ -144,13 +144,13 @@ public class ItemThaumicDisassembler extends Item
switch (mode)
{
case 0 :
return StatCollector.translateToLocal("text.disassembler.normal");
return "\u00A7a" + StatCollector.translateToLocal("text.disassembler.normal");
case 1 :
return StatCollector.translateToLocal("text.disassembler.slow");
return "\u00A7a" + StatCollector.translateToLocal("text.disassembler.slow");
case 2 :
return StatCollector.translateToLocal("text.disassembler.fast");
return "\u00A7a" + StatCollector.translateToLocal("text.disassembler.fast");
case 3 :
return StatCollector.translateToLocal("text.disassembler.off");
return "\u00A7c" + StatCollector.translateToLocal("text.disassembler.off");
}
return null;
}
@@ -79,7 +79,7 @@ public class ItemFocusTaint extends ItemFocusBasic
public ItemFocusBasic.WandFocusAnimation getAnimation (ItemStack s)
{
return ItemFocusBasic.WandFocusAnimation.WAVE;
return ItemFocusBasic.WandFocusAnimation.CHARGE;
}
public ItemStack onFocusRightClick (ItemStack s, World w, EntityPlayer p, MovingObjectPosition mop)
@@ -100,7 +100,7 @@ public class ItemFocusTaint extends ItemFocusBasic
}
int range = 8;
Vec3 vec3d = p.getLook(range);
if (!p.worldObj.isRemote && p.ticksExisted % 20 == 0) p.worldObj.playSoundAtEntity(p, "thaumcraft:bubble", 0.33F, 2.0F);
if (!p.worldObj.isRemote && p.ticksExisted % 5 == 0) p.worldObj.playSoundAtEntity(p, "thaumcraft:bubble", 0.33F, 2F * (float)Math.random());
int potency = wand.getFocusPotency(s);
if ( (!p.worldObj.isRemote) && (wand.consumeAllVis(s, p, getVisCost(s), true, false)))
@@ -2,11 +2,7 @@ package taintedmagic.common.items.wand;
import java.util.Iterator;
import java.util.List;
import java.util.Random;
import org.lwjgl.opengl.GL11;
import net.minecraft.client.particle.EntityFX;
import net.minecraft.client.renderer.texture.IIconRegister;
import net.minecraft.entity.Entity;
import net.minecraft.entity.player.EntityPlayer;
@@ -15,28 +11,19 @@ import net.minecraft.util.AxisAlignedBB;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EnumChatFormatting;
import net.minecraft.util.IIcon;
import net.minecraft.util.MathHelper;
import net.minecraft.util.MovingObjectPosition;
import net.minecraft.util.StatCollector;
import net.minecraft.world.World;
import cpw.mods.fml.common.network.NetworkRegistry;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
import taintedmagic.common.TaintedMagic;
import taintedmagic.common.entities.EntityEldritchOrbAttack;
import taintedmagic.common.helper.TaintedMagicHelper;
import taintedmagic.common.helper.Vector3;
import thaumcraft.api.aspects.Aspect;
import thaumcraft.api.aspects.AspectList;
import thaumcraft.api.wands.FocusUpgradeType;
import thaumcraft.api.wands.ItemFocusBasic;
import thaumcraft.client.fx.ParticleEngine;
import thaumcraft.client.fx.particles.FXWisp;
import thaumcraft.common.Thaumcraft;
import thaumcraft.common.entities.projectile.EntityPrimalOrb;
import thaumcraft.common.items.wands.ItemWandCasting;
import thaumcraft.common.items.wands.WandManager;
import thaumcraft.common.lib.network.PacketHandler;
import thaumcraft.common.lib.network.fx.PacketFXSonic;
import cpw.mods.fml.relauncher.Side;
import cpw.mods.fml.relauncher.SideOnly;
public class ItemFocusTaintedBlast extends ItemFocusBasic
{
@@ -125,13 +112,13 @@ public class ItemFocusTaintedBlast extends ItemFocusBasic
{
if (eo.isEntityAlive() && !eo.isEntityInvulnerable())
{
double d = getDistanceTo(eo.posX, eo.posY, eo.posZ, p);
double d = TaintedMagicHelper.getDistanceTo(eo.posX, eo.posY, eo.posZ, p);
if (d < 7.0D)
{
eo.attackEntityFrom(DamageSource.magic, 2.0F);
}
}
Vector3 movement = getDistanceBetween(eo, p);
Vector3 movement = TaintedMagicHelper.getDistanceBetween(eo, p);
eo.addVelocity(movement.x * 3, 0.8, movement.z * 3);
}
}
@@ -142,24 +129,6 @@ public class ItemFocusTaintedBlast extends ItemFocusBasic
return null;
}
public static Vector3 getDistanceBetween (Entity e, Entity e2)
{
Vector3 fromPosition = new Vector3(e.posX, e.posY, e.posZ);
Vector3 toPosition = new Vector3(e2.posX, e2.posY, e2.posZ);
Vector3 dist = fromPosition.sub(toPosition);
dist.normalize();
return dist;
}
public static double getDistanceTo (double x, double y, double z, EntityPlayer p)
{
double var7 = p.posX + 0.5D - x;
double var9 = p.posY + 0.5D - y;
double var11 = p.posZ + 0.5D - z;
return var7 * var7 + var9 * var9 + var11 * var11;
}
public FocusUpgradeType[] getPossibleUpgradesByRank (ItemStack s, int rank)
{
switch (rank)
@@ -443,6 +443,66 @@ public class LibRecipes
new ItemStack(Items.emerald),
new ItemStack(Items.iron_ingot),
new ItemStack(ItemRegistry.ItemMaterial, 1, 0) }));
ResearchRegistry.recipes.put("ItemKatanaThaumium:inscription0", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONFIRE", new Object[]{
"inscription",
new NBTTagInt(0) }, 8, new AspectList().add(Aspect.FIRE, 64).add(Aspect.LIGHT, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 0), new ItemStack[]{
ItemApi.getItem("itemFocusFire", 0),
new ItemStack(Items.coal),
new ItemStack(Blocks.netherrack),
new ItemStack(Items.fire_charge),
new ItemStack(Items.blaze_powder),
ItemApi.getItem("itemResource", 1) }));
ResearchRegistry.recipes.put("ItemKatanaThaumium:inscription1", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONTAINT", new Object[]{
"inscription",
new NBTTagInt(1) }, 8, new AspectList().add(Aspect.TAINT, 64).add(Aspect.FLESH, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 0), new ItemStack[]{
new ItemStack(ItemRegistry.ItemFocusTaint),
new ItemStack(ItemRegistry.ItemMaterial, 1, 4),
ItemApi.getBlock("blockJar", 1),
ItemApi.getBlock("blockCustomPlant", 5),
ItemApi.getItem("itemBottleTaint", 0),
ItemApi.getItem("itemResource", 11) }));
ResearchRegistry.recipes.put("ItemKatanaThaumium:inscription2", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONWIND", new Object[]{
"inscription",
new NBTTagInt(2) }, 8, new AspectList().add(Aspect.AIR, 64).add(Aspect.FLIGHT, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 0), new ItemStack[]{
ItemApi.getItem("itemShard", 0),
ItemApi.getItem("itemResource", 6),
new ItemStack(Items.feather),
ItemApi.getItem("itemShard", 6),
new ItemStack(Blocks.tnt),
ItemApi.getItem("itemWispEssence", 0) }));
ResearchRegistry.recipes.put("ItemKatana:inscription0", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONFIRE", new Object[]{
"inscription",
new NBTTagInt(0) }, 8, new AspectList().add(Aspect.FIRE, 64).add(Aspect.LIGHT, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 32767), new ItemStack[]{
ItemApi.getItem("itemFocusFire", 0),
new ItemStack(Items.coal),
new ItemStack(Blocks.netherrack),
new ItemStack(Items.fire_charge),
new ItemStack(Items.blaze_powder),
ItemApi.getItem("itemResource", 1) }));
ResearchRegistry.recipes.put("ItemKatana:inscription1", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONTAINT", new Object[]{
"inscription",
new NBTTagInt(1) }, 8, new AspectList().add(Aspect.TAINT, 64).add(Aspect.FLESH, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 32767), new ItemStack[]{
new ItemStack(ItemRegistry.ItemFocusTaint),
new ItemStack(ItemRegistry.ItemMaterial, 1, 4),
ItemApi.getBlock("blockJar", 1),
ItemApi.getBlock("blockCustomPlant", 5),
ItemApi.getItem("itemBottleTaint", 0),
ItemApi.getItem("itemResource", 11) }));
ResearchRegistry.recipes.put("ItemKatana:inscription2", ThaumcraftApi.addInfusionCraftingRecipe("INSCRIPTIONWIND", new Object[]{
"inscription",
new NBTTagInt(2) }, 8, new AspectList().add(Aspect.AIR, 64).add(Aspect.FLIGHT, 64).add(Aspect.METAL, 16), new ItemStack(ItemRegistry.ItemKatana, 1, 32767), new ItemStack[]{
ItemApi.getItem("itemShard", 0),
ItemApi.getItem("itemResource", 6),
new ItemStack(Items.feather),
ItemApi.getItem("itemShard", 6),
new ItemStack(Blocks.tnt),
ItemApi.getItem("itemWispEssence", 0) }));
}
public static void initArcane ()
@@ -470,7 +530,6 @@ public class LibRecipes
ResearchRegistry.recipes.put("ItemHelmetCultistRobe", ThaumcraftApi.addArcaneCraftingRecipe("CRIMSONROBES", ItemApi.getItem("itemHelmetCultistRobe", 0), new AspectList().add(Aspect.ORDER, 5).add(Aspect.WATER, 5).add(Aspect.EARTH, 5).add(Aspect.AIR, 5).add(Aspect.FIRE, 5).add(Aspect.ENTROPY, 5), new Object[]{
"AAA",
"ABA",
" ",
Character.valueOf('A'),
new ItemStack(ItemRegistry.ItemMaterial, 1, 2),
Character.valueOf('B'),
@@ -548,7 +607,7 @@ public class LibRecipes
ResearchRegistry.recipes.put("ItemMagicFunguar", ThaumcraftApi.addShapelessArcaneCraftingRecipe("MAGICFUNGUAR", new ItemStack(ItemRegistry.ItemMagicFunguar), new AspectList().add(Aspect.ORDER, 1).add(Aspect.WATER, 1).add(Aspect.EARTH, 1).add(Aspect.AIR, 1).add(Aspect.FIRE, 1).add(Aspect.ENTROPY, 1), new Object[]{
new ItemStack(ConfigBlocks.blockCustomPlant, 1, 5),
ItemApi.getItem("itemShard", 32767),
new ItemStack(ConfigItems.itemShard, 32767),
new ItemStack(Blocks.brown_mushroom),
new ItemStack(Blocks.red_mushroom),
new ItemStack(Items.blaze_powder) }));
@@ -5,6 +5,6 @@ public class LibStrings
// LibStrings
public static final String MODID = "TaintedMagic";
public static final String NAME = "Tainted Magic";
public static final String VERSION = "r7.1";
public static final String VERSION = "r7.2";
public static final String DEPENDENCIES = "required-after:Forge@[10.13.2.1291,);required-after:Thaumcraft@[4.2.3.5,);after:ThaumicTinkerer";
}
@@ -0,0 +1,67 @@
package taintedmagic.common.network;
import io.netty.buffer.ByteBuf;
import net.minecraft.entity.Entity;
import net.minecraft.entity.EntityLivingBase;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.util.DamageSource;
import net.minecraft.world.World;
import net.minecraftforge.common.DimensionManager;
import cpw.mods.fml.common.network.simpleimpl.IMessage;
import cpw.mods.fml.common.network.simpleimpl.IMessageHandler;
import cpw.mods.fml.common.network.simpleimpl.MessageContext;
public class PacketAttackEntityFromClient implements IMessage, IMessageHandler<PacketAttackEntityFromClient, IMessage>
{
private int entityID;
private int playerID;
private int dimensionID;
private float dmg;
public PacketAttackEntityFromClient ()
{
}
public PacketAttackEntityFromClient (Entity e, EntityPlayer p, float dmg)
{
this.entityID = e.getEntityId();
this.playerID = p.getEntityId();
this.dimensionID = e.dimension;
this.dmg = dmg;
}
@Override
public IMessage onMessage (PacketAttackEntityFromClient message, MessageContext ctx)
{
World w = DimensionManager.getWorld(message.dimensionID);
if (w == null) return null;
Entity e = w.getEntityByID(message.entityID);
Entity p = w.getEntityByID(message.playerID);
if (e != null && e instanceof EntityLivingBase && p != null && p instanceof EntityPlayer)
{
e.attackEntityFrom(DamageSource.causeIndirectMagicDamage(p, e), message.dmg);
}
return null;
}
@Override
public void fromBytes (ByteBuf buf)
{
this.entityID = buf.readInt();
this.playerID = buf.readInt();
this.dimensionID = buf.readInt();
this.dmg = buf.readFloat();
}
@Override
public void toBytes (ByteBuf buf)
{
buf.writeInt(this.entityID);
buf.writeInt(this.playerID);
buf.writeInt(this.dimensionID);
buf.writeFloat(this.dmg);
}
}
@@ -0,0 +1,16 @@
package taintedmagic.common.network;
import cpw.mods.fml.common.network.NetworkRegistry;
import cpw.mods.fml.common.network.simpleimpl.SimpleNetworkWrapper;
import cpw.mods.fml.relauncher.Side;
public class PacketHandler
{
public static final SimpleNetworkWrapper INSTANCE = NetworkRegistry.INSTANCE.newSimpleChannel("TAINTEDMAGIC".toLowerCase());
public static void init ()
{
int i = 0;
INSTANCE.registerMessage(PacketAttackEntityFromClient.class, PacketAttackEntityFromClient.class, i++, Side.SERVER);
}
}
@@ -244,7 +244,7 @@ public class ResearchRegistry
new ResearchPage((InfusionRecipe) recipes.get("ItemShadowFortressLeggings")) }).registerResearchItem();
ThaumcraftApi.addWarpToResearch("SHADOWFORTRESSARMOR", 3);
new TaintedMagicResearchItem("CAP_cloth", TM, new AspectList().add(Aspect.MAGIC, 4).add(Aspect.CLOTH, 4), 7, 1, 0, new ItemStack(ItemRegistry.ItemWandCap, 1, 1)).setParentsHidden("CAP_gold", "ENCHFABRIC").setConcealed().setSecondary().setPages(new ResearchPage[]{
new TaintedMagicResearchItem("CAP_cloth", TM, new AspectList().add(Aspect.MAGIC, 4).add(Aspect.CLOTH, 4), 5, -3, 0, new ItemStack(ItemRegistry.ItemWandCap, 1, 1)).setParentsHidden("CAP_gold", "ENCHFABRIC").setConcealed().setSecondary().setPages(new ResearchPage[]{
new ResearchPage("1"),
new ResearchPage((IArcaneRecipe) recipes.get("ItemWandCap:1")) }).registerResearchItem();
@@ -269,7 +269,7 @@ public class ResearchRegistry
new TaintedMagicResearchItem("BLOODLUSTUPGRADE", TM, new AspectList().add(Aspect.MAGIC, 4).add(Aspect.HEAL, 8).add(Aspect.WEAPON, 8), 1, -4, 0, new ResourceLocation("taintedmagic:textures/foci/IconBloodlust.png")).setParentsHidden("MACEFOCUS", "FOCALMANIPULATION").setConcealed().setParents("CRYSTALDAGGER").setSecondary().setPages(new ResearchPage[]{ new ResearchPage("1") }).registerResearchItem();
new TaintedMagicResearchItem("THAUMIUMKATANA", TM, new AspectList().add(Aspect.METAL, 8).add(Aspect.MAGIC, 4).add(Aspect.WEAPON, 6), 8, 1, 0, new ItemStack(ItemRegistry.ItemKatana, 1, 0)).setParentsHidden("ARMORFORTRESS").setConcealed().setSecondary().setPages(new ResearchPage[]{
new TaintedMagicResearchItem("THAUMIUMKATANA", TM, new AspectList().add(Aspect.METAL, 8).add(Aspect.MAGIC, 4).add(Aspect.WEAPON, 6), 7, 1, 0, new ItemStack(ItemRegistry.ItemKatana, 1, 0)).setParentsHidden("ARMORFORTRESS").setConcealed().setPages(new ResearchPage[]{
new ResearchPage("1"),
new ResearchPage((InfusionRecipe) recipes.get("ItemKatana:0")) }).registerResearchItem();
@@ -282,5 +282,18 @@ public class ResearchRegistry
new ResearchPage("1"),
new ResearchPage((InfusionRecipe) recipes.get("ItemKatana:2")) }).registerResearchItem();
ThaumcraftApi.addWarpToResearch("SHADOWMETALKATANA", 6);
new TaintedMagicResearchItem("INSCRIPTIONFIRE", TM, new AspectList().add(Aspect.FIRE, 8).add(Aspect.LIGHT, 4).add(Aspect.METAL, 6), 9, 1, 0, new ResourceLocation("taintedmagic:textures/misc/IconINSCRIPTIONFIRE.png")).setParents("THAUMIUMKATANA").setParentsHidden("FOCUSFIRE").setConcealed().setPages(new ResearchPage[]{
new ResearchPage("1"),
new ResearchPage((InfusionRecipe) recipes.get("ItemKatanaThaumium:inscription0")) }).setSecondary().registerResearchItem();
new TaintedMagicResearchItem("INSCRIPTIONTAINT", TM, new AspectList().add(Aspect.TAINT, 8).add(Aspect.FLESH, 4).add(Aspect.METAL, 6), 9, 2, 0, new ResourceLocation("taintedmagic:textures/misc/IconINSCRIPTIONTAINT.png")).setParents("THAUMIUMKATANA").setParentsHidden("TAINTFOCUS").setConcealed().setPages(new ResearchPage[]{
new ResearchPage("1"),
new ResearchPage((InfusionRecipe) recipes.get("ItemKatanaThaumium:inscription1")) }).setSecondary().registerResearchItem();
ThaumcraftApi.addWarpToResearch("INSCRIPTIONTAINT", 4);
new TaintedMagicResearchItem("INSCRIPTIONWIND", TM, new AspectList().add(Aspect.AIR, 8).add(Aspect.MOTION, 4).add(Aspect.METAL, 6), 8, 3, 0, new ResourceLocation("taintedmagic:textures/misc/IconINSCRIPTIONWIND.png")).setParents("THAUMIUMKATANA").setConcealed().setPages(new ResearchPage[]{
new ResearchPage("1"),
new ResearchPage((InfusionRecipe) recipes.get("ItemKatanaThaumium:inscription2")) }).setSecondary().registerResearchItem();
}
}