~kris/9p

disco

ref: 66de1621e9cc9311480b11d06272a9ebe7f2c9db disco/DiscordState/struct.go -rw-r--r-- 739 bytes
66de1621 — Sean Hinchee add aux/statusmsg notifications for 9 ;; fix -t timestamp bugs (both thanks to halfwit) 7 years ago
                                                                                
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
package DiscordState

import "github.com/bwmarrin/discordgo"

//State is the current state of the attached client
type State struct {
	Guild         *discordgo.Guild
	Channel       *discordgo.Channel
	Channels      []*discordgo.Channel
	UserChannels  []*discordgo.Channel
	Members       map[string]*discordgo.Member
	MemberRole    map[string]*discordgo.Role
	Messages      []*discordgo.Message
	Session       *Session
	MessageAmount int  //Amount of Messages to keep in State
	Enabled       bool //Toggles State for Event handling
}

//Session contains the 'state' of the attached server
type Session struct {
	Username  string
	User      *discordgo.User
	Password  string
	DiscordGo *discordgo.Session
	Guilds    []*discordgo.UserGuild
}