Skip to content

Commit

Permalink
Meteor boots tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
IcarussOne committed Sep 26, 2024
1 parent 8434566 commit 5a08615
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 13 deletions.
27 changes: 16 additions & 11 deletions src/main/java/mod/icarus/crimsonrevelations/init/CRRecipes.java
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagByte;
import net.minecraft.util.ResourceLocation;
import net.minecraftforge.fml.common.Loader;
import net.minecraftforge.oredict.OreDictionary;
import thaumcraft.api.ThaumcraftApi;
import thaumcraft.api.ThaumcraftApiHelper;
Expand Down Expand Up @@ -252,17 +253,6 @@ public static void initInfusion() {
"plateVoid",
CRItems.crimsonFabric,
CRItems.crimsonFabric));
ThaumcraftApi.addInfusionCraftingRecipe(new ResourceLocation(NewCrimsonRevelations.MODID, "meteor_boots"),
new InfusionRecipe("CR_METEOR_BOOTS", new ItemStack(CRItems.meteorBoots), 4,
new AspectList().add(Aspect.MOTION, 100).add(Aspect.FIRE, 50).add(Aspect.FLIGHT, 100).add(Aspect.ENTROPY, 50),
new ItemStack(ItemsTC.travellerBoots),
BlocksTC.crystalFire,
Blocks.OBSIDIAN,
Blocks.OBSIDIAN,
Blocks.OBSIDIAN,
Items.MAGMA_CREAM,
Items.FIRE_CHARGE,
BlocksTC.crystalEntropy));
ThaumcraftApi.addInfusionCraftingRecipe(new ResourceLocation(NewCrimsonRevelations.MODID, "praetor_helm"),
new InfusionRecipe("CR_PRAETOR_ARMOR", new ItemStack(ItemsTC.crimsonPraetorHelm), 2,
new AspectList().add(Aspect.METAL, 40).add(Aspect.ELDRITCH, 25).add(Aspect.PROTECT, 20),
Expand Down Expand Up @@ -385,5 +375,20 @@ public static void initInfusion() {
Items.GHAST_TEAR,
ThaumcraftApiHelper.makeCrystal(Aspect.WATER, 1),
ThaumcraftApiHelper.makeCrystal(Aspect.WATER, 1)));

// Thaumic Augmentation Integration
if (Loader.isModLoaded("thaumicaugmentation")) {
ThaumcraftApi.addInfusionCraftingRecipe(new ResourceLocation(NewCrimsonRevelations.MODID, "meteor_boots"),
new InfusionRecipe("CR_METEOR_BOOTS", new ItemStack(CRItems.meteorBoots), 4,
new AspectList().add(Aspect.MOTION, 100).add(Aspect.FIRE, 50).add(Aspect.FLIGHT, 100).add(Aspect.ENTROPY, 50),
new ItemStack(ItemsTC.travellerBoots),
BlocksTC.crystalFire,
Blocks.OBSIDIAN,
Blocks.OBSIDIAN,
Blocks.OBSIDIAN,
Items.MAGMA_CREAM,
Items.FIRE_CHARGE,
BlocksTC.crystalEntropy));
}
}
}
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,7 @@
import net.minecraft.item.ItemStack;
import net.minecraft.nbt.NBTTagCompound;
import net.minecraft.util.DamageSource;
import net.minecraft.util.EntitySelectors;
import net.minecraft.util.EnumParticleTypes;
import net.minecraft.util.NonNullList;
import net.minecraft.util.ResourceLocation;
Expand Down Expand Up @@ -185,10 +186,10 @@ public void onArmorTick(World world, EntityPlayer player, ItemStack stack) {
// Explode on ground impact and reset smash state.
if (player.fallDistance <= 0.0F && player.onGround) {
int radius = 4;
AxisAlignedBB area = new AxisAlignedBB(player.posX - radius, player.posY - radius, player.posZ - radius, player.posX + radius, player.posY + radius, player.posZ + radius);
setSmashingState(stack, false);

for (EntityLivingBase nearbyLivingEntity : world.getEntitiesWithinAABB(EntityLivingBase.class, new AxisAlignedBB(player.posX - radius, player.posY - radius, player.posZ - radius,
player.posX + radius, player.posY + radius, player.posZ + radius))) {
for (EntityLivingBase nearbyLivingEntity : world.getEntitiesWithinAABB(EntityLivingBase.class, area, EntitySelectors.IS_ALIVE)) {
if (nearbyLivingEntity != player && !nearbyLivingEntity.isOnSameTeam(player)) {
nearbyLivingEntity.setFire(5 + (world.rand.nextInt(5)));
nearbyLivingEntity.knockBack(player, 1.0F, player.posX - nearbyLivingEntity.posX, player.posZ - nearbyLivingEntity.posZ);
Expand Down

0 comments on commit 5a08615

Please sign in to comment.