More var name fixes

This commit is contained in:
Nassim Jahnke
2024-12-27 13:45:04 +01:00
parent c530c39f4e
commit 2b73d1957c
29 changed files with 156 additions and 218 deletions

View File

@@ -58,7 +58,7 @@
}
}
+ protected void beforeDestroyingBlock(LevelAccessor world, BlockPos pos, BlockState state, BlockPos source) { beforeDestroyingBlock(world, pos, state); } // Paper - Add BlockBreakBlockEvent
+ protected void beforeDestroyingBlock(LevelAccessor level, BlockPos pos, BlockState state, BlockPos source) { beforeDestroyingBlock(level, pos, state); } // Paper - Add BlockBreakBlockEvent
protected abstract void beforeDestroyingBlock(LevelAccessor level, BlockPos pos, BlockState state);
protected int getSlopeDistance(LevelReader level, BlockPos pos, int depth, Direction direction, BlockState state, FlowingFluid.SpreadContext spreadContext) {

View File

@@ -7,9 +7,9 @@
-
+ // Paper start - Add BlockBreakBlockEvent
+ @Override
+ protected void beforeDestroyingBlock(LevelAccessor world, BlockPos pos, BlockState state, BlockPos source) {
+ BlockEntity tileentity = state.hasBlockEntity() ? world.getBlockEntity(pos) : null;
+ Block.dropResources(state, world, pos, tileentity, source);
+ protected void beforeDestroyingBlock(LevelAccessor level, BlockPos pos, BlockState state, BlockPos source) {
+ BlockEntity tileentity = state.hasBlockEntity() ? level.getBlockEntity(pos) : null;
+ Block.dropResources(state, level, pos, tileentity, source);
+ }
+ // Paper end - Add BlockBreakBlockEvent
@Override