diff --git a/bot/event.go b/bot/event.go index 71e0a7c..8dfa445 100644 --- a/bot/event.go +++ b/bot/event.go @@ -8,7 +8,7 @@ type eventBroker struct { GameStart func() error ChatMsg func(msg chat.Message, pos byte) error Disconnect func(reason chat.Message) error - HealhtChange func() error + HealthChange func() error Die func() error SoundPlay func(name string, category int, x, y, z float64, volume, pitch float32) error } diff --git a/bot/ingame.go b/bot/ingame.go index 503ece9..584e88d 100644 --- a/bot/ingame.go +++ b/bot/ingame.go @@ -295,8 +295,8 @@ func handleUpdateHealthPacket(c *Client, p pk.Packet) (err error) { c.Food = int32(Food) c.FoodSaturation = float32(FoodSaturation) - if c.Events.HealhtChange != nil { - err = c.Events.HealhtChange() + if c.Events.HealthChange != nil { + err = c.Events.HealthChange() if err != nil { return }