Documentation ¶
Index ¶
- Constants
- func CheckPermissions(s *discordgo.Session, guildid, memberid string, required Permission) bool
- type Embed
- func (e *Embed) AddField(name, value string) *Embed
- func (e *Embed) AddInlineField(name, value string) *Embed
- func (e *Embed) InlineAllFields() *Embed
- func (e *Embed) SetAuthor(args ...string) *Embed
- func (e *Embed) SetColor(clr int) *Embed
- func (e *Embed) SetDescription(description string) *Embed
- func (e *Embed) SetFooter(args ...string) *Embed
- func (e *Embed) SetImage(args ...string) *Embed
- func (e *Embed) SetThumbnail(args ...string) *Embed
- func (e *Embed) SetTitle(name string) *Embed
- func (e *Embed) SetURL(URL string) *Embed
- func (e *Embed) Truncate() *Embed
- func (e *Embed) TruncateDescription() *Embed
- func (e *Embed) TruncateFields() *Embed
- func (e *Embed) TruncateFooter() *Embed
- func (e *Embed) TruncateTitle() *Embed
- type Permission
Constants ¶
View Source
const ( COLOR int = 0x532c60 VERSION string = "v0.10.0" BOTTAG string = "<:bot:671061944358142007>" PermissionAdministrator Permission = 8 PermissionViewAuditLog Permission = 128 PermissionViewServerInsights Permission = 524288 PermissionManageServer Permission = 32 PermissionManageRoles Permission = 268435456 PermissionManageChannels Permission = 16 PermissionKickMembers Permission = 2 PermissionBanMembers Permission = 4 PermissionCreateInstantInvite Permission = 1 PermissionChangeNickname Permission = 67108864 PermissionManageNicknames Permission = 134217728 PermissionManageEmojis Permission = 1073741824 PermissionManageWebhooks Permission = 536870912 PermissionViewChannels Permission = 1024 PermissionMessagesSend Permission = 2048 PermissionMessagesSendTTS Permission = 4096 PermissionMessagesManage Permission = 8192 PermissionMessagesEmbedLinks Permission = 16384 PermissionMessagesAttachFiles Permission = 32768 PermissionMessagesReadHistory Permission = 65536 PermissionMessagesMentionEveryone Permission = 131072 PermissionMessagesUseExternalEmojis Permission = 262144 PermissionMessagesAddReactions Permission = 64 PermissionVoiceConnect Permission = 1048576 PermissionVoiceSpeak Permission = 2097152 PermissionVoiceMuteMembers Permission = 4194304 PermissionVoiceDeafenMembers Permission = 8388608 PermissionVoiceUseMembers Permission = 16777216 PermissionVoiceUseActivity Permission = 33554432 PermissionVoicePrioritySpeaker Permission = 256 )
View Source
const ( EmbedLimitTitle = 256 EmbedLimitDescription = 2048 EmbedLimitFieldValue = 1024 EmbedLimitFieldName = 256 EmbedLimitField = 25 EmbedLimit = 4000 )
Constants for message embed character limits
Variables ¶
This section is empty.
Functions ¶
func CheckPermissions ¶
func CheckPermissions(s *discordgo.Session, guildid, memberid string, required Permission) bool
Types ¶
type Embed ¶ added in v0.8.0
type Embed struct {
*discordgo.MessageEmbed
}
Embed ...
func (*Embed) AddInlineField ¶ added in v0.8.0
AddInlineField [name] [value]
func (*Embed) InlineAllFields ¶ added in v0.8.0
InlineAllFields sets all fields in the embed to be inline
func (*Embed) SetDescription ¶ added in v0.8.0
SetDescription [desc]
func (*Embed) SetThumbnail ¶ added in v0.8.0
SetThumbnail ...
func (*Embed) Truncate ¶ added in v0.8.0
Truncate truncates any embed value over the character limit.
func (*Embed) TruncateDescription ¶ added in v0.8.0
TruncateDescription ...
func (*Embed) TruncateFields ¶ added in v0.8.0
TruncateFields truncates fields that are too long
func (*Embed) TruncateFooter ¶ added in v0.8.0
TruncateFooter ...
func (*Embed) TruncateTitle ¶ added in v0.8.0
TruncateTitle ...
type Permission ¶
type Permission int
Click to show internal directories.
Click to hide internal directories.