This repository was archived by the owner on Aug 18, 2020. It is now read-only.
File tree 1 file changed +12
-1
lines changed
discordtest/src/main/scala
1 file changed +12
-1
lines changed Original file line number Diff line number Diff line change 1
- import org .codeoverflow .chatoverflow .api .io .dto .chat .discord .DiscordChatMessage
1
+ import java .awt .Color
2
+ import java .io .File
3
+
4
+ import org .codeoverflow .chatoverflow .api .io .dto .chat .discord .{DiscordChatMessage , DiscordEmbed , DiscordReaction }
2
5
import org .codeoverflow .chatoverflow .api .plugin .{PluginImpl , PluginManager }
6
+
3
7
import scala .collection .JavaConverters ._
4
8
5
9
class discordTestPlugin (manager : PluginManager ) extends PluginImpl (manager) {
@@ -17,6 +21,13 @@ class discordTestPlugin(manager: PluginManager) extends PluginImpl(manager) {
17
21
discordInputReq.get.registerMessageEditHandler(onMessageEdit)
18
22
discordInputReq.get.registerMessageDeleteHandler(onMessageDelete)
19
23
discordOutputReq.get.sendChatMessage(" Hey I'm working! \uD83C\uDF89 " )
24
+ discordOutputReq.get().sendFile(" ../config/config.xml" )
25
+ discordOutputReq.get().sendFile(" allowed_file.png" )
26
+ discordOutputReq.get().sendChatMessage(DiscordEmbed .Builder ()
27
+ .withColor(Color .RED )
28
+ .withDescription(" test" )
29
+ .withAuthor(" skateShiny" , null , " https://cdn.discordapp.com/emojis/496389587329875981.png?v=1" )
30
+ .build())
20
31
println(" Startet succesfully" )
21
32
}
22
33
You can’t perform that action at this time.
0 commit comments