Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DES: Fixed XML creation #958

Merged
merged 1 commit into from
Nov 2, 2024
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
46 changes: 23 additions & 23 deletions src/playercards/cards/DreamEnhancingSerum.ttslua
Original file line number Diff line number Diff line change
@@ -1,10 +1,10 @@
require("playercards/CardsWithHelper")
local playermatApi = require("playermat/PlayermatApi")
local playermatApi = require("playermat/PlayermatApi")
local matColor, handColor, loopId

-- intentionally global
hasXML = true
isHelperEnabled = false
hasXML = true
isHelperEnabled = false

function updateSave()
self.script_state = JSON.encode({ isHelperEnabled = isHelperEnabled, loopId = loopId })
Expand All @@ -17,10 +17,10 @@ function onLoad(savedData)
loopId = loadedData.loopId
end
updateColors()

createHelperXML()

if isHelperEnabled then
updateDisplay()
createHelperXML()
end
end

Expand Down Expand Up @@ -53,7 +53,7 @@ function createHelperXML()
children = { {
tag = "Panel",
attributes = {
preferredHeight="300"
preferredHeight = "300"
},
children = { {
tag = "Text",
Expand All @@ -63,26 +63,26 @@ function createHelperXML()
font = "font_teutonic-arkham",
fontsize = "200"
}
}}
} }
},
{
tag = "Panel",
attributes = {
preferredHeight="900"
},
children = { {
tag = "Text",
{
tag = "Panel",
attributes = {
id = "Count",
fontSize = "700",
scale = "2.2 2.2 1",
color = "Green",
font = "font_teutonic-arkham",
text = 0
}
}}
preferredHeight = "900"
},
children = { {
tag = "Text",
attributes = {
id = "Count",
fontSize = "700",
scale = "2.2 2.2 1",
color = "Green",
font = "font_teutonic-arkham",
text = 0
}
} }
}
}
}
} }
self.UI.setXmlTable(xmlTable)
end
Expand Down
Loading