diff --git a/gradle.properties b/gradle.properties index e5e4d83..a5b9fdb 100644 --- a/gradle.properties +++ b/gradle.properties @@ -7,7 +7,7 @@ minecraft_version=1.19.3 yarn_mappings=1.19.3+build.3 loader_version=0.14.11 # Mod Properties -mod_version=0.4.1 +mod_version=0.4.2 maven_group=com.glisco archives_base_name=isometric-renders # Dependencies diff --git a/src/main/java/com/glisco/isometricrenders/property/IntProperty.java b/src/main/java/com/glisco/isometricrenders/property/IntProperty.java index 983aaf0..476e50a 100644 --- a/src/main/java/com/glisco/isometricrenders/property/IntProperty.java +++ b/src/main/java/com/glisco/isometricrenders/property/IntProperty.java @@ -49,7 +49,7 @@ public double progress() { } public void setFromProgress(double progress) { - this.value = (int) (this.min + progress * this.span); + this.value = (int) Math.round(this.min + progress * this.span); this.invokeListeners(); } diff --git a/src/main/java/com/glisco/isometricrenders/render/RenderableDispatcher.java b/src/main/java/com/glisco/isometricrenders/render/RenderableDispatcher.java index e65435a..9f37ae1 100644 --- a/src/main/java/com/glisco/isometricrenders/render/RenderableDispatcher.java +++ b/src/main/java/com/glisco/isometricrenders/render/RenderableDispatcher.java @@ -44,15 +44,17 @@ public static void drawIntoActiveFramebuffer(Renderable renderable, float asp IsometricRenders.beginRenderableDraw(); - // Emit untransformed vertices - renderable.emitVertices( - new MatrixStack(), - MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers(), - tickDelta - ); - - // --> Draw - renderable.draw(modelViewStack.peek().getPositionMatrix()); + RenderSystem.runAsFancy(() -> { + // Emit untransformed vertices + renderable.emitVertices( + new MatrixStack(), + MinecraftClient.getInstance().getBufferBuilders().getEntityVertexConsumers(), + tickDelta + ); + + // --> Draw + renderable.draw(modelViewStack.peek().getPositionMatrix()); + }); IsometricRenders.endRenderableDraw(); diff --git a/src/main/java/com/glisco/isometricrenders/widget/PropertySliderComponent.java b/src/main/java/com/glisco/isometricrenders/widget/PropertySliderComponent.java index 47b7194..362c707 100644 --- a/src/main/java/com/glisco/isometricrenders/widget/PropertySliderComponent.java +++ b/src/main/java/com/glisco/isometricrenders/widget/PropertySliderComponent.java @@ -18,7 +18,7 @@ public PropertySliderComponent(Sizing horizontalSizing, Text text, int scrollInc this.message(s -> text); - this.onChanged(this.setting::setFromProgress); + this.onChanged().subscribe(this.setting::setFromProgress); setting.listen((intSetting, integer) -> ((SliderWidgetInvoker) this).isometric$setValue(setting.progress())); }