-
Notifications
You must be signed in to change notification settings - Fork 982
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Increase elevator pulley view distance to 512 #7854
Closed
Closed
+1
−1
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
The |
This change ensures that elevator pulley cables are still visible even if the elevator contraption drops below 128 blocks from the elevator pulley block.
Done |
Related: #4836 |
Thanks, I've implemented a alternative fix for this that changes based on the user's config |
Cool! Where can I find those changes? I'm curious how you implemented that. |
Subject: [PATCH] Patched up
- Bump rope pulley view distance
---
Index: src/main/java/com/simibubi/create/content/contraptions/pulley/AbstractPulleyRenderer.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/main/java/com/simibubi/create/content/contraptions/pulley/AbstractPulleyRenderer.java b/src/main/java/com/simibubi/create/content/contraptions/pulley/AbstractPulleyRenderer.java
--- a/src/main/java/com/simibubi/create/content/contraptions/pulley/AbstractPulleyRenderer.java (revision b180f9acd068a225de7f6e8c9bb17420e8257a7e)
+++ b/src/main/java/com/simibubi/create/content/contraptions/pulley/AbstractPulleyRenderer.java (date 1741658225800)
@@ -5,6 +5,8 @@
import com.simibubi.create.content.kinetics.base.KineticBlockEntity;
import com.simibubi.create.content.kinetics.base.KineticBlockEntityRenderer;
+import com.simibubi.create.infrastructure.config.AllConfigs;
+
import dev.engine_room.flywheel.api.visualization.VisualizationManager;
import dev.engine_room.flywheel.lib.model.baked.PartialModel;
import net.createmod.catnip.render.CachedBuffers;
@@ -90,7 +92,7 @@
protected abstract Axis getShaftAxis(T be);
protected abstract PartialModel getCoil();
-
+
protected abstract SpriteShiftEntry getCoilShift();
protected abstract SuperByteBuffer renderRope(T be);
@@ -126,7 +128,7 @@
@Override
public int getViewDistance() {
- return 256;
+ return AllConfigs.server().kinetics.maxRopeLength.get();
}
}
Index: src/main/java/com/simibubi/create/content/contraptions/pulley/PulleyRenderer.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/main/java/com/simibubi/create/content/contraptions/pulley/PulleyRenderer.java b/src/main/java/com/simibubi/create/content/contraptions/pulley/PulleyRenderer.java
--- a/src/main/java/com/simibubi/create/content/contraptions/pulley/PulleyRenderer.java (revision b180f9acd068a225de7f6e8c9bb17420e8257a7e)
+++ b/src/main/java/com/simibubi/create/content/contraptions/pulley/PulleyRenderer.java (date 1741658225793)
@@ -58,7 +58,7 @@
protected SpriteShiftEntry getCoilShift() {
return AllSpriteShifts.ROPE_PULLEY_COIL;
}
-
+
public static float getBlockEntityOffset(float partialTicks, PulleyBlockEntity blockEntity) {
float offset = blockEntity.getInterpolatedOffset(partialTicks);
@@ -72,9 +72,4 @@
return offset;
}
- @Override
- public int getViewDistance() {
- return 128;
- }
-
}
Index: src/main/java/com/simibubi/create/content/contraptions/elevator/ElevatorPulleyRenderer.java
IDEA additional info:
Subsystem: com.intellij.openapi.diff.impl.patch.CharsetEP
<+>UTF-8
===================================================================
diff --git a/src/main/java/com/simibubi/create/content/contraptions/elevator/ElevatorPulleyRenderer.java b/src/main/java/com/simibubi/create/content/contraptions/elevator/ElevatorPulleyRenderer.java
--- a/src/main/java/com/simibubi/create/content/contraptions/elevator/ElevatorPulleyRenderer.java (revision b180f9acd068a225de7f6e8c9bb17420e8257a7e)
+++ b/src/main/java/com/simibubi/create/content/contraptions/elevator/ElevatorPulleyRenderer.java (date 1741658225776)
@@ -103,11 +103,6 @@
blockState.getValue(ElevatorPulleyBlock.HORIZONTAL_FACING));
}
- @Override
- public int getViewDistance() {
- return 128;
- }
-
@Override
public boolean shouldRenderOffScreen(ElevatorPulleyBlockEntity p_188185_1_) {
return true; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
area: rendering
Issue or PR is related to rendering
pr flag: simple
PR has minimal changes
pr type: fix
PR fixes a bug
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This change ensures that elevator pulley cables are still visible even if the elevator contraption drops below 128 blocks from the elevator pulley block.
Please tell me if this won't have the effect I'm expecting it to have.
Feedback is greatly appreciated!