9
0
mirror of https://github.com/Winds-Studio/Leaf.git synced 2025-12-29 03:49:21 +00:00

add back zero check fix always tick on first tick

This commit is contained in:
hayanesuru
2025-06-10 00:06:52 +09:00
parent ec62833de4
commit 4e01d009c7

View File

@@ -69,10 +69,10 @@ public final class RandomTickSystem {
tickSpeed = tickSpeed * 4;
long chance = chunk.leaf$randomTickChance();
if (chance != 0L && chance <= (long) (a & MASK)) {
if (chance == 0L && (chance = recompute(chunk, tickSpeed)) == 0L) {
return;
}
if ((chance = recompute(chunk, tickSpeed)) == 0L) {
if (chance <= (long) (a & MASK) || (chance = recompute(chunk, tickSpeed)) == 0L) {
return;
}
int tickingCount = chunk.leaf$countTickingBlocks();