Skip to content

Commit

Permalink
fix: try to fix StackOverflow caused by Biomancy's ScaleModifier impl…
Browse files Browse the repository at this point in the history
…ementation (Pehkui integration)

Closes: #133
  • Loading branch information
Elenterius committed Jun 19, 2024
1 parent 3968c0d commit b062f36
Showing 1 changed file with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -52,12 +52,7 @@ public float getScale(LivingEntity livingEntity) {

}

private static final ScaleModifier SCALE_MODIFIER = registerScaleModifier("scale", () -> new ScaleModifier() {
@Override
public float modifyScale(final ScaleData scaleData, float modifiedScale, final float delta) {
return SCALE_TYPE.getScaleData(scaleData.getEntity()).getScale(delta) * modifiedScale;
}
});
private static final ScaleModifier SCALE_MODIFIER = registerScaleModifier("scale", () -> new TypedScaleModifier(() -> PehkuiCompat.SCALE_TYPE));

private static final ScaleType SCALE_TYPE = registerScaleType("size", builder -> builder.affectsDimensions().addDependentModifier(SCALE_MODIFIER));

Expand Down

0 comments on commit b062f36

Please sign in to comment.