Skip to content

Commit

Permalink
Fix Effortless Ring crash, Closes #1011
Browse files Browse the repository at this point in the history
  • Loading branch information
rubensworks committed Oct 29, 2023
1 parent 8d31083 commit b7e6fb8
Show file tree
Hide file tree
Showing 3 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion gradle.properties
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
mod_version=1.2.32
minecraft_version=1.20.1
forge_version=47.0.1
forge_version=47.2.1
cyclopscore_version=1.18.4-340
evilcraftcompat_version=1.20.1-1.1.0-43
release_type=release
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,7 +57,7 @@ public EntityWerewolf(EntityType<? extends EntityWerewolf> type, Level world) {
public EntityWerewolf(Level world) {
super(RegistryEntries.ENTITY_WEREWOLF, world);

this.maxUpStep = 1.0F;
this.setMaxUpStep(1.0F);

// This sets the default villager profession ID.
this.villagerNBTTagCompound.putString("ProfessionName", ForgeRegistries.VILLAGER_PROFESSIONS.getKey(RegistryEntries.VILLAGER_PROFESSION_WEREWOLF).toString());
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@ public void onPlayerUpdate(LivingEvent.LivingTickEvent event) {
Player player = (Player) event.getEntity();
if(player.getPersistentData().contains(PLAYER_NBT_KEY)) {
if (!ItemStackHelpers.hasPlayerItem(player, this)) {
player.maxUpStep = player.getPersistentData().getFloat(PLAYER_NBT_KEY);
player.setMaxUpStep(player.getPersistentData().getFloat(PLAYER_NBT_KEY));
player.getPersistentData().remove(PLAYER_NBT_KEY);
}
}
Expand Down

0 comments on commit b7e6fb8

Please sign in to comment.