9
0
mirror of https://github.com/Samsuik/Sakura.git synced 2025-12-22 16:29:16 +00:00

Append more sakura comments with commit names

This commit is contained in:
Samsuik
2024-07-17 19:15:48 +01:00
parent cea456f3e9
commit 14fc838dbe
3 changed files with 12 additions and 12 deletions

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Optional Force Position Updates
diff --git a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
index d14128dd5d63e93a3d4aec76b0ee8d0e7d786687..2eb69c7d7843a7b58479049633b838212d003c10 100644
index d14128dd5d63e93a3d4aec76b0ee8d0e7d786687..6902a97bcf858aab63547451a656bc336eeb2b93 100644
--- a/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
+++ b/src/main/java/net/minecraft/world/entity/item/PrimedTnt.java
@@ -129,6 +129,14 @@ public class PrimedTnt extends Entity implements TraceableEntity {
@@ -13,8 +13,8 @@ index d14128dd5d63e93a3d4aec76b0ee8d0e7d786687..2eb69c7d7843a7b58479049633b83821
}
+ // Sakura start - configure force position updates
+ if (level().sakuraConfig().cannons.tnt.forcePositionUpdates) {
+ forcePositionUpdate();
+ if (this.level().sakuraConfig().cannons.tnt.forcePositionUpdates) {
+ this.forcePositionUpdate();
+ }
+ }
+

View File

@@ -5,7 +5,7 @@ Subject: [PATCH] Optimise New Liquid Level
diff --git a/src/main/java/net/minecraft/world/level/material/FlowingFluid.java b/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
index 1c0712295695727ee9c4d430d4157b8e17cbd71f..9dda53434f72a14567fc77275726d67183f13317 100644
index 1c0712295695727ee9c4d430d4157b8e17cbd71f..1c82ff348769655f20ba4fde7914a326e072afce 100644
--- a/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
+++ b/src/main/java/net/minecraft/world/level/material/FlowingFluid.java
@@ -137,7 +137,7 @@ public abstract class FlowingFluid extends Fluid {
@@ -13,7 +13,7 @@ index 1c0712295695727ee9c4d430d4157b8e17cbd71f..9dda53434f72a14567fc77275726d671
BlockPos blockposition1 = fluidPos.below();
BlockState iblockdata1 = world.getBlockState(blockposition1);
- FluidState fluid1 = this.getNewLiquid(world, blockposition1, iblockdata1);
+ FluidState fluid1 = this.getLiquid(world, blockposition1, iblockdata1, fluidPos, iblockdata); // Sakura - optimise liquid level
+ FluidState fluid1 = this.getLiquid(world, blockposition1, iblockdata1, fluidPos, iblockdata); // Sakura - optimise new liquid level
if (this.canSpreadTo(world, fluidPos, iblockdata, Direction.DOWN, blockposition1, iblockdata1, world.getFluidState(blockposition1), fluid1.getType())) {
// CraftBukkit start
@@ -21,7 +21,7 @@ index 1c0712295695727ee9c4d430d4157b8e17cbd71f..9dda53434f72a14567fc77275726d671
}
protected FluidState getNewLiquid(Level world, BlockPos pos, BlockState state) {
+ // Sakura start - optimise liquid level
+ // Sakura start - optimise new liquid level
+ BlockPos blockposition2 = pos.above();
+ BlockState iblockdata3 = world.getBlockState(blockposition2);
+
@@ -60,7 +60,7 @@ index 1c0712295695727ee9c4d430d4157b8e17cbd71f..9dda53434f72a14567fc77275726d671
- return k <= 0 ? Fluids.EMPTY.defaultFluidState() : this.getFlowing(k, false);
- }
+ return k <= 0 ? Fluids.EMPTY.defaultFluidState() : this.getFlowing(k, false);
+ // Sakura end
+ // Sakura end - optimise new liquid level
}
private boolean canPassThroughWall(Direction face, BlockGetter world, BlockPos pos, BlockState state, BlockPos fromPos, BlockState fromState) {

View File

@@ -5,18 +5,18 @@ Subject: [PATCH] Add utility methods to EntitySlices
diff --git a/src/main/java/ca/spottedleaf/moonrise/patches/chunk_system/level/entity/ChunkEntitySlices.java b/src/main/java/ca/spottedleaf/moonrise/patches/chunk_system/level/entity/ChunkEntitySlices.java
index 01e29fc7c91aa7ffeb54584c8ca0989900235251..c140e3a73712d2123bc9ed09e9bab25e48c4420e 100644
index 01e29fc7c91aa7ffeb54584c8ca0989900235251..8126c4fdbbc586cf3722c6ee2986338de044602e 100644
--- a/src/main/java/ca/spottedleaf/moonrise/patches/chunk_system/level/entity/ChunkEntitySlices.java
+++ b/src/main/java/ca/spottedleaf/moonrise/patches/chunk_system/level/entity/ChunkEntitySlices.java
@@ -318,6 +318,12 @@ public final class ChunkEntitySlices {
return true;
}
+ // Sakura start
+ // Sakura start - add utility methods to entity slices
+ public Entity[] getSectionEntities(int sectionY) {
+ return this.allEntities.getSectionEntities(sectionY);
+ }
+ // Sakura end
+ // Sakura end - add utility methods to entity slices
+
public void getHardCollidingEntities(final Entity except, final AABB box, final List<Entity> into, final Predicate<? super Entity> predicate) {
this.hardCollidingEntities.getEntities(except, box, into, predicate);
@@ -25,7 +25,7 @@ index 01e29fc7c91aa7ffeb54584c8ca0989900235251..c140e3a73712d2123bc9ed09e9bab25e
}
}
+ // Sakura start
+ // Sakura start - add utility methods to entity slices
+ public Entity[] getSectionEntities(int sectionY) {
+ BasicEntityList<Entity> list = this.entitiesBySection[sectionY - this.slices.minSection];
+
@@ -35,7 +35,7 @@ index 01e29fc7c91aa7ffeb54584c8ca0989900235251..c140e3a73712d2123bc9ed09e9bab25e
+
+ return new Entity[0];
+ }
+ // Sakura end
+ // Sakura end - add utility methods to entity slices
+
public void getEntities(final Entity except, final AABB box, final List<Entity> into, final Predicate<? super Entity> predicate) {
if (this.count == 0) {