Модуль:tableofchemicals

Вернуться

Строка 51: Строка 51:
end
end
local substanceName = ""
local color = ""
local textColor = ""
local group = ""
local desc = ""
local physicalDesc = ""
if firstProductId and p.chem[firstProductId] then
if firstProductId and p.chem[firstProductId] then
substanceName = p.chem[firstProductId].name or firstProductId
templateArgs.id = p.chem[firstProductId].id
color = p.chem[firstProductId].color or ""
templateArgs.name = p.chem[firstProductId].name
textColor = p.chem[firstProductId].textColor or ""
templateArgs.description = p.chem[firstProductId].desc .. " На вид " .. p.chem[firstProductId].physicalDesc .. "."
group = p.chem[firstProductId].group or ""
templateArgs.color = p.chem[firstProductId].color
desc = p.chem[firstProductId].desc or ""
templateArgs.textColor = p.chem[firstProductId].textColor
physicalDesc = p.chem[firstProductId].physicalDesc or ""
templateArgs.effects = getEffects(firstProductId)
templateArgs.recipes_count = tablelength(p.chem[firstProductId].recipes)
end
end
templateArgs.substance = substanceName
templateArgs.color = color
templateArgs.textColor = textColor
templateArgs.group = group
templateArgs.desc = desc
templateArgs.physicalDesc = physicalDesc
local template = "Строка_реакции"
local template = "Строка_реакции"