Toggle menu
Toggle preferences menu
Toggle personal menu
Not logged in
Your IP address will be publicly visible if you make any edits.

Join the Playtest on Steam Now: SpiritVale

Module:GamePassives: Difference between revisions

From SpiritVale Wiki
No edit summary
No edit summary
Line 379: Line 379:
-- General
-- General
------------------------------------------------------------------
------------------------------------------------------------------
addSectionHeader(root, "General")
addRow(root, "Max Level", rec["Max Level"] and tostring(rec["Max Level"]))
addRow(root, "Max Level", rec["Max Level"] and tostring(rec["Max Level"]))


Line 396: Line 395:
or (req["Required Stances"] and #req["Required Stances"] > 0) then
or (req["Required Stances"] and #req["Required Stances"] > 0) then


addSectionHeader(root, "Requirements")


if type(req["Required Skills"]) == "table" and #req["Required Skills"] > 0 then
if type(req["Required Skills"]) == "table" and #req["Required Skills"] > 0 then
Line 421: Line 419:
local peRows = passiveEffectRows(rec["Passive Effects"])
local peRows = passiveEffectRows(rec["Passive Effects"])
if #peRows > 0 then
if #peRows > 0 then
addSectionHeader(root, "Passive Effects")
for _, r in ipairs(peRows) do
for _, r in ipairs(peRows) do
addRow(root, r.label, r.value)
addRow(root, r.label, r.value)
Line 433: Line 430:
local statusRem  = formatStatusRemoval(rec["Status Removal"])
local statusRem  = formatStatusRemoval(rec["Status Removal"])
if statusApps or statusRem then
if statusApps or statusRem then
addSectionHeader(root, "Status Effects")
addRow(root, "Applies", statusApps)
addRow(root, "Applies", statusApps)
addRow(root, "Removes", statusRem)
addRow(root, "Removes", statusRem)
Line 443: Line 439:
local modsText = formatModifiers(rec.Modifiers)
local modsText = formatModifiers(rec.Modifiers)
if modsText then
if modsText then
addSectionHeader(root, "Modifiers")
addRow(root, "Flags", modsText)
addRow(root, "Flags", modsText)
end
end
Line 452: Line 447:
local eventsText = formatEvents(rec.Events)
local eventsText = formatEvents(rec.Events)
if eventsText then
if eventsText then
addSectionHeader(root, "Events")
addRow(root, "Triggers", eventsText)
addRow(root, "Triggers", eventsText)
end
end
Line 460: Line 454:
------------------------------------------------------------------
------------------------------------------------------------------
if type(rec.Notes) == "table" and #rec.Notes > 0 then
if type(rec.Notes) == "table" and #rec.Notes > 0 then
addSectionHeader(root, "Notes")
addRow(root, "Notes", asUl(rec.Notes) or table.concat(rec.Notes, "<br />"))
addRow(root, "Notes", asUl(rec.Notes) or table.concat(rec.Notes, "<br />"))
end
end