Skip to content

Feature: Installed Mods API#269

Merged
ItsNature merged 2 commits intoversion/1.2.5from
feature/installed-mods-api
Apr 13, 2026
Merged

Feature: Installed Mods API#269
ItsNature merged 2 commits intoversion/1.2.5from
feature/installed-mods-api

Conversation

@ItsNature
Copy link
Copy Markdown
Collaborator

@ItsNature ItsNature commented Apr 10, 2026

Overview

Description:
Add Installed Mods API to the Mod Settings Module

Changes:

  • Deprecate PlayerHandshakeEvent#installedMods.
  • Update apollo-protos to 0.1.0.
  • Add ModSettingModule#requestInstalledMods

Code Example:

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

    if (!apolloPlayerOpt.isPresent()) {
        viewer.sendMessage("Join with Lunar Client to test this feature!");
        return;
    }

    this.modSettingModule.requestInstalledMods(apolloPlayerOpt.get())
        .onSuccess(response -> {
            List<String> modIds = response.getElements()
                .stream().map(LunarClientMod::getId)
                .collect(Collectors.toList());

            viewer.sendMessage("Found " + modIds.size() + " mods: " + modIds);
        })
        .onFailure(exception -> {
            viewer.sendMessage("Internal error! Check console!");
            exception.printStackTrace();
        });
}

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 mentioned this pull request Apr 10, 2026
@ItsNature ItsNature merged commit 08c03f1 into version/1.2.5 Apr 13, 2026
2 checks passed
@ItsNature ItsNature deleted the feature/installed-mods-api branch April 13, 2026 00:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

3 participants