disableAdminMode()

disableAdminMode Method in MelodyManager Class

The disableAdminMode method is a part of the MelodyManager class in the MelodyMine plugin. This method is used to disable the admin mode for a specific player in the MelodyMine plugin.

Method Signature

public void disableAdminMode(String uuid)

Parameters

ParameterTypeDescription

uuid

String

The unique identifier of the player for whom the admin mode is to be disabled.

Usage

To use this method in other plugins, you need to import the MelodyManager class and call the disableAdminMode method on its instance. Here is an example:

import ir.taher7.melodymine.core.MelodyManager;

public class ExamplePlugin {
    public void disableAdminForPlayer(String uuid) {
        MelodyManager.INSTANCE.disableAdminMode(uuid);
        Bukkit.getLogger().info("Admin mode disabled for player with UUID: " + uuid);
    }
}

In this example, the disableAdminForPlayer method in the ExamplePlugin class disables the admin mode for a player with a specific UUID and logs this action to the console.

Make sure that the UUID passed to the disableAdminMode method is valid and corresponds to a player who is currently in admin mode. Otherwise, the method may not have the desired effect.

Last updated