Bureaucrats, Check users, emailconfirmed, Interface administrators, staff, Administrators, translation-admin, Widget editors
1,659
edits
(Add Yellow "Enchanted Book") |
(Vanilla enchanted items) |
||
Line 27: | Line 27: | ||
for _, name in ipairs( yellowTooltips ) do | for _, name in ipairs( yellowTooltips ) do | ||
aliases[name] = { title = '&e', name = name } | aliases[name] = { title = '&e', name = name } | ||
end | |||
local enchantedIconYellowTooltips = { | |||
'Bottle o\' Enchanting', | |||
'Enchanted Book', | |||
'Nether Star' | |||
} | |||
for _, name in ipairs( enchantedIconYellowTooltips ) do | |||
aliases[name] = { title = '&e', name = name, enchanted = yes } | |||
end | end | ||
Line 36: | Line 46: | ||
for _, name in ipairs( aquaTooltips ) do | for _, name in ipairs( aquaTooltips ) do | ||
aliases[name] = { title = '&b', name = name } | aliases[name] = { title = '&b', name = name } | ||
end | |||
local enchantedIconAquaTooltips = { | |||
'End Crystal' | |||
} | |||
for _, name in ipair( enchantedIconAquaTooltips ) do | |||
aliases[name] = { title = '&b', name = name, enchanted = yes } | |||
end | end | ||
Line 42: | Line 60: | ||
'Structure Block', | 'Structure Block', | ||
} | } | ||
for _, name in ipairs( lightPurpleTooltips ) do | for _, name in ipairs( lightPurpleTooltips ) do | ||
aliases[name] = { title = '&d', name = name } | aliases[name] = { title = '&d', name = name } | ||
end | end | ||
local enchantedIconPurpleTooltips = { | |||
'Enchanted Golden Apple' | |||
} | |||
for _, name in ipairs( enchantedIconPurpleTooltips ) do | |||
aliases[name] = { title = '&d', name = name, enchanted = yes } | |||
end | |||
-- Discs -- | -- Discs -- | ||
Line 288: | Line 314: | ||
-- turtle master is weird, so just do a fancy string replacement | -- turtle master is weird, so just do a fancy string replacement | ||
if effect.text then | if effect.text then | ||
aliases[name] = { name = potionName, text = effect.text:gsub( '%$1', durations[1] ) } | aliases[name] = { name = potionName, text = effect.text:gsub( '%$1', durations[1] ), enchanted = yes } | ||
aliases[name .. ' Extended'] = { name = potionName, text = effect.text:gsub( '%$1', durations[2] ) } | aliases[name .. ' Extended'] = { name = potionName, text = effect.text:gsub( '%$1', durations[2] ), enchanted = yes } | ||
aliases[name .. ' Enhanced'] = { name = potionName, text = effect.enhanced:gsub( '%$1', durations[3] ) } | aliases[name .. ' Enhanced'] = { name = potionName, text = effect.enhanced:gsub( '%$1', durations[3] ), enchanted = yes } | ||
else | else | ||
-- we always have normal | -- we always have normal | ||
aliases[name] = { name = potionName, text = string.format( '%s (%s)', effect.effect, durations[1] ) } | aliases[name] = { name = potionName, text = string.format( '%s (%s)', effect.effect, durations[1] ), enchanted = yes } | ||
-- ensure we have extended | -- ensure we have extended | ||
if durations[2] then | if durations[2] then | ||
aliases[name .. ' Extended'] = { name = potionName, text = string.format( '%s (%s)', effect.effect, durations[2] ) } | aliases[name .. ' Extended'] = { name = potionName, text = string.format( '%s (%s)', effect.effect, durations[2] ), enchanted = yes } | ||
-- and enhanced, currently there is nothing with a duration that can be extended but not enhanced | -- and enhanced, currently there is nothing with a duration that can be extended but not enhanced | ||
if effect.enhanced then | if effect.enhanced then | ||
aliases[name .. ' Enhanced'] = { name = potionName, text = string.format( '%s %s (%s)', effect.effect, effect.enhanced, durations[3] ) } | aliases[name .. ' Enhanced'] = { name = potionName, text = string.format( '%s %s (%s)', effect.effect, effect.enhanced, durations[3] ), enchanted = yes } | ||
end | end | ||
end | end | ||
Line 307: | Line 333: | ||
else | else | ||
-- otherwise its just effect, currently every potion with no duration can be enhanced | -- otherwise its just effect, currently every potion with no duration can be enhanced | ||
aliases[name] = { name = potionName, text = effect.effect} | aliases[name] = { name = potionName, text = effect.effect, enchanted = yes } | ||
aliases[name .. ' Enhanced'] = { name = potionName, text = effect.effect .. ' ' .. effect.enhanced } | aliases[name .. ' Enhanced'] = { name = potionName, text = effect.effect .. ' ' .. effect.enhanced, enchanted = yes } | ||
end | end | ||
edits