SuperNeon4ik / NoxesiumUtils

Communicate with The Noxesium Mod with ease.
https://modrinth.com/plugin/noxesiumutils
GNU General Public License v3.0
13 stars 3 forks source link

Unable to use a method "forNoxesiumPlayers" from NoxesiumUtils class #2

Closed MrKacafirekCZ closed 1 year ago

MrKacafirekCZ commented 1 year ago

Hello, as a developer I have found that I'm not able to use methods forNoxesiumPlayers from the NoxesiumUtils class as described in the README file.

Here is an example of how I wanted to use your method:

public void fooBar(Player player) {
    if(!player.isOp()) {
        player.sendMessage(Component.text("Not enough permissions!", NamedTextColor.RED));
        return;
    }

    NoxesiumUtils.forNoxesiumPlayers(1, (p, protocolVersion) -> {
        p.sendMessage("Your Noxesium Protocol Version is " + protocolVersion);
    });
}

However I'm unable to do so as methods forNoxesiumPlayers from the NoxesiumUtils class are missing a static modifier: image

I have created this issue together with a PR #3 where this bug has been fixed.