Added the Sigil of Elasticity, the Sigil of the Claw, and the Sigil of Winter's Breath.

This commit is contained in:
WayofTime 2016-10-14 20:51:21 -04:00
parent 0a1d66a1d9
commit ea43fbce7d
22 changed files with 186 additions and 8 deletions

View file

@ -246,7 +246,10 @@ public class Constants
SIGIL_HOLDING("ItemSigilHolding"),
ARMOUR_POINTS_UPGRADE("ItemLivingArmourPointsUpgrade"),
DEMON_WILL_GAUGE("ItemDemonWillGauge"),
POTION_FLASK("ItemPotionFlask"), ;
POTION_FLASK("ItemPotionFlask"),
SIGIL_CLAW("ItemSigilClaw"),
SIGIL_BOUNCE("ItemSigilBounce"),
SIGIL_FROST("ItemSigilFrost");
@Getter
private final String regName;

View file

@ -53,6 +53,9 @@ public class ItemComponent extends Item implements IVariantProvider
public static final String REAGENT_HOLDING = "reagentHolding";
public static final String CATALYST_LENGTH_1 = "mundaneLength";
public static final String CATALYST_POWER_1 = "mundanePower";
public static final String REAGENT_CLAW = "reagentClaw";
public static final String REAGENT_BOUNCE = "reagentBounce";
public static final String REAGENT_FROST = "reagentFrost";
public ItemComponent()
{
@ -97,6 +100,9 @@ public class ItemComponent extends Item implements IVariantProvider
names.add(27, REAGENT_HOLDING);
names.add(28, CATALYST_LENGTH_1);
names.add(29, CATALYST_POWER_1);
names.add(30, REAGENT_CLAW);
names.add(31, REAGENT_BOUNCE);
names.add(32, REAGENT_FROST);
}
@Override

View file

@ -0,0 +1,21 @@
package WayofTime.bloodmagic.item.sigil;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.potion.PotionEffect;
import net.minecraft.world.World;
import WayofTime.bloodmagic.registry.ModPotions;
public class ItemSigilBounce extends ItemSigilToggleableBase
{
public ItemSigilBounce()
{
super("bounce", 100);
}
@Override
public void onSigilUpdate(ItemStack stack, World world, EntityPlayer player, int itemSlot, boolean isSelected)
{
player.addPotionEffect(new PotionEffect(ModPotions.bounce, 2, 0, true, false));
}
}

View file

@ -0,0 +1,21 @@
package WayofTime.bloodmagic.item.sigil;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.potion.PotionEffect;
import net.minecraft.world.World;
import WayofTime.bloodmagic.registry.ModPotions;
public class ItemSigilClaw extends ItemSigilToggleableBase
{
public ItemSigilClaw()
{
super("claw", 100);
}
@Override
public void onSigilUpdate(ItemStack stack, World world, EntityPlayer player, int itemSlot, boolean isSelected)
{
player.addPotionEffect(new PotionEffect(ModPotions.cling, 2, 0, true, false));
}
}

View file

@ -5,7 +5,6 @@ import net.minecraft.init.MobEffects;
import net.minecraft.item.ItemStack;
import net.minecraft.potion.PotionEffect;
import net.minecraft.world.World;
import WayofTime.bloodmagic.api.Constants;
public class ItemSigilElementalAffinity extends ItemSigilToggleableBase
{

View file

@ -0,0 +1,20 @@
package WayofTime.bloodmagic.item.sigil;
import net.minecraft.enchantment.EnchantmentFrostWalker;
import net.minecraft.entity.player.EntityPlayer;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
public class ItemSigilFrost extends ItemSigilToggleableBase
{
public ItemSigilFrost()
{
super("frost", 100);
}
@Override
public void onSigilUpdate(ItemStack stack, World world, EntityPlayer player, int itemSlot, boolean isSelected)
{
EnchantmentFrostWalker.freezeNearby(player, world, player.getPosition(), 1);
}
}

View file

@ -51,11 +51,14 @@ import WayofTime.bloodmagic.item.routing.ItemNodeRouter;
import WayofTime.bloodmagic.item.routing.ItemRouterFilter;
import WayofTime.bloodmagic.item.sigil.ItemSigilAir;
import WayofTime.bloodmagic.item.sigil.ItemSigilBloodLight;
import WayofTime.bloodmagic.item.sigil.ItemSigilBounce;
import WayofTime.bloodmagic.item.sigil.ItemSigilClaw;
import WayofTime.bloodmagic.item.sigil.ItemSigilCompression;
import WayofTime.bloodmagic.item.sigil.ItemSigilDivination;
import WayofTime.bloodmagic.item.sigil.ItemSigilElementalAffinity;
import WayofTime.bloodmagic.item.sigil.ItemSigilEnderSeverance;
import WayofTime.bloodmagic.item.sigil.ItemSigilFastMiner;
import WayofTime.bloodmagic.item.sigil.ItemSigilFrost;
import WayofTime.bloodmagic.item.sigil.ItemSigilGreenGrove;
import WayofTime.bloodmagic.item.sigil.ItemSigilHaste;
import WayofTime.bloodmagic.item.sigil.ItemSigilHolding;
@ -125,6 +128,9 @@ public class ModItems
public static final Item SIGIL_HOLDING;
public static final Item SIGIL_TELEPOSITION;
public static final Item SIGIL_TRANSPOSITION;
public static final Item SIGIL_CLAW;
public static final Item SIGIL_BOUNCE;
public static final Item SIGIL_FROST;
public static final Item ITEM_COMPONENT;
public static final Item ITEM_DEMON_CRYSTAL;
public static final Item TELEPOSITION_FOCUS;
@ -213,6 +219,10 @@ public class ModItems
SIGIL_TELEPOSITION = registerItem(new ItemSigilTeleposition(), Constants.BloodMagicItem.SIGIL_TELEPOSITION.getRegName());
SIGIL_TRANSPOSITION = registerItem(new ItemSigilTransposition(), Constants.BloodMagicItem.SIGIL_TRANSPOSITION.getRegName());
SIGIL_CLAW = registerItem(new ItemSigilClaw(), Constants.BloodMagicItem.SIGIL_CLAW.getRegName());
SIGIL_BOUNCE = registerItem(new ItemSigilBounce(), Constants.BloodMagicItem.SIGIL_BOUNCE.getRegName());
SIGIL_FROST = registerItem(new ItemSigilFrost(), Constants.BloodMagicItem.SIGIL_FROST.getRegName());
ITEM_COMPONENT = registerItem(new ItemComponent(), Constants.BloodMagicItem.COMPONENT.getRegName());
ITEM_DEMON_CRYSTAL = registerItem(new ItemDemonCrystal(), Constants.BloodMagicItem.DEMON_CRYSTAL.getRegName());
TELEPOSITION_FOCUS = registerItem(new ItemTelepositionFocus(), Constants.BloodMagicItem.TELEPOSITION_FOCUS.getRegName());

View file

@ -288,6 +288,9 @@ public class ModRecipes
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_SEVERANCE), new ItemStack(ModItems.SLATE, 1, 3), new ItemStack(ModItems.SIGIL_ENDER_SEVERANCE), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_TELEPOSITION), new ItemStack(ModItems.SLATE, 1, 3), new ItemStack(ModItems.SIGIL_TELEPOSITION), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_TRANSPOSITION), new ItemStack(ModItems.SLATE, 1, 3), new ItemStack(ModItems.SIGIL_TRANSPOSITION), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_CLAW), new ItemStack(ModItems.SLATE, 1, 2), new ItemStack(ModItems.SIGIL_CLAW), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_BOUNCE), new ItemStack(ModItems.SLATE, 1, 1), new ItemStack(ModItems.SIGIL_BOUNCE), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerCraftingRecipe(ItemComponent.getStack(ItemComponent.REAGENT_FROST), new ItemStack(ModItems.SLATE, 1, 1), new ItemStack(ModItems.SIGIL_FROST), new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/WIPArray.png"));
AlchemyArrayRecipeRegistry.registerRecipe(new ItemStack(Items.ROTTEN_FLESH), new ItemStack(Items.ROTTEN_FLESH), new AlchemyArrayEffectAttractor("attractor"), new AttractorAlchemyCircleRenderer());
AlchemyArrayRecipeRegistry.registerRecipe(new ItemStack(Items.FEATHER), new ItemStack(Items.REDSTONE), new AlchemyArrayEffectMovement("movement"), new StaticAlchemyCircleRenderer(new ResourceLocation("bloodmagic", "textures/models/AlchemyArrays/MovementArray.png")));
@ -342,6 +345,9 @@ public class ModRecipes
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_COMPRESSION), 2000, 200, "blockIron", "blockGold", Blocks.OBSIDIAN, "cobblestone");
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_TELEPOSITION), 1500, 200, ModBlocks.TELEPOSER, "glowstone", "blockRedstone", "ingotGold");
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_TRANSPOSITION), 1500, 200, ModBlocks.TELEPOSER, "gemDiamond", Items.ENDER_PEARL, Blocks.OBSIDIAN);
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_CLAW), 800, 120, Items.FLINT, Items.FLINT, ItemCuttingFluid.getStack(ItemCuttingFluid.BASIC));
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_BOUNCE), 200, 20, Blocks.SLIME_BLOCK, Blocks.SLIME_BLOCK, Items.LEATHER, Items.STRING);
TartaricForgeRecipeRegistry.registerRecipe(ItemComponent.getStack(ItemComponent.REAGENT_FROST), 80, 10, Blocks.ICE, Items.SNOWBALL, Items.SNOWBALL, "dustRedstone");
TartaricForgeRecipeRegistry.registerRecipe(new ItemStack(ModItems.SENTIENT_ARMOUR_GEM), 240, 150, Items.DIAMOND_CHESTPLATE, new ItemStack(ModItems.SOUL_GEM, 1, 1), Blocks.IRON_BLOCK, Blocks.OBSIDIAN);

View file

@ -98,8 +98,7 @@ public class GenericHandler
if (player.worldObj.isRemote)
{
player.motionY *= -0.9;
player.isAirBorne = true;
player.onGround = false;
player.fallDistance = 0;
bounceMap.put(player, player.motionY);
} else
{
@ -231,11 +230,17 @@ public class GenericHandler
if (entity instanceof EntityPlayer)
{
EntityPlayer player = (EntityPlayer) entity;
if (player.worldObj.isRemote && player.isSneaking() && player.isPotionActive(ModPotions.cling) && Utils.isPlayerBesideSolidBlockFace(player) && !player.onGround)
if (player.isSneaking() && player.isPotionActive(ModPotions.cling) && Utils.isPlayerBesideSolidBlockFace(player) && !player.onGround)
{
player.motionY = 0;
player.motionX *= 0.8;
player.motionZ *= 0.8;
if (player.worldObj.isRemote)
{
player.motionY = 0;
player.motionX *= 0.8;
player.motionZ *= 0.8;
} else
{
player.fallDistance = 0;
}
}
}