Update character PDF and library: add inventory page with coin breakdown, item details, and new functions for inventory processing; update character data with inventory variables and calculations
This commit is contained in:
parent
46b9ba81ac
commit
f93b44cb4b
@ -248,6 +248,19 @@
|
||||
<Group Name="print">
|
||||
<Variables>
|
||||
<Bool Name="preprintcheck"/>
|
||||
<Int Name="borderp2"/>
|
||||
<Int Name="borderp1"/>
|
||||
<Int Name="borderp0"/>
|
||||
<Int Name="borderm1"/>
|
||||
<Int Name="borderm2"/>
|
||||
<Int Name="borderm3"/>
|
||||
<List Name="maininventory">
|
||||
<Variables>
|
||||
<Int Name="slotindex"/>
|
||||
<String Name="aw"/>
|
||||
<String Name="gs"/>
|
||||
</Variables>
|
||||
</List>
|
||||
</Variables>
|
||||
</Group>
|
||||
</Groups>
|
||||
|
||||
@ -136,5 +136,98 @@
|
||||
<Function Name="charlib_swords_pa">
|
||||
<Return>[data.character.fight.swords] / 2 + charlib_fightagilityadd()</Return>
|
||||
</Function>
|
||||
|
||||
<Function Name="charlib_maininv_aw">
|
||||
<Actions>
|
||||
<Action>
|
||||
<Do>"X"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderm3]</If>
|
||||
<Do>"-3"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderm2]</If>
|
||||
<Do>"-2"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderm1]</If>
|
||||
<Do>"-1"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderp0]</If>
|
||||
<Do>"0"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderp1]</If>
|
||||
<Do>"+1"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderp2]</If>
|
||||
<Do>"+2"</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
</Actions>
|
||||
<Return>[local.aw]</Return>
|
||||
</Function>
|
||||
<Function Name="charlib_maininv_gs">
|
||||
<Actions>
|
||||
<Action>
|
||||
<Do>"X"</Do>
|
||||
<Output>[local.gs]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderm3]</If>
|
||||
<Do>"-1"</Do>
|
||||
<Output>[local.gs]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderm1]</If>
|
||||
<Do>"0"</Do>
|
||||
<Output>[local.gs]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<If>[param.0] <= [data.character.print.borderp2]</If>
|
||||
<Do>"+1"</Do>
|
||||
<Output>[local.gs]</Output>
|
||||
</Action>
|
||||
</Actions>
|
||||
<Return>[local.gs]</Return>
|
||||
</Function>
|
||||
<Function Name="charlib_maininv">
|
||||
<Actions>
|
||||
<Action>
|
||||
<Do>charlib_maininv_gs([param.0])</Do>
|
||||
<Output>[local.gs]</Output>
|
||||
</Action>
|
||||
<Action>
|
||||
<Do>charlib_maininv_aw([param.0])</Do>
|
||||
<Output>[local.aw]</Output>
|
||||
</Action>
|
||||
<AddListEntry>
|
||||
<List>[data.character.print.maininventory]</List>
|
||||
<PropertyOutputs>
|
||||
<PropertyOutput>
|
||||
<Property>[local.gs]</Property>
|
||||
<Output>[gs]</Output>
|
||||
</PropertyOutput>
|
||||
<PropertyOutput>
|
||||
<Property>[local.aw]</Property>
|
||||
<Output>[aw]</Output>
|
||||
</PropertyOutput>
|
||||
<PropertyOutput>
|
||||
<Property>[param.0]</Property>
|
||||
<Output>[slotindex]</Output>
|
||||
</PropertyOutput>
|
||||
</PropertyOutputs>
|
||||
</AddListEntry>
|
||||
</Actions>
|
||||
</Function>
|
||||
</Functions>
|
||||
</Library>
|
||||
@ -4521,5 +4521,180 @@
|
||||
</ColumnLayout>
|
||||
</Body>
|
||||
</Page>
|
||||
<Page>
|
||||
<Header>
|
||||
<RowLayout>
|
||||
<Content>
|
||||
<Label Styles="HeaderItem;Italic">
|
||||
<Text>"Heldenbogen"</Text>
|
||||
</Label>
|
||||
<Label Styles="HeaderItem">
|
||||
<Text>"-"</Text>
|
||||
</Label>
|
||||
<Label Styles="HeaderItem">
|
||||
<Text>[data.character.definition.name]</Text>
|
||||
</Label>
|
||||
<Label Styles="HeaderItem">
|
||||
<Text>"-"</Text>
|
||||
</Label>
|
||||
<Label Styles="HeaderItem;Bold">
|
||||
<Text>"Ausrüstung"</Text>
|
||||
</Label>
|
||||
</Content>
|
||||
</RowLayout>
|
||||
</Header>
|
||||
<Body>
|
||||
<RowLayout Styles="Page">
|
||||
<Content>
|
||||
|
||||
<!-- Left Inventory -->
|
||||
<ColumnLayout>
|
||||
<Content>
|
||||
|
||||
<!-- Money -->
|
||||
<TableLayout Styles="TableChildren">
|
||||
<Columns>
|
||||
<Column>
|
||||
<Width>40</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
<Column>
|
||||
<Width>30</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
<Column>
|
||||
<Width>30</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
</Columns>
|
||||
<Content>
|
||||
|
||||
|
||||
<Label Styles="TalentTableHeader">
|
||||
<Text>"Münze"</Text>
|
||||
</Label>
|
||||
<Label Styles="TalentTableHeader">
|
||||
<Text>"Aktuell"</Text>
|
||||
</Label>
|
||||
<Label Styles="TalentTableHeader">
|
||||
<Text>"Start"</Text>
|
||||
</Label>
|
||||
|
||||
|
||||
<Label Styles="HLeft">
|
||||
<Text>"Dukaten"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>""</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>Trunc([data.character.control.coins] / 1000)</Text>
|
||||
</Label>
|
||||
|
||||
|
||||
<Label Styles="HLeft">
|
||||
<Text>"Silber"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>""</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>Trunc(([data.character.control.coins] % 1000) / 100)</Text>
|
||||
</Label>
|
||||
|
||||
|
||||
<Label Styles="HLeft">
|
||||
<Text>"Heller"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>""</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>Trunc(([data.character.control.coins] % 100) / 10)</Text>
|
||||
</Label>
|
||||
|
||||
|
||||
<Label Styles="HLeft">
|
||||
<Text>"Kreuzer"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>""</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>Trunc(([data.character.control.coins] % 10))</Text>
|
||||
</Label>
|
||||
|
||||
|
||||
</Content>
|
||||
</TableLayout>
|
||||
|
||||
|
||||
<TableLayout>
|
||||
<Columns>
|
||||
<Column>
|
||||
<Width>15</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
<Column>
|
||||
<Width>15</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
<Column>
|
||||
<Width>15</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
<Column>
|
||||
<Width>55</Width>
|
||||
<Percent>true</Percent>
|
||||
</Column>
|
||||
</Columns>
|
||||
<Content>
|
||||
|
||||
<Label>
|
||||
<Text>"AW"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>"GS"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>"Slot"</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>"Gegenstand"</Text>
|
||||
</Label>
|
||||
|
||||
<Foreach>
|
||||
<List>[data.character.print.maininventory]</List>
|
||||
<Content>
|
||||
<Label>
|
||||
<Text>[aw]</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>[gs]</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>[slotindex]</Text>
|
||||
</Label>
|
||||
<Label>
|
||||
<Text>""</Text>
|
||||
</Label>
|
||||
</Content>
|
||||
</Foreach>
|
||||
</Content>
|
||||
</TableLayout>
|
||||
|
||||
</Content>
|
||||
</ColumnLayout>
|
||||
|
||||
<!-- Right Inventory -->
|
||||
<ColumnLayout>
|
||||
<Content>
|
||||
<Label><Text>"Hier könnte ihre Werbung stehen!"</Text></Label>
|
||||
</Content>
|
||||
</ColumnLayout>
|
||||
</Content>
|
||||
</RowLayout>
|
||||
</Body>
|
||||
</Page>
|
||||
</Pages>
|
||||
</Pdf>
|
||||
@ -4715,10 +4715,21 @@
|
||||
</Page>
|
||||
<Page Name="print">
|
||||
<OnOpen>
|
||||
<!-- Pre Print Checks -->
|
||||
<Action>
|
||||
<Do>charlib_checkpreprint() and charlibcreate_checkpreprint()</Do>
|
||||
<Output>[data.character.print.preprintcheck]</Output>
|
||||
</Action>
|
||||
|
||||
<!-- Print Calculations -->
|
||||
<ForLoop>
|
||||
<LoopCount>20</LoopCount>
|
||||
<Loop>
|
||||
<Action>
|
||||
<Do>charlib_maininv([param.loop])</Do>
|
||||
</Action>
|
||||
</Loop>
|
||||
</ForLoop>
|
||||
</OnOpen>
|
||||
<Content>
|
||||
<Button>
|
||||
|
||||
Loading…
Reference in New Issue
Block a user