9
0
mirror of https://github.com/Xiao-MoMi/craft-engine.git synced 2025-12-31 04:46:37 +00:00

Update CraftEngineBlocks.java

This commit is contained in:
XiaoMoMi
2025-04-26 20:36:40 +08:00
parent f99a98a2eb
commit bf4724d10f

View File

@@ -112,8 +112,6 @@ public final class CraftEngineBlocks {
Object worldServer = FastNMS.INSTANCE.field$CraftWorld$ServerLevel(location.getWorld());
Object blockPos = FastNMS.INSTANCE.constructor$BlockPos(location.getBlockX(), location.getBlockY(), location.getBlockZ());
Object blockState = block.customBlockState().handle();
System.out.println(blockPos);
System.out.println(blockState);
Object oldBlockState = FastNMS.INSTANCE.method$BlockGetter$getBlockState(worldServer, blockPos);
success = FastNMS.INSTANCE.method$LevelWriter$setBlock(worldServer, blockPos, blockState, option.flags());
if (success) {
@@ -122,7 +120,6 @@ public final class CraftEngineBlocks {
location.getWorld().playSound(location, block.sounds().placeSound().toString(), SoundCategory.BLOCKS, block.sounds().placeSound().volume(), block.sounds().placeSound().pitch());
}
}
System.out.println(success);
return success;
}