Skip to content
Merged
Show file tree
Hide file tree
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
1 change: 1 addition & 0 deletions module/applications/sheets-configs/adversary-settings.mjs
Original file line number Diff line number Diff line change
Expand Up @@ -139,6 +139,7 @@ export default class DHAdversarySettings extends DHBaseActorSettings {
// Filter out data that is not configurable for colossi
// These still exist under the hood, but its more user friendly to exclude
if (this.actor.system.typeData?.type === 'colossus') {
context.isColossus = true;
const role = this.actor.system.typeData.role;
context.resources = context.resources.filter(r => role === 'framework' ? r.key !== 'hitPoints' : r.key !== 'stress');
}
Expand Down
38 changes: 20 additions & 18 deletions templates/sheets-settings/adversary-settings/colossus.hbs
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
data-tab='{{tabs.colossus.id}}'
data-group='{{tabs.colossus.group}}'
>
{{#if isColossus}}
{{#if (eq colossus.role "framework")}}
<fieldset class="colossus-parts">
<legend>{{localize "DAGGERHEART.ACTORS.Adversary.colossus.FIELDS.parts.label"}}</legend>
Expand Down Expand Up @@ -33,23 +34,24 @@
</div>
</fieldset>
{{else}}
<fieldset>
<legend>{{localize "DAGGERHEART.ACTORS.Adversary.colossus.FIELDS.frameworkUuid.label"}}</legend>
<div class="framework">
{{#if colossus.framework.actor}}
<img class="portrait" src="{{colossus.framework.actor.img}}" />
<a class="name" data-action="editDoc" data-item-uuid="{{colossus.framework.actor.uuid}}">{{colossus.framework.actor.name}}</a>
{{#unless colossus.framework.linked}}
<span data-tooltip aria-label="DAGGERHEART.ACTORS.Adversary.colossus.Notifications.FrameworkNotLinked">
<i class="fa-solid fa-warning" inert></i>
</span>
{{/unless}}
{{else}}
<i class="fa-solid fa-link-slash image-icon portrait" inert></i>
<span class="name">{{localize "DAGGERHEART.GENERAL.missingX" x=(localize "DOCUMENT.Actor")}}</span>
{{/if}}
</div>
</fieldset>
{{formGroup systemFields.typeData.types.colossus.fields.adjacentParts name="system.typeData.adjacentParts" value=document._source.system.typeData.adjacentParts localize=true }}
<fieldset>
<legend>{{localize "DAGGERHEART.ACTORS.Adversary.colossus.FIELDS.frameworkUuid.label"}}</legend>
<div class="framework">
{{#if colossus.framework.actor}}
<img class="portrait" src="{{colossus.framework.actor.img}}" />
<a class="name" data-action="editDoc" data-item-uuid="{{colossus.framework.actor.uuid}}">{{colossus.framework.actor.name}}</a>
{{#unless colossus.framework.linked}}
<span data-tooltip aria-label="DAGGERHEART.ACTORS.Adversary.colossus.Notifications.FrameworkNotLinked">
<i class="fa-solid fa-warning" inert></i>
</span>
{{/unless}}
{{else}}
<i class="fa-solid fa-link-slash image-icon portrait" inert></i>
<span class="name">{{localize "DAGGERHEART.GENERAL.missingX" x=(localize "DOCUMENT.Actor")}}</span>
{{/if}}
</div>
</fieldset>
{{formGroup systemFields.typeData.types.colossus.fields.adjacentParts name="system.typeData.adjacentParts" value=document._source.system.typeData.adjacentParts localize=true }}
{{/if}}
{{/if}}
</section>
Loading