Okay I gotta hop

This commit is contained in:
Fermi
2019-11-19 12:22:53 +00:00
parent 35c538b412
commit 9fb6c2f3a3
3 changed files with 335 additions and 0 deletions

View File

@@ -0,0 +1,57 @@
<ui-display title='Occupant'>
<ui-section label='Occupant'>
<span>{{data.occupant.name ? data.occupant.name : "No Occupant"}}</span>
</ui-section>
{{#if data.occupied}}
<ui-section label='State'>
<span class='{{data.occupant.statstate}}'>{{data.occupant.stat}}</span>
</ui-section>
<ui-section label='Health'>
<ui-bar min='{{data.occupant.minHealth}}' max='{{data.occupant.maxHealth}}' value='{{data.occupant.health}}'
state='{{data.occupant.health >= 0 ? "good" : "average"}}'>{{Math.round(adata.occupant.health)}}</ui-bar>
</ui-section>
{{#each [{label: "Brute", type: "bruteLoss"}, {label: "Respiratory", type: "oxyLoss"}, {label: "Toxin", type: "toxLoss"}, {label: "Burn", type: "fireLoss"}]}}
<ui-section label='{{label}}'>
<ui-bar min='0' max='{{data.occupant.maxHealth}}' value='{{data.occupant[type]}}' state='bad'>{{Math.round(adata.occupant[type])}}</ui-bar>
</ui-section>
{{/each}}
{{#if data.occupant.blood}}
<ui-section label='Blood'>
<ui-section label='Volume'>
<ui-bar min='0' max='{{data.occupant.blood.maxBloodVolume}}' value='{{data.occupant.blood.currentBloodVolume}}' state='{{data.occupant.blood.currentBloodVolume <= data.occupant.blood.dangerBloodVolume ? "bad" : "good"}}'>{{& data.occupant.blood.currentBloodVolume <= data.occupant.blood.dangerBloodVolume ? "<b>LOW</b>" : "OK"}} - {{Math.round(data.occupant.blood.currentBloodVolume)}} cl</ui-bar>
</ui-section>
<ui-section label='Type'>
<span class='highlight'>{{data.occupant.blood.bloodType}}</span>
</ui-section>
</ui-section>
{{/if}}
<ui-section label='Cells'>
<span class='{{data.occupant.cloneLoss ? "bad" : "good"}}'>{{data.occupant.cloneLoss ? "Damaged" : "Healthy"}}</span>
</ui-section>
<ui-section label='Brain'>
<span class='{{data.occupant.brainLoss ? "bad" : "good"}}'>{{data.occupant.brainLoss ? "Abnormal" : "Healthy"}}</span>
</ui-section>
<ui-section label='Bloodstream'>
{{#each adata.occupant.reagents}}
<span class='highlight' intro-outro='fade'>{{Math.fixed(volume, 1)}} units of {{name}}</span><br/>
{{else}}
<span class='good'>Pure</span>
{{/each}}
</ui-section>
{{/if}}
</ui-display>
<ui-display title='Controls'>
<ui-section label='Door'>
<ui-button icon='{{data.open ? "unlock" : "lock"}}' action='door'>{{data.open ? "Open" : "Closed"}}</ui-button>
</ui-section>
<ui-section label='Inject'>
{{#each data.chems}}
<span>{{name}} </span>
{{if adata.partRating > 3}}
<ui-button icon='transfer' state='{{data.occupied && allowed ? null : "disabled"}}' action='inject' params='{"chem": "{{id}}", "volume": 1}'>1</ui-button>
{{if adata.partRating > 2}}
<ui-button icon='transfer' state='{{data.occupied && allowed ? null : "disabled"}}' action='inject' params='{"chem": "{{id}}", "volume": 5}'>5</ui-button>
<ui-button icon='transfer' state='{{data.occupied && allowed ? null : "disabled"}}' action='inject' params='{"chem": "{{id}}", "volume": 10}'>10</ui-button><br/>
{{/each}}
</ui-section>
</ui-display>