mirror of
https://github.com/jackmerrill/hampbot.git
synced 2025-02-24 03:27:51 -08:00
25 lines
625 B
Go
25 lines
625 B
Go
package embed
|
|
|
|
import (
|
|
"fmt"
|
|
|
|
"github.com/jackmerrill/hampbot/internal/utils/config"
|
|
"github.com/zekroTJA/shireikan"
|
|
)
|
|
|
|
func NewGenericEmbed(ctx shireikan.Context) *Embed {
|
|
return NewEmbed().SetFooter(fmt.Sprintf("HampBot %s", config.Version), ctx.GetSession().State.User.AvatarURL("256"))
|
|
}
|
|
|
|
func NewSuccessEmbed(ctx shireikan.Context) *Embed {
|
|
return NewGenericEmbed(ctx).SetColor(0x00ff00)
|
|
}
|
|
|
|
func NewWarningEmbed(ctx shireikan.Context) *Embed {
|
|
return NewGenericEmbed(ctx).SetColor(0xffff00)
|
|
}
|
|
|
|
func NewErrorEmbed(ctx shireikan.Context) *Embed {
|
|
return NewGenericEmbed(ctx).SetColor(0xff0000).SetTitle("Error")
|
|
}
|