-
Notifications
You must be signed in to change notification settings - Fork 4
Skin Data
Every skin is defined by a table that contains skin's name, ID of a skin that should be used as a template and references to the toast's regions and their properties.
Here's an example of a skin table with all the possible entries.
local skinTable = {
name = "skinName",
template = "anotherSkinID",
border = {...},
title = {...},
text = {...},
bonus = {...},
dragon = {...},
icon = {...},
icon_border = {...},
icon_highlight = {...},
icon_text_1 = {...},
icon_text_2 = {...},
skull = {...},
slot = {...},
bg = {...},
},
}
The only mandatory field is name
. template
, if not defined or another skin's ID is invalid, will be set to "default", which means that the default skin will be used as the template. Other entries, if not defined, will be copied from the template skin table.
-
string
, required
name = "skinName"
The ID of a skin that should be used as a template. Defaults to "default"
-
string
, optional
template = "anotherSkinID"
-
table
, optional-
color -
table
, optional- The default colour
-
offset -
number
, optional- Indicates how far the border is offset from or inset in the toast
-
size -
number
, optional- The size
-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
color -
-- defaults
border = {
color = {1, 1, 1},
offset = -6,
size = 16,
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-border",
}
The upper text
-
table
, optional-
color -
table
, optional- The default colour
-
flags -
string
, optional- Font flags that will be passed to
:SetFont
method as the third argument
- Font flags that will be passed to
-
shadow -
boolean
, optional- Toggles the text shadow
-
color -
-- defaults
title = {
color = {1, 0.82, 0},
flags = "",
shadow = true,
}
The lower text
-
table
, optional-
color -
table
, optional- The default colour
-
flags -
string
, optional- Font flags that will be passed to
:SetFont
method as the third argument
- Font flags that will be passed to
-
shadow -
boolean
, optional- Toggles the text shadow
-
color -
-- defaults
text = {
color = {1, 1, 1},
flags = "",
shadow = true,
}
The texture that is used as the bonus completion indicator in scenarios
-
table
, optional-
hidden -
boolean
, optional- If true, the texture will be permanently hidden
-
hidden -
-- defaults
bonus = {
hidden = false,
}
The texture that is used as the legendary item indicator
-
table
, optional-
hidden -
boolean
, optional- If true, the texture will be permanently hidden
-
hidden -
-- defaults
dragon = {
hidden = false,
}
-
table
, optional-
tex_coords -
table
, optional- Arguments passed to
:SetTexCoord
method
- Arguments passed to
-
tex_coords -
-- defaults
icon = {
tex_coords = {4 / 64, 60 / 64, 4 / 64, 60 / 64},
}
-
table
, optional-
color -
table
, optional- The default colour
-
offset -
number
, optional- Indicates how far the border is offset from or inset in the icon
-
size -
number
, optional- The size
-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
color -
-- defaults
icon_border = {
color = {1, 1, 1},
offset = -4,
size = 16,
texture = "Interface\\AddOns\\ls_Toasts\\assets\\icon-border",
}
The texture that is used as the quest item indicator
-
table
, optional-
hidden -
boolean
, optional- If true, the texture will be permanently hidden
-
tex_coords -
table
, optional- Arguments passed to
:SetTexCoord
method
- Arguments passed to
-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
hidden -
-- defaults
icon_highlight = {
hidden = false,
tex_coords = {4 / 64, 60 / 64, 4 / 64, 60 / 64},
texture = "Interface\\ContainerFrame\\UI-Icon-QuestBorder",
}
The icon's lower text
-
table
, optional-
color -
table
, optional- The default colour
-
flags -
string
, optional- Font flags that will be passed to
:SetFont
method as the third argument
- Font flags that will be passed to
-
shadow -
boolean
, optional- Toggles the text shadow
-
color -
-- defaults
icon_text_1 = {
color = {1, 1, 1},
flags = "THINOUTLINE",
shadow = false,
}
The icon's upper text
-
table
, optional-
color -
table
, optional- The default colour
-
flags -
string
, optional- Font flags that will be passed to
:SetFont
method as the third argument
- Font flags that will be passed to
-
shadow -
boolean
, optional- Toggles the text shadow
-
color -
-- defaults
icon_text_2 = {
color = {1, 1, 1},
flags = "THINOUTLINE",
shadow = false,
}
The texture that is used as the heroic difficulty indicator
-
table
, optional-
hidden -
boolean
, optional- If true, the texture will be permanently hidden
-
hidden -
-- defaults
skull = {
hidden = false,
}
The small frames that are used to display additional rewards
-
table
, optional-
mask -
string
, optional- The mask applied to the slot's icon
-
tex_coords -
table
, optional- Arguments passed to
:SetTexCoord
method of the slot's icon
- Arguments passed to
-
texture -
string
, optional- The border texture
-
mask -
-- defaults
slot = {
mask = "Interface\\CHARACTERFRAME\\TempPortraitAlphaMaskSmall",
tex_coords = {28 / 128, 100 / 128, 28 / 128, 100 / 128},
texture = "Interface\\AddOns\\ls_Toasts\\assets\\slot-border",
},
The background texture
-
table
, optional-
alliance -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
archaeology -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
collection -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
default -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
dungeon -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
horde -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
legendary -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
legion -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
recipe -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
store -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
transmog -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
upgrade -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
worldquest -
table
, optional-
texture -
string
,table
, optional- The texture. A string will be passed to
:SetTexture
method, a table will be unpacked and passed to:SetColorTexture
method
- The texture. A string will be passed to
-
texture -
-
alliance -
-- defaults
bg = {
alliance = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-alliance",
},
archaeology = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-archaeology",
},
collection = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-collection",
},
default = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-default",
},
dungeon = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-dungeon",
},
horde = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-horde",
},
legendary = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-legendary",
},
legion = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-legion",
},
recipe = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-recipe",
},
store = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-store",
},
transmog = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-transmog",
},
upgrade = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-upgrade",
},
worldquest = {
texture = "Interface\\AddOns\\ls_Toasts\\assets\\toast-bg-worldquest",
},
}