Module:Gm4Sprite/Aliases: Difference between revisions

Okay this should work now
(Zauber armor maybe? Let's see if this works.)
(Okay this should work now)
Line 322: Line 322:
}
}


for _, armourPiece in ipairs (armourPiece ) do
for _, armourProps in ipairs ( armourPiece ) do
local aliasName = 'Zauber ' .. armourPiece
local aliasName = 'Zauber ' .. armourProps[1]


local armourSlotText = '&9+25% Magic//&7When on '
local armourSlotText = '&9+25% Magic//&7When on '


if armourPiece[1] == 'Helmet' then
if armourProps[1] == 'Helmet' then
armourSlotText = armourSlotText .. 'head'
armourSlotText = armourSlotText .. 'head'
elseif armourPiece[1] == 'Chestplate' then
elseif armourProps[1] == 'Chestplate' then
armourSlotText = armourSlotText .. 'body'
armourSlotText = armourSlotText .. 'body'
elseif armourPiece[1] == 'Leggings' then
elseif armourProps[1] == 'Leggings' then
armourSlotText = armourSlotText .. 'legs'
armourSlotText = armourSlotText .. 'legs'
else
else
Line 341: Line 341:


-- If Armour Toughness (diamond armour)
-- If Armour Toughness (diamond armour)
aliases[aliasName] = { title = '&b' .. 'Zauber ' .. armourPiece, name = aliasName, text = armourSlotText .. '+' .. armourPiece[3] .. ' Armour Toughness/+' .. armourPiece[2] .. ' Armour' }
aliases[aliasName] = { title = '&b' .. 'Zauber ' .. armourProps[1], name = aliasName, text = armourSlotText .. '+' .. armourProps[3] .. ' Armour Toughness/+' .. armourProps[2] .. ' Armour' }
for _, armourBuff in ipairs( armourBuff ) do
for _, buff in ipairs( armourBuff ) do


if armourBuff == 'Health' then
if buff == 'Health' then
armourSlotText = armourSlotText .. '+4 Max Health/'
armourSlotText = armourSlotText .. '+4 Max Health/'
elseif armourBuff == 'Knockback' then
elseif buff == 'Knockback' then
armourSlotText = armourSlotText .. '+0.25 Knockback Resistance/'
armourSlotText = armourSlotText .. '+0.25 Knockback Resistance/'
elseif armourBuff == 'Speed' then
elseif buff == 'Speed' then
armourSlotText = armourSlotText .. '+10% Speed/'
armourSlotText = armourSlotText .. '+10% Speed/'
else
else
Line 356: Line 356:


-- If Armour Toughness (diamond armour)
-- If Armour Toughness (diamond armour)
aliases[aliasName] = { title = '&b' .. 'Zauber ' .. armourPiece, name = aliasName, text = armourSlotText .. '+' .. armourPiece[3] .. ' Armour Toughness/+' .. armourPiece[2] .. ' Armour' }
aliases[aliasName] = { title = '&b' .. 'Zauber ' .. armourProps[1], name = aliasName, text = armourSlotText .. '+' .. armourProps[3] .. ' Armour Toughness/+' .. armourProps[2] .. ' Armour' }
end
end
end
end
Bureaucrats, Check users, emailconfirmed, Interface administrators, staff, Administrators, translation-admin, Widget editors
1,637

edits