Skip to content

Commit 5c5ab8d

Browse files
committed
Fix meteor boots registration
1 parent 14c8508 commit 5c5ab8d

File tree

4 files changed

+9
-7
lines changed

4 files changed

+9
-7
lines changed

src/main/java/mod/icarus/crimsonrevelations/events/CREvents.java

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,7 @@ public static void onAttackEvent(LivingAttackEvent event) {
9090
for (ItemStack stack : event.getEntityLiving().getArmorInventoryList()) {
9191

9292
// Prevents screen shaking and damage sound.
93-
if (stack.getItem() == CRItems.METEOR_BOOTS) {
93+
if (stack.getItem() == CRItems.meteorBoots) {
9494
if (event.getSource() == DamageSource.HOT_FLOOR) {
9595
event.setCanceled(true);
9696
}
@@ -103,7 +103,7 @@ public static void onDamageEvent(LivingDamageEvent event) {
103103
for (ItemStack stack : event.getEntityLiving().getArmorInventoryList()) {
104104

105105
// Immune to these damage types.
106-
if (stack.getItem() == CRItems.METEOR_BOOTS) {
106+
if (stack.getItem() == CRItems.meteorBoots) {
107107
if (event.getSource() == DamageSource.HOT_FLOOR) {
108108
event.setAmount(0.0F);
109109
event.setCanceled(true);

src/main/java/mod/icarus/crimsonrevelations/init/CRItems.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -66,7 +66,6 @@ public class CRItems {
6666
public static final CRItemCultistArcherArmor CRIMSON_ARCHER_LEGGINGS = null;
6767
public static final CRItemKnowledgeScribingTools KNOWLEDGE_SCRIBING_TOOLS = null;
6868
public static final CRItemManaBean MANA_BEAN = null;
69-
public static final CRItem METEOR_BOOTS = null;
7069
public static final CRItemPrimordialScribingTools PRIMORDIAL_SCRIBING_TOOLS = null;
7170
public static final CRItemRunicBauble PROTECTION_RING = null;
7271
public static final CRItemRunicBauble RUNIC_AMULET = null;
@@ -80,6 +79,9 @@ public class CRItems {
8079
public static final CRItemSword CRIMSON_SWORD = null;
8180
public static final CRItemVerdantRing VERDANT_RING = null;
8281

82+
@GameRegistry.ObjectHolder("meteor_boots")
83+
public static Item meteorBoots;
84+
8385
@SubscribeEvent
8486
public static void registerItems(@Nonnull final RegistryEvent.Register<Item> event) {
8587
final IForgeRegistry<Item> registry = event.getRegistry();

src/main/java/mod/icarus/crimsonrevelations/init/CRRecipes.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -450,7 +450,7 @@ public static void initInfusion() {
450450
// Thaumic Augmentation Integration
451451
if (Loader.isModLoaded("thaumicaugmentation")) {
452452
ThaumcraftApi.addInfusionCraftingRecipe(new ResourceLocation(NewCrimsonRevelations.MODID, "meteor_boots"),
453-
new InfusionRecipe("CR_METEOR_BOOTS", new ItemStack(CRItems.METEOR_BOOTS), 4,
453+
new InfusionRecipe("CR_METEOR_BOOTS", new ItemStack(CRItems.meteorBoots), 4,
454454
new AspectList().add(Aspect.MOTION, 100).add(Aspect.FIRE, 50).add(Aspect.FLIGHT, 100).add(Aspect.ENTROPY, 50),
455455
new ItemStack(ItemsTC.travellerBoots),
456456
BlocksTC.crystalFire,

src/main/java/mod/icarus/crimsonrevelations/item/armor/CRItemMeteorBoots.java

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -78,7 +78,7 @@ public Float apply(EntityPlayer player, MovementType type) {
7878
@Override
7979
public boolean test(EntityPlayer player) {
8080
for (ItemStack stack : player.getArmorInventoryList()) {
81-
if (stack.getItem() == CRItems.METEOR_BOOTS)
81+
if (stack.getItem() == CRItems.meteorBoots)
8282
return true;
8383
}
8484

@@ -158,7 +158,7 @@ public void onArmorTick(World world, EntityPlayer player, ItemStack stack) {
158158

159159
// Activate smash state once the sneak key is pressed. Do not activate while flying.
160160
if (player.isSneaking() && !player.capabilities.isFlying && !player.isElytraFlying() && player.fallDistance > 0.0F && hasCharge) {
161-
if (!getSmashingState(stack) && !(player.getCooldownTracker().hasCooldown(CRItems.METEOR_BOOTS))) {
161+
if (!getSmashingState(stack) && !(player.getCooldownTracker().hasCooldown(CRItems.meteorBoots))) {
162162
setSmashingState(stack, true);
163163
player.playSound(SoundsTC.rumble, 1.0F, 0.8F + (float) player.getEntityWorld().rand.nextGaussian() * 0.05F);
164164
RechargeHelper.consumeCharge(stack, player, 2);
@@ -204,7 +204,7 @@ public void onArmorTick(World world, EntityPlayer player, ItemStack stack) {
204204
}
205205

206206
player.playSound(SoundEvents.ENTITY_GENERIC_EXPLODE, 4.0F, (1.0F + (world.rand.nextFloat() - world.rand.nextFloat()) * 0.2F) * 0.7F);
207-
player.getCooldownTracker().setCooldown(CRItems.METEOR_BOOTS, 5 * 20);
207+
player.getCooldownTracker().setCooldown(CRItems.meteorBoots, 5 * 20);
208208
}
209209
}
210210

0 commit comments

Comments
 (0)