Skip to content

Feature - Height Limit Module#300

Open
ItsNature wants to merge 2 commits into
version/1.2.9from
feature/height-limit
Open

Feature - Height Limit Module#300
ItsNature wants to merge 2 commits into
version/1.2.9from
feature/height-limit

Conversation

@ItsNature

@ItsNature ItsNature commented Jul 8, 2026

Copy link
Copy Markdown
Collaborator

Overview

Description:
Add Height Limit Module, letting servers set a per-world build height limit shown by the client's Height Limit Mod (block overlay + HUD). Servers send a Y level and an optional display name per world.

This module is disabled by default and only provides a visual indicator, the server is still responsible for cancelling block placement above the height limit.

Full Docs: https://48cef51e.lunarclient-dev.pages.dev/apollo/developers/modules/heightlimit

Changes:

  • Add HeightLimitModule API
    • overrideHeightLimit(Recipients, HeightLimit)
    • removeHeightLimit(Recipients, String world)
    • removeHeightLimit(Recipients, HeightLimit)
    • resetHeightLimits(Recipients)
  • Add HeightLimit builder: world, limit and optional displayName
  • Add DEFAULT_HEIGHT_LIMITS config option

Code Example:

  public void overrideHeightLimitExample(Player viewer) {
      Optional<ApolloPlayer> apolloPlayerOpt = Apollo.getPlayerManager().getPlayer(viewer.getUniqueId());

      apolloPlayerOpt.ifPresent(apolloPlayer -> {
          this.heightLimitModule.overrideHeightLimit(apolloPlayer, HeightLimit.builder()
              .world("world_the_end")
              .limit(150)
              .displayName(Component.text("The End", NamedTextColor.DARK_PURPLE))
              .build()
          );
      });
  }

Review Request Checklist

  • Your code follows the style guidelines of this project.
  • I have performed a self-review of my code.
  • I have tested this change myself. (If applicable)
  • I have made corresponding changes to the documentation. (If applicable)
  • The branch name follows the projects naming conventions. (e.g. feature/add-module & bugfix/fix-issue)

@ItsNature ItsNature added type: Documentation Documentation improvement or issue type: Enhancement Feature improvement or addition labels Jul 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

type: Documentation Documentation improvement or issue type: Enhancement Feature improvement or addition

Development

Successfully merging this pull request may close these issues.

3 participants