Rewrite config file system and remove useless patches
This commit is contained in:
45
patches/server/0017-Piston-fixes-from-molean-server.patch
Normal file
45
patches/server/0017-Piston-fixes-from-molean-server.patch
Normal file
@@ -0,0 +1,45 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: MrHua269 <novau233@163.com>
|
||||
Date: Wed, 7 Feb 2024 07:18:27 +0000
|
||||
Subject: [PATCH] Piston fixes from molean server
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/world/entity/Entity.java b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
index 55c42fa5fb60858af08c98940a2e786038f2ca4e..539ddfb88a5409b2270b36cf81120d81cffb197d 100644
|
||||
--- a/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
+++ b/src/main/java/net/minecraft/world/entity/Entity.java
|
||||
@@ -1448,7 +1448,7 @@ public abstract class Entity implements Nameable, EntityAccess, CommandSource, S
|
||||
if (movement.lengthSqr() <= 1.0E-7D) {
|
||||
return movement;
|
||||
} else {
|
||||
- long i = this.level().getGameTime();
|
||||
+ long i = this.level().getRedstoneGameTime(); //Luminol - Piston fixes from molean server
|
||||
|
||||
if (i != this.pistonDeltasGameTime) {
|
||||
Arrays.fill(this.pistonDeltas, 0.0D);
|
||||
diff --git a/src/main/java/net/minecraft/world/level/block/piston/PistonBaseBlock.java b/src/main/java/net/minecraft/world/level/block/piston/PistonBaseBlock.java
|
||||
index be74adc86f0ca467f3b59e7b57fd47a8f381d86e..3482ed0449478b258d85751ffc90ce677acbc60f 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/piston/PistonBaseBlock.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/block/piston/PistonBaseBlock.java
|
||||
@@ -152,7 +152,7 @@ public class PistonBaseBlock extends DirectionalBlock {
|
||||
if (tileentity instanceof PistonMovingBlockEntity) {
|
||||
PistonMovingBlockEntity tileentitypiston = (PistonMovingBlockEntity) tileentity;
|
||||
|
||||
- if (tileentitypiston.isExtending() && (tileentitypiston.getProgress(0.0F) < 0.5F || world.getGameTime() == tileentitypiston.getLastTicked() || ((ServerLevel) world).isHandlingTick())) {
|
||||
+ if (tileentitypiston.isExtending() && (tileentitypiston.getProgress(0.0F) < 0.5F || world.getRedstoneGameTime() == tileentitypiston.getLastTicked() || ((ServerLevel) world).isHandlingTick())) { //Luminol - Piston fixes from molean server
|
||||
b0 = 2;
|
||||
}
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/world/level/block/piston/PistonMovingBlockEntity.java b/src/main/java/net/minecraft/world/level/block/piston/PistonMovingBlockEntity.java
|
||||
index 1c23597f172f46eec714b510acfedb415bb01bff..3262398db1b053115b83ed6aab15f9fef511d5d3 100644
|
||||
--- a/src/main/java/net/minecraft/world/level/block/piston/PistonMovingBlockEntity.java
|
||||
+++ b/src/main/java/net/minecraft/world/level/block/piston/PistonMovingBlockEntity.java
|
||||
@@ -277,7 +277,7 @@ public class PistonMovingBlockEntity extends BlockEntity {
|
||||
}
|
||||
|
||||
public static void tick(Level world, BlockPos pos, BlockState state, PistonMovingBlockEntity blockEntity) {
|
||||
- blockEntity.lastTicked = world.getGameTime();
|
||||
+ blockEntity.lastTicked = world.getRedstoneGameTime(); //Luminol - Piston fixes from molean server
|
||||
blockEntity.progressO = blockEntity.progress;
|
||||
if (blockEntity.progressO >= 1.0F) {
|
||||
if (world.isClientSide && blockEntity.deathTicks < 5) {
|
||||
Reference in New Issue
Block a user