{{#unless (eq @root.source.type 'healing')}}
{{localize "DAGGERHEART.GENERAL.damage"}} {{#if source.main}} {{else}} {{/if}} {{#if source.main}}
{{#if @root.hasBaseDamage}} {{formField @root.fields.damage.fields.main.fields.includeBase value=source.main.includeBase name="damage.main.includeBase" classes="checkbox" localize=true }} {{/if}} {{#unless (eq @root.source.type 'healing')}} {{formField baseFields.main.fields.direct value=source.main.direct name=(concat path "damage.main.direct") localize=true classes="checkbox"}} {{/unless}} {{#if (and @root.isNPC (not (eq path 'system.attack.')))}} {{formField baseFields.main.fields.groupAttack value=source.main.groupAttack name=(concat path "damage.main.groupAttack") localize=true classes="select"}} {{/if}}
{{> damageData damage=source.main fields=fields.main.fields basePath=(concat path "damage.main")}} {{#if horde}} {{> hordeDamage source=source.main fields=fields.main.fields basePath=(concat path "damage.main")}} {{/if}} {{#if (ne @root.source.type 'healing')}} {{formField fields.main.fields.type value=source.main.type name=(concat path "damage.main.type") localize=true}} {{/if}} {{/if}}
{{/unless}} {{#unless (eq path 'system.attack.')}} {{! In the future, consider allowing this even on NPCs}}
{{#if (eq @root.source.type 'healing')}} {{localize "DAGGERHEART.GENERAL.healing"}} {{else}} {{localize "DAGGERHEART.ACTIONS.Config.damage.markResources"}} {{/if}} {{#unless @root.allDamageTypesUsed}}{{/unless}} {{#each source.resources as |dmg key|}}
{{localize (concat "DAGGERHEART.CONFIG.HealingType." dmg.applyTo ".name")}} {{#unless (or dmg.base ../path)}} {{/unless}} {{> damageData damage=dmg fields=../fields.resources.element.fields basePath=(concat ../path "damage.resources." dmg.applyTo)}}
{{/each}} {{/unless}} {{#*inline "formula"}} {{#unless isBase}} {{formField fields.custom.fields.enabled value=source.custom.enabled name=(concat basePath ".custom.enabled") classes="checkbox" localize=true}} {{/unless}} {{#if source.custom.enabled}} {{formField fields.custom.fields.formula value=source.custom.formula name=(concat basePath ".custom.formula") localize=true}} {{else}}
{{#unless @root.isNPC}} {{formField fields.multiplier value=source.multiplier name=(concat basePath ".multiplier") localize=true}} {{/unless}} {{#if (eq source.multiplier 'flat')}}{{formField fields.flatMultiplier value=source.flatMultiplier name=(concat basePath ".flatMultiplier") localize=true }}{{/if}} {{formField fields.dice value=source.dice name=(concat basePath ".dice") localize=true}} {{formField fields.bonus value=source.bonus name=(concat basePath ".bonus") localize=true}}
{{/if}} {{#if @root.isNPC}} {{/if}} {{/inline}} {{#*inline "damageData"}} {{#if (and (not @root.isNPC) @root.hasRoll (not damage.base))}} {{formField fields.resultBased value=damage.resultBased name=(concat basePath ".resultBased") localize=true classes="checkbox"}} {{/if}} {{#if (and (not @root.isNPC) @root.hasRoll (not damage.base) damage.resultBased)}}
{{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.hope")}} {{> formula key=damage.applyTo fields=fields.value.fields type=fields.type isBase=damage.base source=damage.value basePath=(concat basePath ".value")}}
{{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.fear")}} {{> formula key=damage.applyTo fields=fields.valueAlt.fields type=fields.type isBase=damage.base source=damage.valueAlt basePath=(concat basePath ".valueAlt")}}
{{else}} {{> formula key=damage.applyTo fields=fields.value.fields type=fields.type isBase=damage.base source=damage.value basePath=(concat basePath ".value")}} {{/if}} {{/inline}} {{#*inline "hordeDamage"}}
{{localize "DAGGERHEART.ACTORS.Adversary.hordeDamage"}}
{{formField fields.valueAlt.fields.flatMultiplier value=source.valueAlt.flatMultiplier name=(concat basePath ".valueAlt.flatMultiplier") label="DAGGERHEART.ACTIONS.Settings.multiplier" classes="inline-child" localize=true }} {{formField fields.valueAlt.fields.dice value=source.valueAlt.dice name=(concat basePath ".valueAlt.dice") classes="inline-child" localize=true}} {{formField fields.valueAlt.fields.bonus value=source.valueAlt.bonus name=(concat basePath ".valueAlt.bonus") localize=true classes="inline-child"}}
{{/inline}}