toggleCall()
toggleCall
Method in MelodyManager
Class
toggleCall
Method in MelodyManager
ClassThe toggleCall
method is used to toggle the call status of a player in the MelodyMine plugin. This method changes the callToggle
status of the player, which determines whether the player can receive calls or not.
Method Signature
Parameters
melodyPlayer
MelodyPlayer
The player whose call status is to be toggled.
Example
Here is an example of how to use the toggleCall
method in another plugin:
In this example, the togglePlayerCallStatus
method in the ExamplePlugin
class retrieves the MelodyPlayer
instance for the player using their UUID. It then uses the toggleCall
method of the MelodyManager
class to toggle the call status of the player. If the call status is successfully toggled, a message is logged to the console. If the player is not found, a warning is logged instead.
Last updated