Discord Components & Role Selection (#5)

This commit is contained in:
2023-04-01 01:23:37 -04:00
committed by GitHub
parent 5e6a433b92
commit e1038a15cd
25 changed files with 696 additions and 31 deletions

View File

@@ -31,7 +31,7 @@ type Bot struct {
onEventUpdatedHandlers [](func(common.Event) error)
onEventCompletedHandlers [](func(common.Event) error)
gameModules []common.GameModule
gameModules []common.ChatSyncModule
}
// Initalize creates the discord session and registers handlers
@@ -62,6 +62,11 @@ func (app *Bot) Initialize(cfg *core.Config) error {
app.Session.OnEventDelete(app.onEventDelete)
app.Session.OnEventUpdate(app.onEventUpdate)
btn := app.Session.NewButton("test", "Click Me")
btn.OnClick(func(user common.User) {
print("clicked")
})
return nil
}