rename bot/chat to bot/msg

This commit is contained in:
Tnze
2022-11-27 16:10:06 +08:00
parent fad92fe364
commit f19d39c6d0
4 changed files with 11 additions and 11 deletions

View File

@ -1,4 +1,4 @@
package chat
package msg
import (
"fmt"
@ -13,14 +13,14 @@ import (
"github.com/google/uuid"
)
type Chat struct {
type Manager struct {
c *bot.Client
p *basic.Player
}
func NewChat(c *bot.Client, p *basic.Player, events EventsHandler) *Chat {
func New(c *bot.Client, p *basic.Player, events EventsHandler) *Manager {
attachPlayerMsg(c, p, events.PlayerChatMessage)
return &Chat{c, p}
return &Manager{c, p}
}
func attachPlayerMsg(c *bot.Client, p *basic.Player, handler func(msg chat.Message) error) {

View File

@ -1,4 +1,4 @@
package chat
package msg
import "github.com/Tnze/go-mc/chat"