mirror of
https://github.com/Foundryborne/daggerheart.git
synced 2026-07-21 18:09:54 +02:00
Cleaned up uses of 'mode' for activeEffects in configs (#2076)
This commit is contained in:
parent
2c98070836
commit
c6411ef0fe
4 changed files with 315 additions and 260 deletions
|
|
@ -315,15 +315,15 @@ export default class BeastformDialog extends HandlebarsApplicationMixin(Applicat
|
|||
|
||||
const beastformEffect = selected.effects.find(x => x.type === 'beastform');
|
||||
for (const traitBonus of app.modifications.traitBonuses) {
|
||||
const existingChange = beastformEffect.changes.find(
|
||||
const existingChange = beastformEffect.system.changes.find(
|
||||
x => x.key === `system.traits.${traitBonus.trait}.value`
|
||||
);
|
||||
if (existingChange) {
|
||||
existingChange.value = Number.parseInt(existingChange.value) + traitBonus.bonus;
|
||||
} else {
|
||||
beastformEffect.changes.push({
|
||||
beastformEffect.system.changes.push({
|
||||
key: `system.traits.${traitBonus.trait}.value`,
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
priority: null,
|
||||
value: traitBonus.bonus
|
||||
});
|
||||
|
|
|
|||
|
|
@ -139,14 +139,16 @@ export default class DhDeathMove extends HandlebarsApplicationMixin(ApplicationV
|
|||
name: game.i18n.localize('DAGGERHEART.CONFIG.DeathMoves.blazeOfGlory.name'),
|
||||
description: game.i18n.localize('DAGGERHEART.CONFIG.DeathMoves.blazeOfGlory.description'),
|
||||
img: CONFIG.DH.GENERAL.deathMoves.blazeOfGlory.img,
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.rules.roll.guaranteedCritical',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: 'true'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]);
|
||||
|
||||
await this.actor.setDeathMoveDefeated(CONFIG.DH.GENERAL.defeatedConditionChoices.dead.id);
|
||||
|
|
|
|||
|
|
@ -90,19 +90,21 @@ export const BPModifiers = {
|
|||
name: 'DAGGERHEART.CONFIG.BPModifiers.increaseDamage.effect.name',
|
||||
description: 'DAGGERHEART.CONFIG.BPModifiers.increaseDamage.effect.description',
|
||||
img: 'icons/magic/control/buff-flight-wings-red.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.physical.dice',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1d4'
|
||||
},
|
||||
{
|
||||
key: 'system.bonuses.damage.magical.dice',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1d4'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
},
|
||||
|
|
|
|||
|
|
@ -37,14 +37,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.channeling.effects.channeling.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.channeling.effects.channeling.description',
|
||||
img: 'icons/magic/symbols/rune-sigil-horned-blue.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.roll.spellcast',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
difficult: {
|
||||
|
|
@ -55,44 +57,46 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.difficult.effects.difficult.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.difficult.effects.difficult.description',
|
||||
img: 'icons/magic/control/buff-flight-wings-red.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.traits.agility.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.strength.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.finesse.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.instinct.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.presence.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.knowledge.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
flexible: {
|
||||
|
|
@ -103,14 +107,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.flexible.effects.flexible.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.flexible.effects.flexible.description',
|
||||
img: 'icons/magic/movement/abstract-ribbons-red-orange.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
fortified: {
|
||||
|
|
@ -121,14 +127,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.fortified.effects.fortified.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.fortified.effects.fortified.description',
|
||||
img: 'icons/magic/defensive/shield-barrier-glowing-blue.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.rules.damageReduction.increasePerArmorMark',
|
||||
mode: 5,
|
||||
type: 'override',
|
||||
value: '2'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
gilded: {
|
||||
|
|
@ -139,14 +147,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.gilded.effects.gilded.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.gilded.effects.gilded.description',
|
||||
img: 'icons/magic/control/control-influence-crown-gold.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.traits.presence.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
heavy: {
|
||||
|
|
@ -157,14 +167,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.heavy.effects.heavy.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.heavy.effects.heavy.description',
|
||||
img: 'icons/commodities/metal/ingot-worn-iron.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
hopeful: {
|
||||
|
|
@ -212,14 +224,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.magical.effects.magical.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.magical.effects.magical.description',
|
||||
img: 'icons/magic/defensive/barrier-shield-dome-blue-purple.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.rules.damageReduction.magical',
|
||||
mode: 5,
|
||||
type: 'override',
|
||||
value: 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
painful: {
|
||||
|
|
@ -249,14 +263,16 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.physical.effects.physical.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.physical.effects.physical.description',
|
||||
img: 'icons/commodities/stone/ore-pile-tan.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.rules.damageReduction.physical',
|
||||
mode: 5,
|
||||
type: 'override',
|
||||
value: 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
quiet: {
|
||||
|
|
@ -280,19 +296,21 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.reinforced.effects.reinforced.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.reinforced.effects.reinforced.description',
|
||||
img: 'icons/magic/defensive/shield-barrier-glowing-triangle-green.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bunuses.damageThresholds.major',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '2'
|
||||
},
|
||||
{
|
||||
key: 'system.bunuses.damageThresholds.severe',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '2'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
resilient: {
|
||||
|
|
@ -326,19 +344,21 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.sharp.effects.sharp.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.sharp.effects.sharp.description',
|
||||
img: 'icons/magic/defensive/shield-barrier-glowing-triangle-green.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.primaryWeapon.dice',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1d4'
|
||||
},
|
||||
{
|
||||
key: 'system.bonuses.damage.secondaryWeapon.dice',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1d4'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
shifting: {
|
||||
|
|
@ -408,19 +428,21 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.veryHeavy.effects.veryHeavy.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.veryHeavy.effects.veryHeavy.description',
|
||||
img: 'icons/commodities/metal/ingot-stamped-steel.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-2'
|
||||
},
|
||||
{
|
||||
key: 'system.traits.agility.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
warded: {
|
||||
|
|
@ -431,15 +453,17 @@ export const armorFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.ArmorFeature.warded.effects.warded.name',
|
||||
description: 'DAGGERHEART.CONFIG.ArmorFeature.warded.effects.warded.description',
|
||||
img: 'icons/magic/defensive/barrier-shield-dome-pink.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.resistance.magical.reduction',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '@system.armorScore',
|
||||
priority: 21
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
};
|
||||
|
|
@ -488,10 +512,11 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.barrier.effects.barrier.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.barrier.effects.barrier.description',
|
||||
img: 'icons/skills/melee/shield-block-bash-blue.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
|
|
@ -504,6 +529,7 @@ export const weaponFeatures = {
|
|||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
bonded: {
|
||||
|
|
@ -514,14 +540,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.bonded.effects.damage.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.bonded.effects.damage.description',
|
||||
img: 'icons/magic/symbols/chevron-elipse-circle-blue.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.primaryWeapon.bonus',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '@system.levelData.level.current'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
bouncing: {
|
||||
|
|
@ -553,19 +581,21 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.brave.effects.brave.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.brave.effects.brave.description',
|
||||
img: 'icons/magic/life/heart-cross-strong-flame-purple-orange.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
},
|
||||
{
|
||||
key: 'system.damageThresholds.severe',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: 'ITEM.@system.tier'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
brutal: {
|
||||
|
|
@ -618,14 +648,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.charged.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.charged.description',
|
||||
img: 'icons/magic/lightning/claws-unarmed-strike-teal.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.proficiency',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
@ -660,14 +692,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.cumbersome.effects.cumbersome.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.cumbersome.effects.cumbersome.description',
|
||||
img: 'icons/commodities/metal/mail-plate-steel.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.traits.finesse.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
deadly: {
|
||||
|
|
@ -707,15 +741,17 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.deflecting.effects.deflecting.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.deflecting.effects.deflecting.description',
|
||||
img: 'icons/skills/melee/hand-grip-sword-strike-orange.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '@system.armorScore',
|
||||
priority: 21
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
@ -754,14 +790,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.destructive.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.destructive.effects.agility',
|
||||
img: 'icons/skills/melee/strike-flail-spiked-pink.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.traits.agility.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
devastating: {
|
||||
|
|
@ -795,7 +833,7 @@ export const weaponFeatures = {
|
|||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.primaryWeapon.bonus',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
],
|
||||
|
|
@ -902,14 +940,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.greedy.actions.greed.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.greedy.actions.greed.description',
|
||||
img: 'icons/commodities/currency/coins-crown-stack-gold.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.proficiency',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
@ -951,14 +991,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.heavy.effects.heavy.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.heavy.effects.heavy.description',
|
||||
img: 'icons/commodities/metal/ingot-worn-iron.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
hooked: {
|
||||
|
|
@ -1066,14 +1108,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.massive.effects.massive.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.massive.effects.massive.description',
|
||||
img: 'icons/skills/melee/strike-flail-destructive-yellow.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.evasion',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '-1'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
painful: {
|
||||
|
|
@ -1107,7 +1151,7 @@ export const weaponFeatures = {
|
|||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.primaryWeapon.bonus',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: 'ITEM.@system.tier + 1'
|
||||
}
|
||||
],
|
||||
|
|
@ -1158,14 +1202,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.persuasive.effects.persuasive.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.persuasive.effects.persuasive.description',
|
||||
img: 'icons/magic/control/hypnosis-mesmerism-eye.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.traits.presence.value',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '2'
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
]
|
||||
|
|
@ -1203,6 +1249,7 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.protective.effects.protective.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.protective.effects.protective.description',
|
||||
img: 'icons/skills/melee/shield-block-gray-orange.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'Armor',
|
||||
|
|
@ -1215,6 +1262,8 @@ export const weaponFeatures = {
|
|||
}
|
||||
]
|
||||
}
|
||||
|
||||
}
|
||||
]
|
||||
},
|
||||
quick: {
|
||||
|
|
@ -1244,14 +1293,16 @@ export const weaponFeatures = {
|
|||
name: 'DAGGERHEART.CONFIG.WeaponFeature.reliable.effects.reliable.name',
|
||||
description: 'DAGGERHEART.CONFIG.WeaponFeature.reliable.effects.reliable.description',
|
||||
img: 'icons/skills/melee/strike-sword-slashing-red.webp',
|
||||
system: {
|
||||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.roll.primaryWeapon.bonus',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: 1
|
||||
}
|
||||
]
|
||||
}
|
||||
}
|
||||
]
|
||||
},
|
||||
reloading: {
|
||||
|
|
@ -1341,7 +1392,7 @@ export const weaponFeatures = {
|
|||
changes: [
|
||||
{
|
||||
key: 'system.bonuses.damage.primaryWeapon.bonus',
|
||||
mode: 2,
|
||||
type: 'add',
|
||||
value: '@system.traits.agility.value',
|
||||
priority: 21
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue