Skip to content

Refactor: Optimize BlockPos retrieval accuracy in BlockRawIdCommand#89

Merged
Nekiplay merged 1 commit into
MeteorClientPlus:1.21.11from
Astatine-LAB:1.21.11
Apr 20, 2026
Merged

Refactor: Optimize BlockPos retrieval accuracy in BlockRawIdCommand#89
Nekiplay merged 1 commit into
MeteorClientPlus:1.21.11from
Astatine-LAB:1.21.11

Conversation

@JAXPLE
Copy link
Copy Markdown
Contributor

@JAXPLE JAXPLE commented Apr 20, 2026

  • Issue: Manually casting double coordinates to int caused truncation errors depending on the block face being looked at, leading to inaccurate targeting of adjacent blocks.

  • Fix: Removed manual coordinate calculations, directly cast the target to BlockHitResult, and utilized the native getBlockPos() method.

  • Result: Eliminated unnecessary computation overhead and guaranteed 100% accurate block identification without offset bugs.

@Nekiplay Nekiplay merged commit 7547617 into MeteorClientPlus:1.21.11 Apr 20, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants