Interface IChatExtension
- All Known Implementing Classes:
OpChatChatExtension
,WaypointChatExtension
public interface IChatExtension
-
Method Summary
Modifier and TypeMethodDescriptiondefault String
Gets the description of the Chat ExtensiongetName()
Gets the name of the Chat ExtensiononDCMessage
(net.dv8tion.jda.api.entities.Message message) Runs when a message is sent in the Discord servervoid
Runs when the Chat Extension is disabledvoid
onEnable()
Runs when the Chat Extension is enabledonMCMessage
(String message, String player) Runs when a message is sent in MC chat
-
Method Details
-
getName
String getName()Gets the name of the Chat Extension- Returns:
- The chat extension's name
-
getDescription
Gets the description of the Chat Extension- Returns:
- The chat extension's description
-
onEnable
void onEnable()Runs when the Chat Extension is enabled -
onDisable
void onDisable()Runs when the Chat Extension is disabled -
onMCMessage
Runs when a message is sent in MC chat- Parameters:
message
- The messageplayer
- The player
-
onDCMessage
Runs when a message is sent in the Discord serverIt's global so that things like OpChat can work properly (sends and receives messages from different channel)
- Parameters:
message
- The JDA message- Returns:
- The result
-