Diferencia entre revisiones de «Módulo:LootChest»

Leynaf (discusión | contribs.)
Sin resumen de edición
Leynaf (discusión | contribs.)
Sin resumen de edición
 
(No se muestran 12 ediciones intermedias del mismo usuario)
Línea 24: Línea 24:
end,
end,
dev = 'In {{1.9}},{{upcoming}} ',
dev = 'En la {{1.9}}, ',
-- these define which sprite, label and link to use, in the table,
-- these define which sprite, label and link to use, in the table,
Línea 117: Línea 117:


notes = {
notes = {
["level-book"] = "<ref group='note' name='level-book'>Enchanted books in the same chest will have the same enchantments (not in {{1.9}}{{upcoming}}). Enchantment probabilities are the same as a level-30 enchantment on an [[enchantment table]], but the chance of multiple enchantments is not reduced.</ref>",
["level-book"] = "<ref group='note' name='level-book'>Los libros encantados que se encuentren en el mismo cofre tendrán los mismos encantos (no en la {{1.9}}. Las probabilidades de encantamiento son las mismas que un hechizo de nivel 30 en una [[mesa de encantamientos]], pero la posibilidad de múltiples encantos no se reduce.</ref>",
["end-ench-equipment"] = "<ref group='note' name='end-city-enchantment'>Enchanted items of the same type in the same chest will have the same enchantments. Enchantment probabilities are the same as a level-20 to level-39 <!-- Yes, really 39 even though the table normally only goes to 30 --> enchantment on an [[enchantment table]].</ref>",
["end-ench-equipment"] = "<ref group='note' name='end-city-enchantment'>Los objetos encantados del mismo tipo en el mismo cofre tendrán los mismos encantos. Las probabilidades de encanto son las mismas que de un nivel 20 a un nivel 39<!-- Sí, realmente 39 a pesar de que la mesa normalmente sólo va hasta 30 --> de encanto en una [[mesa de encantamientos]].</ref>",
["random-book"] = "<ref group='note' name='random-book'>All enchantments are equally probable, and any level of the enchantment is equally probable.</ref>",
["random-book"] = "<ref group='note' name='random-book'>Todos los encantamientos son igualmente probables, y cualquier nivel de encantamiento es igualmente probable.</ref>",
},
},
Línea 359: Línea 359:
},
},
["mineshaft"] = { -- abandoned_mineshaft.json
["mineshaft"] = { -- abandoned_mineshaft.json
header = "[[Mina]]",
header = "[[Minas abandonadas|Mina]]",
link  = "[[Mina abandonada]]",
link  = "[[Minas abandonadas]]",
pools = {
pools = {
{
{
Línea 464: Línea 464:
},
},
["desert-temple"] = { -- desert_pyramid.json
["desert-temple"] = { -- desert_pyramid.json
header = "[[Templo del desierto]]",
header = "[[Templo del desierto|Templo del]]<br>[[Templo del desierto|desierto]]",
link  = "[[Templo del desierto]]",
link  = "[[Templo del desierto]]",
pools = {
pools = {
Línea 518: Línea 518:
},
},
["jungle-temple"] = { -- jungle-temple.json
["jungle-temple"] = { -- jungle-temple.json
header = "[[Jungle temple]]",
header = "[[Templo de la selva|Templo de]]<br>[[Templo de la selva|la selva]]",
link  = "[[jungle temple]]",
link  = "[[Templo de la selva]]",
pools = {
pools = {
{
{
Línea 540: Línea 540:
},
},
["end-city"] = { -- end_city_treasure.json
["end-city"] = { -- end_city_treasure.json
header = "[[Ciudad del Fin]]",
header = "[[Ciudad del Fin|Ciudad]]<br>[[Ciudad del Fin|del Fin]]",
link  = "[[Ciudad del Fin]]",
link  = "[[Ciudad del Fin]]",
poolsDev = {
poolsDev = {
Línea 625: Línea 625:
display_names = {
display_names = {
["nether-fortress"] = "Nether fortress",
["nether-fortress"] = "fortaleza del inframundo",
["nether"] = "Nether fortress",
["nether"] = "fortaleza del inframundo",
["fortress"] = "Nether fortress",
["fortress"] = "fortaleza del inframundo",
["desert"] = "desert temple",
["desert"] = "templo del desierto",
["jungle"] = "jungle temple",
["jungle"] = "templo de la selva",
["desert-temple"] = "desert temple",
["desert-temple"] = "templo del desierto",
["jungle-temple"] = "jungle temple"
["jungle-temple"] = "templo de la selva"
},
},
Línea 795: Línea 795:
table.insert( html, item_display_name )
table.insert( html, item_display_name )
table.insert( html, ' can be found ' )
table.insert( html, ' se pueden encontrar ' )


local html_stacks = {}
local html_stacks = {}
Línea 805: Línea 805:
s = s + 1
s = s + 1
local html_per_stack = { 'in ' }
local html_per_stack = { 'en ' }
local c = 0
local c = 0
local nc = q.tablelength( chest_details )
local nc = q.tablelength( chest_details )
Línea 815: Línea 815:
c = c + 1
c = c + 1
if c == nc and nc > 1 then
if c == nc and nc > 1 then
table.insert( html_per_stack, 'and ' )
table.insert( html_per_stack, 'y ' )
end
end
table.insert( html_per_stack, string.format("%.1f", chest.chance*100) )
table.insert( html_per_stack, string.format("%.1f", chest.chance*100) )
table.insert( html_per_stack, "% of " )
table.insert( html_per_stack, "% de " )
if chest.chest_name == 'mineshaft' then
if chest.chest_name == 'mineshaft' then
table.insert( html_per_stack, ' [[Minecart with Chest|chest minecarts]] in ' )
table.insert( html_per_stack, ' [[Vagoneta con cofre|vagonetas con cofre]] en ' )
table.insert( html_per_stack, p.chests[chest.chest_name].link )
table.insert( html_per_stack, p.chests[chest.chest_name].link )
else
else
table.insert( html_per_stack, p.chests[chest.chest_name].link )
table.insert( html_per_stack, p.chests[chest.chest_name].link )
table.insert( html_per_stack, ' chests' )
table.insert( html_per_stack, ' cofres' )
end
end
table.insert( html_per_stack, sep )
table.insert( html_per_stack, sep )
end
end
if nc > 2 then
if nc > 2 then
table.insert( html_per_stack, 'all ' )
table.insert( html_per_stack, 'todo ' )
end
end
table.insert( html_per_stack, 'in ' )
table.insert( html_per_stack, 'en ' )
if p.items[itemname].cannot_stack ~= nil then
if p.items[itemname].cannot_stack ~= nil then
table.insert( html_per_stack, 'groups of ' )
table.insert( html_per_stack, 'grupos de ' )
else
else
table.insert( html_per_stack, 'stacks of ' )
table.insert( html_per_stack, 'pilas de ' )
end
end
table.insert( html_per_stack, stacksize )
table.insert( html_per_stack, stacksize )
Línea 850: Línea 850:
table.insert( html, stack_sep )  
table.insert( html, stack_sep )  
end
end
table.insert( html, 'and ' )
table.insert( html, 'y ' )
table.insert( html, html_stacks[#html_stacks] )
table.insert( html, html_stacks[#html_stacks] )
end
end
Línea 1246: Línea 1246:
chest_name = chest_name:gsub( "-", " " )
chest_name = chest_name:gsub( "-", " " )
table.insert( html, "Each " )
table.insert( html, "Cada " )
table.insert( html, display_name or chest_name )
table.insert( html, display_name or chest_name )
table.insert( html, " chest contains " )
table.insert( html, " cofre contiene " )
if #allRolls == 1 then
if #allRolls == 1 then
table.insert( html, allRolls[1] )
table.insert( html, allRolls[1] )
else
else
table.insert( html, #allRolls )
table.insert( html, #allRolls )
table.insert( html, ' groups of ' )
table.insert( html, ' grupos de ' )
local s = q.tern( #allRolls > 2, ', ', ' ' )
local s = q.tern( #allRolls > 2, ', ', ' ' )
for i = 1, #allRolls-1 do
for i = 1, #allRolls-1 do
Línea 1259: Línea 1259:
table.insert( html, s )
table.insert( html, s )
end
end
table.insert( html, 'and ' )
table.insert( html, 'y ' )
table.insert( html, allRolls[#allRolls] )
table.insert( html, allRolls[#allRolls] )
end
end
table.insert( html, " item stacks, with the following distribution: \n" )
table.insert( html, " pilas de objetos, con la siguiente distribución: \n" )
end
end