Skip to content

Commit

Permalink
Fix #4739
Browse files Browse the repository at this point in the history
  • Loading branch information
IThundxr committed Mar 24, 2024
1 parent 1ab972a commit 664b3bb
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 4 deletions.
3 changes: 2 additions & 1 deletion changelog.txt
Original file line number Diff line number Diff line change
@@ -1 +1,2 @@
- Fix crash with optifine
- Fix crash with optifine
- Fix crash with Dye Depot
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ public boolean canPickUpLoot() {
}

@Override
protected void populateDefaultEquipmentSlots(RandomSource rand, @NotNull DifficultyInstance difficulty) {
protected void populateDefaultEquipmentSlots(@NotNull RandomSource rand, @NotNull DifficultyInstance difficulty) {
super.populateDefaultEquipmentSlots(rand, difficulty);

prepareEquipment();
Expand All @@ -169,8 +169,10 @@ public void prepareEquipment() {
DyeColor color = DyeColor.values()[random.nextInt(DyeColor.values().length)];
RuneColor rune = RuneColor.byDyeColor(color);

ColorRunesModule.withRune(bow, rune);
ColorRunesModule.withRune(sheathed, rune);
if (rune != null) {
ColorRunesModule.withRune(bow, rune);
ColorRunesModule.withRune(sheathed, rune);
}
}

setItemSlot(EquipmentSlot.MAINHAND, bow);
Expand Down

0 comments on commit 664b3bb

Please sign in to comment.