Hypixel SkyBlock Wiki
No edit summary
No edit summary
 
(119 intermediate revisions by 6 users not shown)
Line 1: Line 1:
  +
return {
require('Module:MultiRequire')
 
  +
-- Item names that are copied from wikitools in the MC-item mode that needs remapping
--<pre>
 
  +
-- These are paired with enchanted versions if it exists on wiki
--Initial values from https://minecraft.gamepedia.com/Module:Inventory_slot/Aliases
 
  +
['Spawn'] = 'Spawn Egg',
local aliases = {}
 
  +
['Sugar Canes'] = 'Sugar Cane',
local table = require('Module:Table')
 
  +
['Enchanted Sugar Canes'] = 'Enchanted Sugar Cane',
local uiText = require('Module:UIText')._main
 
  +
['Snow'] = 'Snow Block',
local string = require('Module:String')
 
  +
['Enchanted Snow'] = 'Enchanted Snow Block',
local tooltips = require('Module:Inventory slot/Tooltips')
 
  +
-- Others
local minionData, petData, textData = loadDataMulti('Module:Minion/Data', 'Module:Pet/Data', 'Module:UIText/Data')
 
  +
['Redstone Dust'] = 'Redstone',
local petModule = require("Module:Pet")
 
  +
['Jack o\'Lantern'] = 'Jack o\' Lantern',
 
  +
['Enchanted Iron Ingot'] = 'Enchanted Iron',
local rarityAliases = require('Module:RarityTier/Aliases')
 
  +
['Enchanted Gold Ingot'] = 'Enchanted Gold',
local rarityData = require('Module:RarityTier/Data')
 
  +
['Necron\'s Blade (Unrefined)'] = 'Necron\'s Blade',
local statAliases = require('Module:Statname/aliases')
 
  +
['Perfect Helmet'] = 'Perfect Helmet - Tier I',
local statData = require('Module:Statname/Data')
 
  +
['Perfect Chestplate'] = 'Perfect Chestplate - Tier I',
 
  +
['Perfect Leggings'] = 'Perfect Leggings - Tier I',
local function mergeTables(target, merger)
 
  +
['Perfect Boots'] = 'Perfect Boots - Tier I',
for k, v in pairs(merger) do
 
  +
['Nether Brick Stairs'] = 'Nether Bricks Stairs',
target[k] = v
 
  +
['Ink Sack'] = 'Ink Sac',
end
 
  +
['Mushroom Soup'] = 'Mushroom Stew',
return target
 
  +
['Bitter Ice Tea'] = 'Bitter Iced Tea',
end
 
  +
['Seed'] = 'Seeds',
 
  +
['Tesselated Ender Pearl'] = 'Tessellated Ender Pearl',
local function getTooltips(keys)
 
  +
['Enchanted Ink Sack'] = 'Enchanted Ink Sac',
local ret = {}
 
  +
['Music Disc 11'] = 'Music Disc - 11',
if type(keys) == "table" then
 
  +
['Music Disc 13'] = 'Music Disc - 13',
for i, key in ipairs(keys) do
 
  +
['Music Disc Blocks'] = 'Music Disc - Blocks',
ret[i] = tooltips[key] or key
 
  +
['Music Disc Cat'] = 'Music Disc - Cat',
end
 
  +
['Music Disc Chirp'] = 'Music Disc - Chirp',
return ret
 
  +
['Music Disc Far'] = 'Music Disc - Far',
else
 
  +
['Music Disc Mall'] = 'Music Disc - Mall',
return tooltips[key] or key
 
  +
['Music Disc Mellohi'] = 'Music Disc - Mellohi',
end
 
  +
['Music Disc Stal'] = 'Music Disc - Stal',
end
 
  +
['Music Disc Strad'] = 'Music Disc - Strad',
 
  +
['Music Disc Wait'] = 'Music Disc - Wait',
--------------------------------------------------------------------------------
 
  +
['Music Disc Ward'] = 'Music Disc - Ward',
-- Item Tool tips
 
  +
['Dctr\'s Space Helmet'] = 'Space Helmet',
--
 
  +
['Coco Chopper'] = 'Cocoa Chopper',
-- See https://hypixel.net/threads/guide-minecraft-color-codes.1741307/
 
  +
['Melon (block)'] = 'Melon Block',
-- for information on the color syntax.
 
  +
['Dungeon Journal (Admin-only item)'] = 'Dungeon Journal',
--
 
  +
['Abiphone (Bingo)'] = 'AⒷiphone',
-- Other syntax:
 
-- *\ - New line
 
--------------------------------------------------------------------------------
 
-- Data from Module:Inventory slot/Tooltips
 
table.merge(aliases, tooltips)
 
 
table.merge(aliases, {
 
['Oak Wood Planks'] = aliases['Oak Wood Plank'],
 
['Spruce Wood Planks'] = aliases['Spruce Wood Plank'],
 
['Birch Wood Planks'] = aliases['Birch Wood Plank'],
 
['Jungle Wood Planks'] = aliases['Jungle Wood Plank'],
 
['Acacia Wood Planks'] = aliases['Acacia Wood Plank'],
 
['Dark Oak Wood Planks'] = aliases['Dark Oak Wood Plank'],
 
})
 
----------------------
 
-- Hypixel Skyblock stuff
 
----------------------
 
table.merge(aliases, {
 
-- Display names --
 
['Melon'] = { title = 'Melon', name = 'Melon Slice' },
 
['Melon Slice'] = { title = 'Melon', name = 'Melon Slice' },
 
['Melon (block)'] = { title = 'Melon', name = 'Melon (block)' },
 
['Mushroom'] = getTooltips{ 'Red Mushroom', 'Brown Mushroom' },
 
['Enchanted Mushroom'] = getTooltips{ 'Enchanted Red Mushroom', 'Enchanted Brown Mushroom' },
 
 
-- Fake items
 
['Air (minion)'] = { title = 'Air', name = 'Minions', image = 'Air (minion)', text = '&7Air should be 1 layer/underneath where the minion/is standing.', link = 'none' },
 
['Blank'] = { image = 'Black Stained Glass Pane', name = 'none', title = 'none', link='none', text='none' },
 
['Sell Item'] = { name = 'Hopper', title = '&aSell Item', link='none', text='&7Click items in your inventory to/sell them to the shop!' },
 
['Close'] = { name = 'Barrier', title = '&cClose', link='none', text='none' },
 
['Cancel'] = { name = 'Barrier', title = '&cCancel', link='none', text='none' },
 
['Go Back'] = { name = 'Arrow', title = '&aGo Back', link='none'},
 
['Next Page'] = { name = 'Arrow', title = '&aNext Page', link='none'},
 
['Previous Page'] = { name = 'Arrow', title = '&aPrevious Page', link='none'},
 
['SkyBlock Menu'] = { name = 'SkyBlock Menu', title = '&aSkyBlock Menu &7(Right Click)', text = '&7View all of your SkyBlock/&7progress, including your Skills,/&7Collections, Recipes, and more!//&eClick to open!', },
 
})
 
 
-- Make it so minions tiers use the image, but link to actual page
 
local minions = {
 
-- Farming
 
'Wheat', 'Carrot', 'Potato', 'Pumpkin', 'Melon', 'Mushroom', 'Cocoa Beans', 'Cactus', 'Sugar Cane', 'Cow', 'Pig', 'Chicken', 'Sheep', 'Rabbit', 'Nether Wart',
 
-- Mining
 
'Cobblestone', 'Coal', 'Iron', 'Gold', 'Diamond', 'Lapis', 'Emerald', 'Redstone', 'Quartz', 'Obsidian', 'Glowstone', 'Gravel', 'Ice', 'Sand', 'End Stone', 'Clay', 'Mithril',
 
-- Combat
 
'Zombie', 'Skeleton', 'Spider', 'Cave Spider', 'Creeper', 'Enderman', 'Ghast', 'Slime', 'Blaze', 'Magma Cube',
 
-- Slayer
 
'Revenant', 'Tarantula', 'Voidling',
 
-- Woodcutting
 
'Oak', 'Spruce', 'Birch', 'Dark Oak', 'Acacia', 'Jungle',
 
-- Misc
 
'Fishing', 'Flower', 'Snow',
 
 
}
 
}
 
local minionsTiers = { "I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII" };
 
for _, name in ipairs(minions) do
 
for i, tier in ipairs(minionsTiers) do
 
if minionData[name].stats[i] then
 
local key = name.." Minion "..tier
 
local description = minionData[name].description or 'No Description'
 
aliases[key] = { title = '&9'..key, name = name.." Minion#"..tier, image = key, text = description..'//&7Time Between Action: &a'..minionData[name].stats[i].tba..'s/&7Max Storage: &e'..minionData[name].stats[i].storage }
 
end
 
end
 
end
 
 
-- Make it so enchanted books link to enchantments with href to enchant
 
local ench_data = require("Module:Link/enchantmentsLink/Data")
 
for name, ench in pairs(ench_data) do
 
for tier = 1, ench.max, 1 do
 
local tier_display = string._toRoman(tier)
 
local key = "Enchanted Book ("..name.." "..tier_display..")"
 
aliases[key] = { title = "Enchanted Book", text=(ench.isUltimate and "&d&l" or "&9")..name.." "..tier_display, name = "Enchantments#".. mw.uri.anchorEncode(name), image = "Enchanted Book" }
 
end
 
end
 
 
-- Mystery XX Pet
 
do
 
local seenPets = {}
 
 
for _, petName in pairs(table.keys(petData)) do
 
local data = petData[petName];
 
local rarities = table.map(string.split(data.rarities:gsub('%-', ''), ''), function(v)
 
return v:lower()
 
end)
 
 
local stats = {}
 
for stat, value in pairs(data.stats) do
 
if not value.req then
 
value = tonumber(value[1])
 
table.push(stats, ('&r%s: &a%s'):format(string.ucfirst(statAliases[stat]), value < 0 and value or '+'..value))
 
end
 
end
 
 
aliases['Mystery '..petName..' Pet'] = {
 
title = '&9Mystery '..petName..' Pet',
 
text = uiText(string.dedent[[
 
&8%s Pet
 
 
%s
 
 
&6Perks:&r
 
&f&l???&r
 
&7Progress to level 2: &e0%%&r
 
&f-------------------- &e0&6/&e100&r
 
 
 
&6Quality:
 
&f&l???]]:format(data.petType or '', table.concat(stats, '\n')), ''),
 
name = petName..' Pet',
 
}
 
 
aliases[petName..' Pet'] = petModule._petTooltip(petName)
 
end
 
end
 
 
----------------------
 
-- Vanilla Minecraft stuff (may have some edits)
 
----------------------
 
local coloredDyes = {
 
'Orange Dye', 'Magenta Dye', 'Light Blue Dye', 'Dandelion Yellow', 'Lime Dye',
 
'Pink Dye', 'Gray Dye', 'Light Gray Dye', 'Cyan Dye', 'Purple Dye',
 
'Lapis Lazuli', 'Cocoa Beans', 'Cactus Green',
 
'Rose Red', 'Ink Sack',
 
}
 
-- Lists of item variants --
 
local itemVariants = {
 
['Dye'] = mw.clone(coloredDyes),
 
['Colored Dye'] = coloredDyes,
 
['Dyed Wool'] = {
 
'Orange Wool', 'Magenta Wool', 'Light Blue Wool', 'Yellow Wool', 'Lime Wool',
 
'Pink Wool', 'Gray Wool', 'Light Gray Wool', 'Cyan Wool', 'Purple Wool',
 
'Blue Wool', 'Brown Wool', 'Green Wool', 'Red Wool', 'Black Wool',
 
},
 
['Dyed Carpet'] = {
 
'Orange Carpet', 'Magenta Carpet', 'Light Blue Carpet', 'Yellow Carpet', 'Lime Carpet',
 
'Pink Carpet', 'Gray Carpet', 'Light Gray Carpet', 'Cyan Carpet', 'Purple Carpet',
 
'Blue Carpet', 'Brown Carpet', 'Green Carpet',
 
'Red Carpet', 'Black Carpet',
 
},
 
['Dyed Stained Clay'] = {
 
'White Stained Clay', 'Orange Stained Clay', 'Magenta Stained Clay', 'Light Blue Stained Clay',
 
'Yellow Stained Clay', 'Lime Stained Clay', 'Pink Stained Clay', 'Gray Stained Clay', 'Light Gray Stained Clay',
 
'Cyan Stained Clay', 'Purple Stained Clay', 'Blue Stained Clay', 'Brown Stained Clay',
 
'Green Stained Clay', 'Red Stained Clay', 'Black Stained Clay',
 
},
 
['Dyed Small Backpack'] = {
 
'Small Backpack (white)',
 
'Small Backpack (orange)', 'Small Backpack (magenta)', 'Small Backpack (light blue)',
 
'Small Backpack (yellow)', 'Small Backpack (lime)', 'Small Backpack (pink)',
 
'Small Backpack (gray)', 'Small Backpack (light gray)', 'Small Backpack (cyan)',
 
'Small Backpack (purple)', 'Small Backpack (blue)', 'Small Backpack (brown)',
 
'Small Backpack (green)', 'Small Backpack (red)', 'Small Backpack (black)',
 
},
 
['Dyed Medium Backpack'] = {
 
'Medium Backpack (white)',
 
'Medium Backpack (orange)', 'Medium Backpack (magenta)', 'Medium Backpack (light blue)',
 
'Medium Backpack (yellow)', 'Medium Backpack (lime)', 'Medium Backpack (pink)',
 
'Medium Backpack (gray)', 'Medium Backpack (light gray)', 'Medium Backpack (cyan)',
 
'Medium Backpack (purple)', 'Medium Backpack (blue)', 'Medium Backpack (brown)',
 
'Medium Backpack (green)', 'Medium Backpack (red)', 'Medium Backpack (black)',
 
},
 
['Dyed Large Backpack'] = {
 
'Large Backpack (white)',
 
'Large Backpack (orange)', 'Large Backpack (magenta)', 'Large Backpack (light blue)',
 
'Large Backpack (yellow)', 'Large Backpack (lime)', 'Large Backpack (pink)',
 
'Large Backpack (gray)', 'Large Backpack (light gray)', 'Large Backpack (cyan)',
 
'Large Backpack (purple)', 'Large Backpack (blue)', 'Large Backpack (brown)',
 
'Large Backpack (green)', 'Large Backpack (red)', 'Large Backpack (black)',
 
},
 
['Dyed Greater Backpack'] = {
 
'Greater Backpack (white)',
 
'Greater Backpack (orange)', 'Greater Backpack (magenta)', 'Greater Backpack (light blue)',
 
'Greater Backpack (yellow)', 'Greater Backpack (lime)', 'Greater Backpack (pink)',
 
'Greater Backpack (gray)', 'Greater Backpack (light gray)', 'Greater Backpack (cyan)',
 
'Greater Backpack (purple)', 'Greater Backpack (blue)', 'Greater Backpack (brown)',
 
'Greater Backpack (green)', 'Greater Backpack (red)', 'Greater Backpack (black)',
 
},
 
['Dyed Jumbo Backpack'] = {
 
'Jumbo Backpack (white)',
 
'Jumbo Backpack (orange)', 'Jumbo Backpack (magenta)', 'Jumbo Backpack (light blue)',
 
'Jumbo Backpack (yellow)', 'Jumbo Backpack (lime)', 'Jumbo Backpack (pink)',
 
'Jumbo Backpack (gray)', 'Jumbo Backpack (light gray)', 'Jumbo Backpack (cyan)',
 
'Jumbo Backpack (purple)', 'Jumbo Backpack (blue)', 'Jumbo Backpack (brown)',
 
'Jumbo Backpack (green)', 'Jumbo Backpack (red)', 'Jumbo Backpack (black)',
 
},
 
['Flower'] = { 'Oxeye Daisy', 'Red Tulip', 'Orange Tulip', 'White Tulip', 'Pink Tulip', 'Azure Bluet', 'Allium', 'Blue Orchid', 'Poppy', 'Dandelion' },
 
['Mushroom'] = { 'Red Mushroom', 'Brown Mushroom' },
 
['Quartz Block'] = { 'Block of Quartz', 'Chiseled Quartz Block', 'Quartz Pillar' },
 
['Red Sandstone'] = { 'Red Sandstone', 'Chiseled Red Sandstone', 'Smooth Red Sandstone' },
 
['Sandstone'] = { 'Sandstone', 'Chiseled Sandstone', 'Smooth Sandstone' },
 
['Stone Bricks'] = { 'Stone Bricks', 'Mossy Stone Bricks', 'Cracked Stone Bricks', 'Chiseled Stone Bricks' },
 
['Stone Slab'] = { 'Sandstone Slab', 'Cobblestone Slab', 'Brick Slab', 'Stone Brick Slab', 'Nether Brick Slab', 'Quartz Slab' },
 
['Stone'] = { 'Stone', 'Andesite', 'Granite', 'Diorite', 'Polished Andesite', 'Polished Granite', 'Polished Diorite' },
 
['Tulip'] = { 'Red Tulip', 'Orange Tulip', 'White Tulip', 'Pink Tulip' },
 
['Century Cake'] = { 'Crab-Colored Century Cake', 'Pet Rock Century Cake', 'aPunch Century Cake', 'Potato-Style Century Cake', 'Barry Century Cake', 'Sea Emperor Century Cake', 'Century Cake of the Next Dungeon Floor', 'Latest Update Century Cake', 'Streamer\'s Century Cake' },
 
}
 
table.unshift(itemVariants['Dye'], 'Bone Meal')
 
for aliasName, aliasItems in pairs(itemVariants) do
 
aliases['Any ' .. aliasName] = getTooltips(aliasItems)
 
aliases['Matching ' .. aliasName] = getTooltips(aliasItems)
 
end
 
 
-- Discs --
 
--local discs = { '13', 'Cat', 'Blocks', 'Chirp', 'Far', 'Mall', 'Mellohi', 'Stal', 'Strad', 'Ward', '11', 'Wait' }
 
--for _, disc in ipairs(discs) do
 
-- local name = 'Music Disc ' .. disc
 
-- aliases[name] = { title = '&bMusic Disc', name = name, text = '&7C418 - ' .. disc }
 
--end
 
 
-- Banners and colored items --
 
local colors = {
 
'White',
 
'Orange',
 
'Magenta',
 
'Light Blue',
 
'Yellow',
 
'Lime',
 
'Pink',
 
'Gray',
 
'Light Gray',
 
'Cyan',
 
'Purple',
 
'Blue',
 
'Brown',
 
'Green',
 
'Red',
 
'Black'
 
}
 
-- Items that use the sixteen colors --
 
local coloredItems = {
 
'Carpet',
 
'Wool',
 
'Stained Glass',
 
'Stained Glass Pane',
 
}
 
 
for i, item in ipairs(coloredItems) do
 
local coloredItemAliases = table.deepCopy(coloredItems)
 
local itemName = ""
 
 
for j, color in ipairs(colors) do
 
if item:find('%$1') then
 
itemName = item:gsub('%$1', color)
 
else
 
itemName = color .. ' ' .. item
 
end
 
coloredItemAliases[j] = itemName
 
end
 
 
item = item:gsub('%$1%s*', '')
 
aliases['Any ' .. item] = getTooltips(coloredItemAliases)
 
aliases['Matching ' .. item] = getTooltips(coloredItemAliases)
 
end
 
 
-- UI Blank (Any Specific Color) --
 
for _, color in ipairs(colors) do
 
aliases['Blank ('..color..')'] = { image = color..' Stained Glass Pane', name = 'none', title = 'none', link='none', text='none' }
 
end
 
 
-- Item groups --
 
local dragonArmors = { 'Protector', 'Old', 'Unstable', 'Holy', 'Wise', 'Young', 'Strong', 'Superior' }
 
for _, piece in ipairs{ 'Helmet', 'Chestplate', 'Leggings', 'Boots', 'Fragment' } do
 
local dragonRelatedAliases = getTooltips(table.map(table.deepCopy(dragonArmors), function(v)
 
return v .. ' Dragon ' .. piece
 
end))
 
aliases['Any ' .. piece] = getTooltips(dragonRelatedAliases)
 
aliases['Matching ' .. piece] = getTooltips(dragonRelatedAliases)
 
end
 
 
-- Wood --
 
local woods = {
 
'Oak',
 
'Spruce',
 
'Birch',
 
'Dark Oak',
 
'Acacia',
 
'Jungle'
 
}
 
local woodItems = {
 
'Wood',
 
'Wood Plank', -- Skyblock specific
 
'Wood Slab',
 
'Wood Stairs',
 
'Fence',
 
'Fence Gate',
 
'Sapling',
 
'Leaves',
 
}
 
 
for _, item in ipairs(woodItems) do
 
local itemName = ''
 
local woodAliases = {}
 
 
for _, wood in ipairs(woods) do
 
if item:find('wood') then
 
itemName = string.gsub(item, 'wood', wood)
 
elseif item:find('%$1') then
 
itemName = string.gsub(item, '%$1', wood)
 
else
 
itemName = wood .. ' ' .. item
 
end
 
table.insert(woodAliases, aliases[itemName] or itemName)
 
end
 
 
item = string.gsub(item, '%$1 ', '')
 
aliases['Any ' .. item] = getTooltips(woodAliases)
 
end
 
 
return aliases
 

Latest revision as of 15:18, 5 October 2023

Submodules


Caching

This Module Requires Cache Refresh After Changes
Module Page Name(s): Module:Inventory slot/Datasheet
Prerequisite: Option RefreshLuaCache in your gadget settings must be enabled.
Instruction: If prerequisite is met, button(s) for refreshing cache entries will load below.


Module:Inventory slot/Aliases/doc

Module Code

return {
	-- Item names that are copied from wikitools in the MC-item mode that needs remapping
	-- These are paired with enchanted versions if it exists on wiki
	['Spawn'] = 'Spawn Egg',
	['Sugar Canes'] = 'Sugar Cane',
	['Enchanted Sugar Canes'] = 'Enchanted Sugar Cane',
	['Snow'] = 'Snow Block',
	['Enchanted Snow'] = 'Enchanted Snow Block',
	-- Others
	['Redstone Dust'] = 'Redstone',
	['Jack o\'Lantern'] = 'Jack o\' Lantern',
	['Enchanted Iron Ingot'] = 'Enchanted Iron',
	['Enchanted Gold Ingot'] = 'Enchanted Gold',
	['Necron\'s Blade (Unrefined)'] = 'Necron\'s Blade',
	['Perfect Helmet'] = 'Perfect Helmet - Tier I',
	['Perfect Chestplate'] = 'Perfect Chestplate - Tier I',
	['Perfect Leggings'] = 'Perfect Leggings - Tier I',
	['Perfect Boots'] = 'Perfect Boots - Tier I',
	['Nether Brick Stairs'] = 'Nether Bricks Stairs',
	['Ink Sack'] = 'Ink Sac',
	['Mushroom Soup'] = 'Mushroom Stew',
	['Bitter Ice Tea'] = 'Bitter Iced Tea',
	['Seed'] = 'Seeds',
	['Tesselated Ender Pearl'] = 'Tessellated Ender Pearl',
	['Enchanted Ink Sack'] = 'Enchanted Ink Sac',
	['Music Disc 11'] = 'Music Disc - 11',
	['Music Disc 13'] = 'Music Disc - 13',
	['Music Disc Blocks'] = 'Music Disc - Blocks',
	['Music Disc Cat'] = 'Music Disc - Cat',
	['Music Disc Chirp'] = 'Music Disc - Chirp',
	['Music Disc Far'] = 'Music Disc - Far',
	['Music Disc Mall'] = 'Music Disc - Mall',
	['Music Disc Mellohi'] = 'Music Disc - Mellohi',
	['Music Disc Stal'] = 'Music Disc - Stal',
	['Music Disc Strad'] = 'Music Disc - Strad',
	['Music Disc Wait'] = 'Music Disc - Wait',
	['Music Disc Ward'] = 'Music Disc - Ward',
	['Dctr\'s Space Helmet'] = 'Space Helmet',
	['Coco Chopper'] = 'Cocoa Chopper',
	['Melon (block)'] = 'Melon Block',
	['Dungeon Journal (Admin-only item)'] = 'Dungeon Journal',
	['Abiphone (Bingo)'] = 'AⒷiphone',
}