small updates

This commit is contained in:
dscarpac 2024-02-14 13:01:08 -06:00
parent 2ee32e58f5
commit 73fa890eb2
3 changed files with 35 additions and 23 deletions

View File

@ -16,10 +16,6 @@ function onLoad(savedData)
self.addContextMenuItem("Clear Helper", deleteButtons)
end
else
self.UI.hide("active_bless")
self.UI.hide("inactive_bless")
self.UI.hide("inactive_curse")
self.UI.hide("active_curse")
self.addContextMenuItem("Enable Helper", createButtons)
end
end
@ -40,6 +36,8 @@ end
function createButtons()
self.clearContextMenu()
self.addContextMenuItem("Clear Helper", deleteButtons)
self.UI.setAttribute("inactives", "active", true)
self.UI.setAttribute("actives", "active", true)
currentState = "Empty"
loopId = Wait.time(countBlessCurse, 1, -1)
end
@ -59,7 +57,7 @@ function resolveBless()
end
function countBlessCurse()
-- count tokens in the bag and show appropriate button
-- count tokens in the bag and show appropriate buttons
numInBag = { Bless = 0, Curse = 0 }
local chaosBag = chaosBagApi.findChaosBag()
local tokens = {}

View File

@ -1,27 +1,41 @@
<Panel
position="0 -50 -22"
rotation="0 0 180"
height="900" width="1400"
scale="0.1 0.1 1" active="true">
<TableLayout cellSpacing="80" cellBackgroundColor="rgba(1,1,1,0)">
<Row><Cell>
position="0 -50 -22"
rotation="0 0 180"
height="900" width="1400"
scale="0.1 0.1 1">
<TableLayout id="actives" active="false" cellSpacing="80" cellBackgroundColor="rgba(1,1,1,0)">
<Row>
<Cell>
<Button id="active_bless" padding="50 50 50 50" icon="bless" iconWidth="400" font="font_teutonic-arkham" fontSize="300" textColor="White"
onClick="resolveBless" color="#9D702CE6" iconAlignment="Right">Resolve</Button></Cell></Row>
<Row><Cell>
onClick="resolveBless" color="#9D702CE6" iconAlignment="Right">Resolve</Button>
</Cell>
</Row>
<Row>
<Cell>
<Button id="active_curse" padding="50 50 50 50" icon="curse" iconWidth="400" font="font_teutonic-arkham" fontSize="300" textColor="White"
onClick="resolveCurse" color="#37232FE6" iconAlignment="Right">Resolve</Button></Cell></Row></TableLayout>
onClick="resolveCurse" color="#37232FE6" iconAlignment="Right">Resolve</Button>
</Cell>
</Row>
</TableLayout>
</Panel>
<Panel
position="0 -50 -22"
rotation="0 0 180"
height="900" width="1400"
scale="0.1 0.1 1" active="true">
<TableLayout cellSpacing="80" cellBackgroundColor="rgba(1,1,1,0)">
<Row><Cell>
position="0 -50 -22"
rotation="0 0 180"
height="900" width="1400"
scale="0.1 0.1 1">
<TableLayout id="inactives" active="false" cellSpacing="80" cellBackgroundColor="rgba(1,1,1,0)">
<Row>
<Cell>
<Button id="inactive_bless" padding="50 50 50 50" icon="bless" iconWidth="400" font="font_teutonic-arkham" fontSize="300" textColor="#A0A0A0"
color="#5C5C5CE6" iconAlignment="Right">Resolve</Button></Cell></Row>
<Row><Cell>
color="#5C5C5CE6" iconAlignment="Right">Resolve</Button>
</Cell>
</Row>
<Row>
<Cell>
<Button id="inactive_curse" padding="50 50 50 50" icon="curse" iconWidth="400" font="font_teutonic-arkham" fontSize="300" textColor="#A0A0A0"
color="#353535E6" iconAlignment="Right">Resolve</Button></Cell></Row></TableLayout>
color="#353535E6" iconAlignment="Right">Resolve</Button>
</Cell>
</Row>
</TableLayout>
</Panel>