Documentation
¶
Index ¶
- Constants
- Variables
- type CatFacts
- type Command
- type Forum
- type ForumTopic
- type Instance
- func (i *Instance) AddScore(amount int, score_type, user string)
- func (i *Instance) ChannelMsg(channel, msg string)
- func (i *Instance) GetScore(score_type, user string) int
- func (i *Instance) HandleMsg(msg *slack.MessageEvent)
- func (i *Instance) Mute(channel string, dur time.Duration)
- func (i *Instance) Run()
- func (i *Instance) StartVote(channel string)
- func (i *Instance) StopVote(channel string) int
- func (i *Instance) UserMsg(user, msg string) error
- func (i *Instance) Vote(val int, channel string)
- type Message
- type Quote
Constants ¶
View Source
const ANNOUNCE_TIMEOUT = 30 // minutes
View Source
const APOLLO_QUOTES_FILE = "./apollo_quotes.txt"
View Source
const GOON_QUOTES_FILE = "./goon_quotes.txt"
View Source
const TALK_CHANNEL = "C0JPGPM9T" // The dumpster
View Source
const VERSION = "0.4"
View Source
const WIKI_URL = "http://wiki.apollo-community.org/index.php?title="
Variables ¶
View Source
var COMMANDS []*Command
View Source
var FORUMS = []*Forum{ &Forum{"Staff Applications", "https://apollo-community.org/viewforum.php?f=15", "G0JPDL06A"}, &Forum{"Head Applications", "https://apollo-community.org/viewforum.php?f=16", "G0JPDL06A"}, &Forum{"Race Applications", "https://apollo-community.org/viewforum.php?f=17", "G0JPDL06A"}, &Forum{"Ban Requests", "https://apollo-community.org/viewforum.php?f=33", "G0JPDL06A"}, &Forum{"Unban Requests", "https://apollo-community.org/viewforum.php?f=34", "G0JPDL06A"}, }
View Source
var LAST_CATFACT_TIME time.Time
Functions ¶
This section is empty.
Types ¶
type ForumTopic ¶
type Instance ¶
type Instance struct {
Users map[string]slack.User // TODO: not thread safe
Channels map[string]slack.Channel
Groups map[string]slack.Group
Latency time.Duration
Debug bool
BotId string
// contains filtered or unexported fields
}
func (*Instance) ChannelMsg ¶
func (*Instance) HandleMsg ¶
func (i *Instance) HandleMsg(msg *slack.MessageEvent)
Click to show internal directories.
Click to hide internal directories.