Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

can't disable the Mini Map Addon #2

Open
4 tasks done
TheWylot opened this issue Aug 16, 2024 · 0 comments
Open
4 tasks done

can't disable the Mini Map Addon #2

TheWylot opened this issue Aug 16, 2024 · 0 comments
Labels
bug Something isn't working pending This issue or pull request still needs to be looked at

Comments

@TheWylot
Copy link

TheWylot commented Aug 16, 2024

General Troubleshooting

  • I am using the latest version of the LabyMod 4 Server API.
  • I am using the latest version of LabyMod.
  • I have checked for similar issues on the Issue-tracker.
  • I have checked for Pull Requests that might already address this issue.

Platforms

Spigot / Bukkit, Other (please specify in the additional information text field at the bottom)

Affected Minecraft Version(s)

ALL of the Labymod Versions

Expected Behaviour

I can disable other addon with below code, but when im going to disable "labysminimap" it doesnt function at all.

Code Example for Reproduction Steps

@Override
    public void onEnable() {
        instance = this;
        LabyModProtocolService.initialize(this);
        getServer().getPluginManager().registerEvents(new Listener() {
            @EventHandler
            public void onLabyModPlayerJoin(LabyModPlayerJoinEvent event) {
                Player player = event.labyModPlayer().getPlayer();
                List<String> addonsToDisable = new ArrayList<>();

                addonsToDisable.add("keystrokes"); // it works, getting disabled.
                addonsToDisable.add("labysminimap"); // it doesnt function

                LabyModPlayer labyModPlayer = LabyModProtocolService.get().getPlayer(player.getUniqueId());

                labyModPlayer.disableAddons(addonsToDisable);
                requestAddons(player);
                player.sendMessage(ChatColor.RED + "LabyMod Integration has been enabled, due to the server rules Minimap addon has been disabled on this gamemode.");
            }
        }, this);
    }

Exception or Error

N/A

Additional Information

No response

@TheWylot TheWylot added bug Something isn't working pending This issue or pull request still needs to be looked at labels Aug 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working pending This issue or pull request still needs to be looked at
Projects
None yet
Development

No branches or pull requests

1 participant