Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
View Source
var (
ErrEmptyMessage = errors.New("Empty message")
)
View Source
var SoundsList, SoundsMap = func() ([]SoundInfo, map[string]SoundInfo) {
m := map[string]SoundInfo{}
fis, _ := fs.ReadDir(files.Sounds, "sounds")
for _, fi := range fis {
fn := fi.Name()
nm := fn[:len(fn)-len(path.Ext(fn))]
m[nm] = SoundInfo{
Name: nm,
}
}
for nm, _ := range translate.Substites {
m[nm] = SoundInfo{Name: nm}
}
l := make([]SoundInfo, 0, len(m))
for _, si := range m {
l = append(l, si)
}
sort.Slice(l, func(i, j int) bool { return l[i].Name < l[j].Name })
return l, m
}()
Functions ¶
Types ¶
Click to show internal directories.
Click to hide internal directories.