From 1f485c6e4108cef1ac68aa426af69f6832f7120b Mon Sep 17 00:00:00 2001 From: MukjepScarlet <93977077+MukjepScarlet@users.noreply.github.com> Date: Sun, 5 Jan 2025 23:41:58 +0800 Subject: [PATCH] chore(ProphuntESP): remove redundant transform Now the PlacementRenderer can directly use BlockPos.Mutable as parameters. --- .../features/module/modules/render/ModuleProphuntESP.kt | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/src/main/kotlin/net/ccbluex/liquidbounce/features/module/modules/render/ModuleProphuntESP.kt b/src/main/kotlin/net/ccbluex/liquidbounce/features/module/modules/render/ModuleProphuntESP.kt index c29f6c60792..b0f0134d9bd 100644 --- a/src/main/kotlin/net/ccbluex/liquidbounce/features/module/modules/render/ModuleProphuntESP.kt +++ b/src/main/kotlin/net/ccbluex/liquidbounce/features/module/modules/render/ModuleProphuntESP.kt @@ -46,8 +46,10 @@ object ModuleProphuntESP : ClientModule("ProphuntESP", Category.RENDER, @Suppress("unused") private val tickHandler = tickHandler { - world.entities.filterIsInstance().forEach { - renderer.addBlock(it.blockPos) + world.entities.forEach { + if (it is FallingBlockEntity) { + renderer.addBlock(it.blockPos) + } } } @@ -58,7 +60,7 @@ object ModuleProphuntESP : ClientModule("ProphuntESP", Category.RENDER, renderer.addBlock(packet.pos) } is ChunkDeltaUpdateS2CPacket -> mc.renderTaskQueue.add { - packet.visitUpdates { pos, _ -> renderer.addBlock(pos.toImmutable()) } + packet.visitUpdates { pos, _ -> renderer.addBlock(pos) } } } }