diff --git a/.editorconfig b/.editorconfig index 6cfef2fc..8bbc2b52 100644 --- a/.editorconfig +++ b/.editorconfig @@ -1,5 +1,3 @@ [*] indent_size = 4 indent_style = spaces -[*.yml] -indent_size = 2 diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml deleted file mode 100644 index fd9b922e..00000000 --- a/.github/workflows/ci.yml +++ /dev/null @@ -1,42 +0,0 @@ -name: Project CI - -on: - pull_request: - branches: [main] - push: - branches: [main] - workflow_dispatch: - branches: [main] - -jobs: - build: - runs-on: ubuntu-latest - - strategy: - matrix: - node-version: [24.x] - - steps: - - uses: actions/checkout@v4 - - - uses: actions/setup-node@v4 - with: - node-version: ${{ matrix.node-version }} - - - uses: pnpm/action-setup@v4 - with: - version: 10 - - - name: Cache NPM Deps - id: cache-npm - uses: actions/cache@v3 - with: - path: node_modules/ - key: npm-${{ hashFiles('package-lock.json') }} - - - name: Install NPM Deps - if: ${{ steps.cache-npm.outputs.cache-hit != 'true' }} - run: npm ci - - - name: Lint - run: npm run lint \ No newline at end of file diff --git a/.github/workflows/deploy.yml b/.github/workflows/deploy.yml index 553a1a17..e245c7fa 100644 --- a/.github/workflows/deploy.yml +++ b/.github/workflows/deploy.yml @@ -35,7 +35,7 @@ jobs: env: version: ${{steps.get_version.outputs.version-without-v}} url: https://github.com/${{github.repository}} - manifest: https://raw.githubusercontent.com/${{github.repository}}/v14/system.json + manifest: https://raw.githubusercontent.com/${{github.repository}}/main/system.json download: https://github.com/${{github.repository}}/releases/download/${{github.event.release.tag_name}}/system.zip # Create a zip file with all files required by the module to add to the release diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 261c26bd..b9099005 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -1,9 +1,78 @@ -# Contributing to Daggerheart +# Contributing to Foundryborne -Thank you for your interest in contributing to the Foundryborne project! +Welcome! This is a community-driven project to bring [Daggerheart](https://www.daggerheart.com/) to [FoundryVTT](https://foundryvtt.com/) as a full system. We're excited to have you here and appreciate your interest in contributing. -To ensure that all contributions align with our project goals and architectural standards, we ask that you **do not submit outside contributions without first receiving feedback from the development team.** +--- -If you have an idea or a fix you'd like to contribute, please start a discussion or open an issue first. We'd love to hear from you and collaborate on the best way to move forward! +## 🀝 How to Contribute -Thank you for your understanding and support. +We welcome contributions of all kinds: + +- Bug reports +- Feature suggestions +- Code contributions +- UI/UX mockups +- Documentation improvements +- Questions and discussions + +Please be respectful and collaborative β€” we’re all here to build something great together. + +### Community Translations + +Please note that we are not accepting community translations in the main project. Instead, community translations should be published as a module. + +--- + +## 🧭 General Guidelines + +- **Use GitHub Issues** to report bugs or propose features +- **Start a Discussion** for larger ideas or questions +- **Open a Pull Request** once you've confirmed your work aligns with project direction +- **Keep things modular and maintainable** β€” if you're not sure how to structure something, ask! +- **Orient your code on existing examples**, and feel free to suggest a standard if it makes things clearer + +--- + +## πŸ—‚οΈ Project Structure + +Please try to follow the general logic of the existing code when submitting PRs. + +We encourage contributors to leave comments or open Discussions when proposing structural or organizational changes. + +--- + +## 🧾 Issue & PR Best Practices + +**For Issues:** + +- Use clear, descriptive titles +- Provide a concise explanation of the problem or idea +- Include reproduction steps or example scenarios if it's a bug +- Add screenshots or logs if helpful + +**For Pull Requests:** + +- Use a clear title summarizing the change +- Provide a brief description of what your code does and why +- Link to any related Issues +- Keep PRs focused β€” smaller is better + +--- + +## πŸ”– Labels and Boards + +We use GitHub labels to help organize contributions. If your issue or PR relates to a specific category, feel free to tag it. There is also a GitHub Project Board to help track active work and priorities. + +--- + +## πŸ“£ Communication + +Discussions are currently happening on GitHub β€” in Issues, PRs, and [GitHub Discussions](https://github.com/Foundryborne/daggerheart/discussions). You're welcome to use any of these, though we may consolidate to one in the future. + +--- + +## πŸ€— Thank You! + +Whether you're fixing a typo or designing entire mechanics β€” every contribution matters. Thank you for helping bring _Daggerheart_ to life in FoundryVTT through **Foundryborne**! + +πŸΈπŸ› οΈ diff --git a/daggerheart.mjs b/daggerheart.mjs index e25f1b09..240d8704 100644 --- a/daggerheart.mjs +++ b/daggerheart.mjs @@ -32,11 +32,6 @@ CONFIG.Dice.daggerheart = { FateRoll: FateRoll }; -CONFIG.RegionBehavior.dataModels = { - ...CONFIG.RegionBehavior.dataModels, - ...data.regionBehaviors -}; - Object.assign(CONFIG.Dice.termTypes, dice.diceTypes); CONFIG.Actor.documentClass = documents.DhpActor; @@ -348,20 +343,7 @@ Hooks.on(CONFIG.DH.HOOKS.hooksConfig.tagTeamStart, async data => { } }); -Hooks.on(CONFIG.DH.HOOKS.hooksConfig.groupRollStart, async data => { - if (data.openForAllPlayers && data.partyId) { - const party = game.actors.get(data.partyId); - if (!party) return; - - const dialog = new game.system.api.applications.dialogs.GroupRollDialog(party); - dialog.tabGroups.application = 'groupRoll'; - await dialog.render({ force: true }); - } -}); - const updateActorsRangeDependentEffects = async token => { - if (!token) return; - const rangeMeasurement = game.settings.get( CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.variantRules diff --git a/eslint.config.mjs b/eslint.config.mjs deleted file mode 100644 index ce2bb86f..00000000 --- a/eslint.config.mjs +++ /dev/null @@ -1,14 +0,0 @@ -import globals from 'globals'; -import { defineConfig } from 'eslint/config'; -import prettier from 'eslint-plugin-prettier'; - -export default defineConfig([ - { files: ['**/*.{js,mjs,cjs}'], languageOptions: { globals: globals.browser } }, - { plugins: { prettier } }, - { - files: ['**/*.{js,mjs,cjs}'], - rules: { - 'prettier/prettier': 'error' - } - } -]); diff --git a/lang/en.json b/lang/en.json index 2efd6d7b..d19dfb58 100755 --- a/lang/en.json +++ b/lang/en.json @@ -74,7 +74,9 @@ "name": "Summon", "tooltip": "Create tokens in the scene.", "error": "You do not have permission to summon tokens or there is no active scene.", - "invalidDrop": "You can only drop Actor entities to summon." + "invalidDrop": "You can only drop Actor entities to summon.", + "chatMessageTitle": "Test2", + "chatMessageHeaderTitle": "Summoning" }, "transform": { "name": "Transform", @@ -109,18 +111,11 @@ "customFormula": "Custom Formula", "formula": "Formula" }, - "area": { - "sectionTitle": "Areas", - "shape": "Shape", - "size": "Size" - }, "displayInChat": "Display in chat", "deleteTriggerTitle": "Delete Trigger", "deleteTriggerContent": "Are you sure you want to delete the {trigger} trigger?", "advantageState": "Advantage State", - "damageOnSave": "Damage on Save", - "useDefaultItemValues": "Use default Item values", - "itemDamageIsUsed": "Item Damage Is Used" + "damageOnSave": "Damage on Save" }, "RollField": { "diceRolling": { @@ -135,8 +130,7 @@ "attackModifier": "Attack Modifier", "attackName": "Attack Name", "criticalThreshold": "Critical Threshold", - "includeBase": { "label": "Use Item Damage" }, - "groupAttack": { "label": "Group Attack" }, + "includeBase": { "label": "Include Item Damage" }, "multiplier": "Multiplier", "saveHint": "Set a default Trait to enable Reaction Roll. It can be changed later in Reaction Roll Dialog.", "resultBased": { @@ -168,8 +162,7 @@ "rangeDependence": { "title": "Range Dependence" }, - "stacking": { "title": "Stacking" }, - "targetDispositions": "Affected Dispositions" + "stacking": { "title": "Stacking" } }, "RangeDependance": { "hint": "Settings for an optional distance at which this effect should activate", @@ -216,13 +209,7 @@ "type": { "label": "Type" } }, "hordeDamage": "Horde Damage", - "horderHp": "Horde/HP", - "adversaryReactionRoll": { - "headerTitle": "Adversary Reaction Roll" - } - }, - "Base": { - "CannotAddType": "Cannot add {itemType} items to {actorType} actors." + "horderHp": "Horde/HP" }, "Character": { "advantageSources": { @@ -247,8 +234,6 @@ }, "defaultHopeDice": "Default Hope Dice", "defaultFearDice": "Default Fear Dice", - "defaultAdvantageDice": "Default Advantage Dice", - "defaultDisadvantageDice": "Default Disadvantage Dice", "disadvantageSources": { "label": "Disadvantage Sources", "hint": "Add single words or short text as reminders and hints of what a character has disadvantage on." @@ -333,22 +318,6 @@ } }, "newAdversary": "New Adversary" - }, - "Party": { - "Subtitle": { - "character": "{community} {ancestry} | {subclass} {class}", - "companion": "Companion of {partner}" - }, - "RemoveConfirmation": { - "title": "Remove member {name}", - "text": "Are you sure you want to remove {name} from the party?" - }, - "Thresholds": { - "minor": "MIN", - "major": "MAJ", - "severe": "SEV" - }, - "triggerRestContent": "This will trigger a dialog to players make their downtime moves. Are you sure?" } }, "APPLICATIONS": { @@ -384,7 +353,7 @@ "selectSecondaryWeapon": "Select Secondary Weapon", "selectSubclass": "Select Subclass", "setupSkipTitle": "Skipping Character Setup", - "setupSkipContent": "You are skipping the Character Setup by adding this manually. The character setup is the blinking button in the top-right. Are you sure you want to continue?", + "setupSkipContent": "You are skipping the Character Setup by adding this manually. The character setup is the blinking arrows in the top-right. Are you sure you want to continue?", "startingItems": "Starting Items", "story": "Story", "storyExplanation": "Select which background and connection prompts you want to copy into your character's background.", @@ -482,10 +451,6 @@ "defaultOwnershipTooltip": "The default player ownership of countdowns", "hideNewCountdowns": "Hide New Countdowns" }, - "CreateItemDialog": { - "createItem": "Create Item", - "browseCompendium": "Browse Compendium" - }, "DaggerheartMenu": { "title": "GM Tools", "refreshFeatures": "Refresh Features", @@ -700,12 +665,6 @@ "noPlayers": "No players to assign ownership to", "default": "Default Ownership" }, - "PendingReactionsDialog": { - "title": "Pending Reaction Rolls Found", - "unfinishedRolls": "Some Tokens still need to roll their Reaction Roll.", - "confirmation": "Are you sure you want to continue ?", - "warning": "Undone reaction rolls will be considered as failed" - }, "ReactionRoll": { "title": "Reaction Roll: {trait}" }, @@ -731,7 +690,7 @@ "FIELDS": { "initiator": { "memberId": { "label": "Initiating Character" }, - "cost": { "label": "Hope Cost" } + "cost": { "label": "Initiation Cost" } } }, "leaderTitle": "Initiating Character", @@ -758,17 +717,6 @@ "selectRoll": "Select which roll value to be used for the Tag Team" } }, - "GroupRollSelect": { - "title": "Group Roll", - "aidingCharacters": "Aiding Characters", - "leader": "Leader", - "leaderRoll": "Leader Roll", - "openDialogForAll": "Open Dialog For All", - "startGroupRoll": "Start Group Roll", - "finishGroupRoll": "Finish Group Roll", - "cancelConfirmTitle": "Cancel Group Roll", - "cancelConfirmText": "Are you sure you want to cancel the Group Roll? This will close it for all other players too." - }, "TokenConfig": { "actorSizeUsed": "Actor size is set, determining the dimensions" } @@ -789,11 +737,6 @@ "session": "Next Session", "custom": "Custom" }, - "ActionAutomationChoices": { - "never": "Never", - "showDialog": "Show Dialog Only", - "always": "Always" - }, "AdversaryTrait": { "relentless": { "name": "Relentless", @@ -1323,11 +1266,6 @@ "on": "On", "onWithToggle": "On With Toggle" }, - "SceneRangeMeasurementTypes": { - "disable": "Disable Daggerheart Range Measurement", - "default": "Default", - "custom": "Custom" - }, "SelectAction": { "selectType": "Select Action Type", "selectAction": "Action Selection" @@ -2027,10 +1965,6 @@ "hint": "Multiply any damage dealt to you by this number" } }, - "Battlepoints": { - "full": "Battlepoints", - "short": "BP" - }, "Bonuses": { "rest": { "downtimeAction": "Downtime Action", @@ -2441,13 +2375,10 @@ "maxWithThing": "Max {thing}", "missingDragDropThing": "Drop {thing} here", "multiclass": "Multiclass", - "name": "Name", "newCategory": "New Category", "newThing": "New {thing}", - "next": "Next", "none": "None", "noTarget": "No current target", - "optionalThing": "Optional {thing}", "partner": "Partner", "player": { "single": "Player", @@ -2474,11 +2405,9 @@ "rollDamage": "Roll Damage", "rollWith": "{roll} Roll", "save": "Save", - "saveSettings": "Save Settings", "scalable": "Scalable", "scars": "Scars", "situationalBonus": "Situational Bonus", - "searchPlaceholder": "Search...", "spent": "Spent", "step": "Step", "stress": "Stress", @@ -2629,14 +2558,8 @@ }, "Weapon": { "weaponType": "Weapon Type", - "primaryWeapon": { - "full": "Primary Weapon", - "short": "Primary" - }, - "secondaryWeapon": { - "full": "Secondary Weapon", - "short": "Secondary" - } + "primaryWeapon": "Primary Weapon", + "secondaryWeapon": "Secondary Weapon" } }, "MACROS": { @@ -2890,10 +2813,6 @@ } }, "Keybindings": { - "partySheet": { - "name": "Toggle Party Sheet", - "hint": "Open or close the active party's sheet" - }, "spotlight": { "name": "Spotlight Combatant", "hint": "Move the spotlight to a hovered or selected token that's present in an active encounter" @@ -2938,7 +2857,6 @@ "system": "Dice Preset", "font": "Font", "critical": "Duality Critical Animation", - "muted": "Muted", "diceAppearance": "Dice Appearance", "animations": "Animations", "defaultAnimations": "Set Animations As Player Defaults", @@ -3047,6 +2965,18 @@ "immunityTo": "Immunity: {immunities}" }, "featureTitle": "Class Feature", + "groupRoll": { + "title": "Group Roll", + "leader": "Leader", + "partyTeam": "Party Team", + "team": "Team", + "selectLeader": "Select a Leader", + "selectMember": "Select a Member", + "rerollTitle": "Reroll Group Roll", + "rerollContent": "Are you sure you want to reroll your {trait} roll?", + "rerollTooltip": "Reroll", + "wholePartySelected": "The whole party is selected" + }, "healingRoll": { "title": "Heal - {damage}", "heal": "Heal", @@ -3064,9 +2994,6 @@ "resourceRoll": { "playerMessage": "{user} rerolled their {name}" }, - "saveRoll": { - "reactionRollAllTargets": "Reaction Roll All Targets" - }, "tagTeam": { "title": "Tag Team", "membersTitle": "Members" @@ -3095,9 +3022,9 @@ }, "ItemBrowser": { "title": "Daggerheart Compendium Browser", - "windowTitle": "Compendium Browser", "hint": "Select a Folder in sidebar to start browsing through the compendium", "browserSettings": "Browser Settings", + "searchPlaceholder": "Search...", "columnName": "Name", "tooltipFilters": "Filters", "tooltipErase": "Erase", @@ -3133,7 +3060,7 @@ "weapons": "Weapons", "armors": "Armors", "consumables": "Consumables", - "loots": "Loot" + "loots": "Loots" } }, "Notifications": { @@ -3215,8 +3142,7 @@ "tokenActorsMissing": "[{names}] missing Actors", "domainTouchRequirement": "This domain card requires {nr} {domain} cards in the loadout to be used", "knowTheTide": "Know The Tide gained a token", - "lackingItemTransferPermission": "User {user} lacks owner permission needed to transfer items to {target}", - "noTokenTargeted": "No token is targeted" + "lackingItemTransferPermission": "User {user} lacks owner permission needed to transfer items to {target}" }, "Progress": { "migrationLabel": "Performing system migration. Please wait and do not close Foundry." @@ -3228,9 +3154,6 @@ "companion": "Level {level} - {partner}", "companionNoPartner": "No Partner", "duplicateToNewTier": "Duplicate to New Tier", - "activateParty": "Make Active Party", - "partyIsActive": "Active", - "createAdversary": "Create Adversary", "pickTierTitle": "Pick a new tier for this adversary" }, "daggerheartMenu": { @@ -3242,7 +3165,6 @@ "Tooltip": { "disableEffect": "Disable Effect", "enableEffect": "Enable Effect", - "edit": "Edit", "openItemWorld": "Open Item World", "openActorWorld": "Open Actor World", "sendToChat": "Send to Chat", diff --git a/module/applications/characterCreation/characterCreation.mjs b/module/applications/characterCreation/characterCreation.mjs index 936bb79d..e6c0f299 100644 --- a/module/applications/characterCreation/characterCreation.mjs +++ b/module/applications/characterCreation/characterCreation.mjs @@ -11,10 +11,7 @@ export default class DhCharacterCreation extends HandlebarsApplicationMixin(Appl this.character = character; this.setup = { - traits: Object.keys(this.character.system.traits).reduce((acc, key) => { - acc[key] = { value: null }; - return acc; - }, {}), + traits: this.character.system.traits, ancestryName: { primary: '', secondary: '' @@ -380,10 +377,8 @@ export default class DhCharacterCreation extends HandlebarsApplicationMixin(Appl ]; return Object.values(this.setup.traits).reduce((acc, x) => { const index = traitCompareArray.indexOf(x.value); - if (index === -1) return acc; - traitCompareArray.splice(index, 1); - acc += 1; + acc += index !== -1; return acc; }, 0); } diff --git a/module/applications/dialogs/_module.mjs b/module/applications/dialogs/_module.mjs index c866f1cd..a479100a 100644 --- a/module/applications/dialogs/_module.mjs +++ b/module/applications/dialogs/_module.mjs @@ -13,7 +13,7 @@ export { default as OwnershipSelection } from './ownershipSelection.mjs'; export { default as RerollDamageDialog } from './rerollDamageDialog.mjs'; export { default as ResourceDiceDialog } from './resourceDiceDialog.mjs'; export { default as ActionSelectionDialog } from './actionSelectionDialog.mjs'; +export { default as GroupRollDialog } from './group-roll-dialog.mjs'; export { default as TagTeamDialog } from './tagTeamDialog.mjs'; -export { default as GroupRollDialog } from './groupRollDialog.mjs'; export { default as RiskItAllDialog } from './riskItAllDialog.mjs'; export { default as CompendiumBrowserSettingsDialog } from './CompendiumBrowserSettings.mjs'; diff --git a/module/applications/dialogs/actionSelectionDialog.mjs b/module/applications/dialogs/actionSelectionDialog.mjs index 995c4894..c421a577 100644 --- a/module/applications/dialogs/actionSelectionDialog.mjs +++ b/module/applications/dialogs/actionSelectionDialog.mjs @@ -72,8 +72,8 @@ export default class ActionSelectionDialog extends HandlebarsApplicationMixin(Ap static async #onChooseAction(event, button) { const { actionId } = button.dataset; - this.action = this.item.system.actionsList.find(a => a._id === actionId); - Object.defineProperty(this.event, 'shiftKey', { + this.#action = this.#item.system.actionsList.find(a => a._id === actionId); + Object.defineProperty(this.#event, 'shiftKey', { get() { return event.shiftKey; } diff --git a/module/applications/dialogs/d20RollDialog.mjs b/module/applications/dialogs/d20RollDialog.mjs index 067aa473..64fa168a 100644 --- a/module/applications/dialogs/d20RollDialog.mjs +++ b/module/applications/dialogs/d20RollDialog.mjs @@ -123,10 +123,6 @@ export default class D20RollDialog extends HandlebarsApplicationMixin(Applicatio context.advantage = this.config.roll?.advantage; context.disadvantage = this.config.roll?.disadvantage; context.diceOptions = CONFIG.DH.GENERAL.diceTypes; - context.dieFaces = CONFIG.DH.GENERAL.dieFaces.reduce((acc, face) => { - acc[face] = `d${face}`; - return acc; - }, {}); context.isLite = this.config.roll?.lite; context.extraFormula = this.config.extraFormula; context.formula = this.roll.constructFormula(this.config); @@ -156,7 +152,9 @@ export default class D20RollDialog extends HandlebarsApplicationMixin(Applicatio } if (this.config.uses) this.config.uses = foundry.utils.mergeObject(this.config.uses, rest.uses); if (rest.roll?.dice) { - this.roll = foundry.utils.mergeObject(this.roll, rest.roll.dice); + Object.entries(rest.roll.dice).forEach(([key, value]) => { + this.roll[key] = value; + }); } if (rest.hasOwnProperty('trait')) { this.config.roll.trait = rest.trait; @@ -175,15 +173,6 @@ export default class D20RollDialog extends HandlebarsApplicationMixin(Applicatio this.disadvantage = advantage === -1; this.config.roll.advantage = this.config.roll.advantage === advantage ? 0 : advantage; - - if (this.config.roll.advantage === 1 && this.config.data.rules.roll.defaultAdvantageDice) { - const faces = Number.parseInt(this.config.data.rules.roll.defaultAdvantageDice); - this.roll.advantageFaces = Number.isNaN(faces) ? this.roll.advantageFaces : faces; - } else if (this.config.roll.advantage === -1 && this.config.data.rules.roll.defaultDisadvantageDice) { - const faces = Number.parseInt(this.config.data.rules.roll.defaultDisadvantageDice); - this.roll.advantageFaces = Number.isNaN(faces) ? this.roll.advantageFaces : faces; - } - this.render(); } diff --git a/module/applications/dialogs/damageDialog.mjs b/module/applications/dialogs/damageDialog.mjs index 46d3d41f..97f1c538 100644 --- a/module/applications/dialogs/damageDialog.mjs +++ b/module/applications/dialogs/damageDialog.mjs @@ -22,7 +22,6 @@ export default class DamageDialog extends HandlebarsApplicationMixin(Application }, actions: { toggleSelectedEffect: this.toggleSelectedEffect, - updateGroupAttack: this.updateGroupAttack, toggleCritical: this.toggleCritical, submitRoll: this.submitRoll }, @@ -65,40 +64,15 @@ export default class DamageDialog extends HandlebarsApplicationMixin(Application context.hasSelectedEffects = Boolean(Object.keys(this.selectedEffects).length); context.selectedEffects = this.selectedEffects; - context.damageOptions = this.config.damageOptions; - context.rangeOptions = CONFIG.DH.GENERAL.groupAttackRange; - return context; } static updateRollConfiguration(_event, _, formData) { - const data = foundry.utils.expandObject(formData.object); - foundry.utils.mergeObject(this.config.roll, data.roll); - foundry.utils.mergeObject(this.config.modifiers, data.modifiers); - this.config.selectedMessageMode = data.selectedMessageMode; + const { ...rest } = foundry.utils.expandObject(formData.object); + foundry.utils.mergeObject(this.config.roll, rest.roll); + foundry.utils.mergeObject(this.config.modifiers, rest.modifiers); + this.config.selectedMessageMode = rest.selectedMessageMode; - if (data.damageOptions) { - const numAttackers = data.damageOptions.groupAttack?.numAttackers; - if (typeof numAttackers !== 'number' || numAttackers % 1 !== 0) { - data.damageOptions.groupAttack.numAttackers = null; - } - - foundry.utils.mergeObject(this.config.damageOptions, data.damageOptions); - } - - this.render(); - } - - static updateGroupAttack() { - const targets = Array.from(game.user.targets); - if (targets.length === 0) - return ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.noTokenTargeted')); - - const actorId = this.roll.data.parent.id; - const range = this.config.damageOptions.groupAttack.range; - const groupAttackTokens = game.system.api.fields.ActionFields.DamageField.getGroupAttackTokens(actorId, range); - - this.config.damageOptions.groupAttack.numAttackers = groupAttackTokens.length; this.render(); } diff --git a/module/applications/dialogs/downtime.mjs b/module/applications/dialogs/downtime.mjs index 989e4625..3475dee7 100644 --- a/module/applications/dialogs/downtime.mjs +++ b/module/applications/dialogs/downtime.mjs @@ -259,9 +259,8 @@ export default class DhpDowntime extends HandlebarsApplicationMixin(ApplicationV const resetValue = increasing ? 0 : feature.system.resource.max - ? new Roll(Roll.replaceFormulaData(feature.system.resource.max, this.actor)).evaluateSync().total + ? Roll.replaceFormulaData(feature.system.resource.max, this.actor) : 0; - await feature.update({ 'system.resource.value': resetValue }); } diff --git a/module/applications/dialogs/group-roll-dialog.mjs b/module/applications/dialogs/group-roll-dialog.mjs new file mode 100644 index 00000000..8a3c43d6 --- /dev/null +++ b/module/applications/dialogs/group-roll-dialog.mjs @@ -0,0 +1,204 @@ +import autocomplete from 'autocompleter'; +import { abilities } from '../../config/actorConfig.mjs'; + +const { HandlebarsApplicationMixin, ApplicationV2 } = foundry.applications.api; + +export default class GroupRollDialog extends HandlebarsApplicationMixin(ApplicationV2) { + constructor(actors) { + super(); + this.actors = actors; + this.actorLeader = {}; + this.actorsMembers = []; + } + + get title() { + return 'Group Roll'; + } + + static DEFAULT_OPTIONS = { + tag: 'form', + classes: ['daggerheart', 'views', 'dh-style', 'dialog', 'group-roll'], + position: { width: 'auto', height: 'auto' }, + window: { + title: 'DAGGERHEART.UI.Chat.groupRoll.title' + }, + actions: { + roll: GroupRollDialog.#roll, + removeLeader: GroupRollDialog.#removeLeader, + removeMember: GroupRollDialog.#removeMember + }, + form: { handler: this.updateData, submitOnChange: true, closeOnSubmit: false } + }; + + static PARTS = { + application: { + id: 'group-roll', + template: 'systems/daggerheart/templates/dialogs/group-roll/group-roll.hbs' + } + }; + + _attachPartListeners(partId, htmlElement, options) { + super._attachPartListeners(partId, htmlElement, options); + const leaderChoices = this.actors.filter(x => this.actorsMembers.every(member => member.actor?.id !== x.id)); + const memberChoices = this.actors.filter( + x => this.actorLeader?.actor?.id !== x.id && this.actorsMembers.every(member => member.actor?.id !== x.id) + ); + + htmlElement.querySelectorAll('.leader-change-input').forEach(element => { + autocomplete({ + input: element, + fetch: function (text, update) { + if (!text) { + update(leaderChoices); + } else { + text = text.toLowerCase(); + var suggestions = leaderChoices.filter(n => n.name.toLowerCase().includes(text)); + update(suggestions); + } + }, + render: function (actor, search) { + const actorName = game.i18n.localize(actor.name); + const matchIndex = actorName.toLowerCase().indexOf(search); + + const beforeText = actorName.slice(0, matchIndex); + const matchText = actorName.slice(matchIndex, matchIndex + search.length); + const after = actorName.slice(matchIndex + search.length, actorName.length); + const img = document.createElement('img'); + img.src = actor.img; + + const element = document.createElement('li'); + element.appendChild(img); + + const label = document.createElement('span'); + label.innerHTML = + `${beforeText}${matchText ? `${matchText}` : ''}${after}`.replaceAll( + ' ', + ' ' + ); + element.appendChild(label); + + return element; + }, + renderGroup: function (label) { + const itemElement = document.createElement('div'); + itemElement.textContent = game.i18n.localize(label); + return itemElement; + }, + onSelect: actor => { + element.value = actor.uuid; + this.actorLeader = { actor: actor, trait: 'agility', difficulty: 0 }; + this.render(); + }, + click: e => e.fetch(), + customize: function (_input, _inputRect, container) { + container.style.zIndex = foundry.applications.api.ApplicationV2._maxZ; + }, + minLength: 0 + }); + }); + + htmlElement.querySelectorAll('.team-push-input').forEach(element => { + autocomplete({ + input: element, + fetch: function (text, update) { + if (!text) { + update(memberChoices); + } else { + text = text.toLowerCase(); + var suggestions = memberChoices.filter(n => n.name.toLowerCase().includes(text)); + update(suggestions); + } + }, + render: function (actor, search) { + const actorName = game.i18n.localize(actor.name); + const matchIndex = actorName.toLowerCase().indexOf(search); + + const beforeText = actorName.slice(0, matchIndex); + const matchText = actorName.slice(matchIndex, matchIndex + search.length); + const after = actorName.slice(matchIndex + search.length, actorName.length); + const img = document.createElement('img'); + img.src = actor.img; + + const element = document.createElement('li'); + element.appendChild(img); + + const label = document.createElement('span'); + label.innerHTML = + `${beforeText}${matchText ? `${matchText}` : ''}${after}`.replaceAll( + ' ', + ' ' + ); + element.appendChild(label); + + return element; + }, + renderGroup: function (label) { + const itemElement = document.createElement('div'); + itemElement.textContent = game.i18n.localize(label); + return itemElement; + }, + onSelect: actor => { + element.value = actor.uuid; + this.actorsMembers.push({ actor: actor, trait: 'agility', difficulty: 0 }); + this.render({ force: true }); + }, + click: e => e.fetch(), + customize: function (_input, _inputRect, container) { + container.style.zIndex = foundry.applications.api.ApplicationV2._maxZ; + }, + minLength: 0 + }); + }); + } + + async _prepareContext(_options) { + const context = await super._prepareContext(_options); + context.leader = this.actorLeader; + context.members = this.actorsMembers; + context.traitList = abilities; + + context.allSelected = this.actorsMembers.length + (this.actorLeader?.actor ? 1 : 0) === this.actors.length; + context.rollDisabled = context.members.length === 0 || !this.actorLeader?.actor; + + return context; + } + + static updateData(event, _, formData) { + const { actorLeader, actorsMembers } = foundry.utils.expandObject(formData.object); + this.actorLeader = foundry.utils.mergeObject(this.actorLeader, actorLeader); + this.actorsMembers = foundry.utils.mergeObject(this.actorsMembers, actorsMembers); + this.render(true); + } + + static async #removeLeader(_, button) { + this.actorLeader = null; + this.render(); + } + + static async #removeMember(_, button) { + this.actorsMembers = this.actorsMembers.filter(m => m.actor.uuid !== button.dataset.memberUuid); + this.render(); + } + + static async #roll() { + const cls = getDocumentClass('ChatMessage'); + const systemData = { + leader: this.actorLeader, + members: this.actorsMembers + }; + const msg = { + type: 'groupRoll', + user: game.user.id, + speaker: cls.getSpeaker(), + title: game.i18n.localize('DAGGERHEART.UI.Chat.groupRoll.title'), + system: systemData, + content: await foundry.applications.handlebars.renderTemplate( + 'systems/daggerheart/templates/ui/chat/groupRoll.hbs', + { system: systemData } + ) + }; + + cls.create(msg); + this.close(); + } +} diff --git a/module/applications/dialogs/groupRollDialog.mjs b/module/applications/dialogs/groupRollDialog.mjs deleted file mode 100644 index a47dd0a8..00000000 --- a/module/applications/dialogs/groupRollDialog.mjs +++ /dev/null @@ -1,527 +0,0 @@ -import { ResourceUpdateMap } from '../../data/action/baseAction.mjs'; -import { emitAsGM, GMUpdateEvent, RefreshType, socketEvent } from '../../systemRegistration/socket.mjs'; -import Party from '../sheets/actors/party.mjs'; - -const { HandlebarsApplicationMixin, ApplicationV2 } = foundry.applications.api; - -export default class GroupRollDialog extends HandlebarsApplicationMixin(ApplicationV2) { - constructor(party) { - super(); - - this.party = party; - this.partyMembers = party.system.partyMembers - .filter(x => Party.DICE_ROLL_ACTOR_TYPES.includes(x.type)) - .map(member => ({ - ...member.toObject(), - uuid: member.uuid, - id: member.id, - selected: true, - owned: member.testUserPermission(game.user, CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER) - })); - - this.leader = null; - this.openForAllPlayers = true; - - this.tabGroups.application = Object.keys(party.system.groupRoll.participants).length - ? 'groupRoll' - : 'initialization'; - - Hooks.on(socketEvent.Refresh, this.groupRollRefresh.bind()); - } - - get title() { - return game.i18n.localize('DAGGERHEART.APPLICATIONS.GroupRollSelect.title'); - } - - static DEFAULT_OPTIONS = { - tag: 'form', - id: 'GroupRollDialog', - classes: ['daggerheart', 'views', 'dh-style', 'dialog', 'group-roll-dialog'], - position: { width: 550, height: 'auto' }, - actions: { - toggleSelectMember: this.#toggleSelectMember, - startGroupRoll: this.#startGroupRoll, - makeRoll: this.#makeRoll, - removeRoll: this.#removeRoll, - rerollDice: this.#rerollDice, - makeLeaderRoll: this.#makeLeaderRoll, - removeLeaderRoll: this.#removeLeaderRoll, - rerollLeaderDice: this.#rerollLeaderDice, - markSuccessfull: this.#markSuccessfull, - cancelRoll: this.#onCancelRoll, - finishRoll: this.#finishRoll - }, - form: { handler: this.updateData, submitOnChange: true, closeOnSubmit: false } - }; - - static PARTS = { - initialization: { - id: 'initialization', - template: 'systems/daggerheart/templates/dialogs/groupRollDialog/initialization.hbs' - }, - leader: { - id: 'leader', - template: 'systems/daggerheart/templates/dialogs/groupRollDialog/leader.hbs' - }, - groupRoll: { - id: 'groupRoll', - template: 'systems/daggerheart/templates/dialogs/groupRollDialog/groupRoll.hbs' - }, - footer: { - id: 'footer', - template: 'systems/daggerheart/templates/dialogs/groupRollDialog/footer.hbs' - } - }; - - /** @inheritdoc */ - static TABS = { - application: { - tabs: [{ id: 'initialization' }, { id: 'groupRoll' }] - } - }; - - _attachPartListeners(partId, htmlElement, options) { - super._attachPartListeners(partId, htmlElement, options); - - htmlElement - .querySelector('.main-character-field') - ?.addEventListener('input', this.updateLeaderField.bind(this)); - } - - _configureRenderParts(options) { - const { initialization, leader, groupRoll, footer } = super._configureRenderParts(options); - const augmentedParts = { initialization }; - for (const memberKey of Object.keys(this.party.system.groupRoll.aidingCharacters)) { - augmentedParts[memberKey] = { - id: memberKey, - template: 'systems/daggerheart/templates/dialogs/groupRollDialog/groupRollMember.hbs' - }; - } - - augmentedParts.leader = leader; - augmentedParts.groupRoll = groupRoll; - augmentedParts.footer = footer; - - return augmentedParts; - } - - /**@inheritdoc */ - async _onRender(context, options) { - await super._onRender(context, options); - - if (this.element.querySelector('.team-container')) return; - - if (this.tabGroups.application !== this.constructor.PARTS.initialization.id) { - const initializationPart = this.element.querySelector('.initialization-container'); - initializationPart.insertAdjacentHTML('afterend', '
'); - initializationPart.insertAdjacentHTML( - 'afterend', - `
${game.i18n.localize('DAGGERHEART.APPLICATIONS.GroupRollSelect.aidingCharacters')}
` - ); - - const teamContainer = this.element.querySelector('.team-container'); - for (const memberContainer of this.element.querySelectorAll('.team-member-container')) - teamContainer.appendChild(memberContainer); - } - } - - async _prepareContext(_options) { - const context = await super._prepareContext(_options); - - context.isGM = game.user.isGM; - context.isEditable = this.getIsEditable(); - context.fields = this.party.system.schema.fields.groupRoll.fields; - context.data = this.party.system.groupRoll; - context.traitOptions = CONFIG.DH.ACTOR.abilities; - context.members = {}; - context.allHaveRolled = Object.keys(context.data.participants).every(key => { - const data = context.data.participants[key]; - return Boolean(data.rollData); - }); - - return context; - } - - async _preparePartContext(partId, context, options) { - const partContext = await super._preparePartContext(partId, context, options); - partContext.partId = partId; - - switch (partId) { - case 'initialization': - partContext.groupRollFields = this.party.system.schema.fields.groupRoll.fields; - partContext.memberSelection = this.partyMembers; - - const selectedMembers = partContext.memberSelection.filter(x => x.selected); - - partContext.selectedLeader = this.leader; - partContext.selectedLeaderOptions = selectedMembers - .filter(actor => actor.owned) - .map(x => ({ value: x.id, label: x.name })); - partContext.selectedLeaderDisabled = !selectedMembers.length; - - partContext.canStartGroupRoll = selectedMembers.length > 1 && this.leader?.memberId; - partContext.openForAllPlayers = this.openForAllPlayers; - break; - case 'leader': - partContext.leader = this.getRollCharacterData(this.party.system.groupRoll.leader); - break; - case 'groupRoll': - const leader = this.party.system.groupRoll.leader; - partContext.hasRolled = - leader?.rollData || - Object.values(this.party.system.groupRoll?.aidingCharacters ?? {}).some( - x => x.successfull !== null - ); - const { modifierTotal, modifiers } = Object.values(this.party.system.groupRoll.aidingCharacters).reduce( - (acc, curr) => { - const modifier = curr.successfull === true ? 1 : curr.successfull === false ? -1 : null; - if (modifier) { - acc.modifierTotal += modifier; - acc.modifiers.push(modifier); - } - - return acc; - }, - { modifierTotal: 0, modifiers: [] } - ); - const leaderTotal = leader?.rollData ? leader.roll.total : null; - partContext.groupRoll = { - totalLabel: leader?.rollData - ? game.i18n.format('DAGGERHEART.GENERAL.withThing', { - thing: leader.roll.totalLabel - }) - : null, - totalDualityClass: leader?.roll?.isCritical ? 'critical' : leader?.roll?.withHope ? 'hope' : 'fear', - total: leaderTotal + modifierTotal, - leaderTotal: leaderTotal, - modifiers - }; - break; - case 'footer': - partContext.canFinishRoll = - Boolean(this.party.system.groupRoll.leader?.rollData) && - Object.values(this.party.system.groupRoll.aidingCharacters).every(x => x.successfull !== null); - break; - } - - if (Object.keys(this.party.system.groupRoll.aidingCharacters).includes(partId)) { - const characterData = this.party.system.groupRoll.aidingCharacters[partId]; - partContext.members[partId] = this.getRollCharacterData(characterData, partId); - } - - return partContext; - } - - getRollCharacterData(data, partId) { - if (!data) return {}; - - const actor = game.actors.get(data.id); - - return { - ...data, - roll: data.roll, - isEditable: actor.testUserPermission(game.user, CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER), - key: partId, - readyToRoll: Boolean(data.rollChoice), - hasRolled: Boolean(data.rollData) - }; - } - - static async updateData(event, _, formData) { - const partyData = foundry.utils.expandObject(formData.object); - - this.updatePartyData(partyData, this.getUpdatingParts(event.target)); - } - - async updatePartyData(update, updatingParts, options = { render: true }) { - if (!game.users.activeGM) - return ui.notifications.error(game.i18n.localize('DAGGERHEART.UI.Notifications.gmRequired')); - - const gmUpdate = async update => { - await this.party.update(update); - this.render({ parts: updatingParts }); - game.socket.emit(`system.${CONFIG.DH.id}`, { - action: socketEvent.Refresh, - data: { refreshType: RefreshType.GroupRoll, action: 'refresh', parts: updatingParts } - }); - }; - - await emitAsGM( - GMUpdateEvent.UpdateDocument, - gmUpdate, - update, - this.party.uuid, - options.render ? { refreshType: RefreshType.GroupRoll, action: 'refresh', parts: updatingParts } : undefined - ); - } - - getUpdatingParts(target) { - const { initialization, leader, groupRoll, footer } = this.constructor.PARTS; - const isInitialization = this.tabGroups.application === initialization.id; - const updatingMember = target.closest('.team-member-container')?.dataset?.memberKey; - const updatingLeader = target.closest('.main-character-outer-container'); - - return [ - ...(isInitialization ? [initialization.id] : []), - ...(updatingMember ? [updatingMember] : []), - ...(updatingLeader ? [leader.id] : []), - ...(!isInitialization ? [groupRoll.id, footer.id] : []) - ]; - } - - getIsEditable() { - return this.party.system.partyMembers.some(actor => { - const selected = Boolean(this.party.system.groupRoll.participants[actor.id]); - return selected && actor.testUserPermission(game.user, CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER); - }); - } - - groupRollRefresh = ({ refreshType, action, parts }) => { - if (refreshType !== RefreshType.GroupRoll) return; - - switch (action) { - case 'startGroupRoll': - this.tabGroups.application = 'groupRoll'; - break; - case 'refresh': - this.render({ parts }); - break; - case 'close': - this.close(); - break; - } - }; - - async close(options = {}) { - /* Opt out of Foundry's standard behavior of closing all application windows marked as UI when Escape is pressed */ - if (options.closeKey) return; - - Hooks.off(socketEvent.Refresh, this.groupRollRefresh); - return super.close(options); - } - - //#region Initialization - static #toggleSelectMember(_, button) { - const member = this.partyMembers.find(x => x.id === button.dataset.id); - member.selected = !member.selected; - this.render(); - } - - updateLeaderField(event) { - if (!this.leader) this.leader = {}; - this.leader.memberId = event.target.value; - this.render(); - } - - static async #startGroupRoll() { - const leader = this.partyMembers.find(x => x.id === this.leader.memberId); - const aidingCharacters = this.partyMembers.reduce((acc, curr) => { - if (curr.selected && curr.id !== this.leader.memberId) - acc[curr.id] = { id: curr.id, name: curr.name, img: curr.img }; - - return acc; - }, {}); - - await this.party.update({ - 'system.groupRoll': _replace( - new game.system.api.data.GroupRollData({ - ...this.party.system.groupRoll.toObject(), - leader: { id: leader.id, name: leader.name, img: leader.img }, - aidingCharacters - }) - ) - }); - - const hookData = { openForAllPlayers: this.openForAllPlayers, partyId: this.party.id }; - Hooks.callAll(CONFIG.DH.HOOKS.hooksConfig.groupRollStart, hookData); - game.socket.emit(`system.${CONFIG.DH.id}`, { - action: socketEvent.GroupRollStart, - data: hookData - }); - - this.render(); - } - //#endregion - - async makeRoll(button, characterData, path) { - const actor = game.actors.find(x => x.id === characterData.id); - if (!actor) return; - - const result = await actor.rollTrait(characterData.rollChoice, { - skips: { - createMessage: true, - resources: true, - triggers: true - } - }); - - if (!result) return; - if (!game.modules.get('dice-so-nice')?.active) foundry.audio.AudioHelper.play({ src: CONFIG.sounds.dice }); - - const rollData = result.messageRoll.toJSON(); - delete rollData.options.messageRoll; - this.updatePartyData( - { - [path]: rollData - }, - this.getUpdatingParts(button) - ); - } - - static async #makeRoll(_event, button) { - const { member } = button.dataset; - const character = this.party.system.groupRoll.aidingCharacters[member]; - this.makeRoll(button, character, `system.groupRoll.aidingCharacters.${member}.rollData`); - } - - static async #makeLeaderRoll(_event, button) { - const character = this.party.system.groupRoll.leader; - this.makeRoll(button, character, 'system.groupRoll.leader.rollData'); - } - - async removeRoll(button, path) { - this.updatePartyData( - { - [path]: { - rollData: null, - rollChoice: null, - selected: false, - successfull: null - } - }, - this.getUpdatingParts(button) - ); - } - - static async #removeRoll(_event, button) { - this.removeRoll(button, `system.groupRoll.aidingCharacters.${button.dataset.member}`); - } - - static async #removeLeaderRoll(_event, button) { - this.removeRoll(button, 'system.groupRoll.leader'); - } - - async rerollDice(button, data, path) { - const { diceType } = button.dataset; - - const dieIndex = diceType === 'hope' ? 0 : diceType === 'fear' ? 1 : 2; - const newRoll = game.system.api.dice.DualityRoll.fromData(data.rollData); - const dice = newRoll.dice[dieIndex]; - await dice.reroll(`/r1=${dice.total}`, { - liveRoll: { - roll: newRoll, - isReaction: true - } - }); - const rollData = newRoll.toJSON(); - this.updatePartyData( - { - [path]: rollData - }, - this.getUpdatingParts(button) - ); - } - - static async #rerollDice(_, button) { - const { member } = button.dataset; - this.rerollDice( - button, - this.party.system.groupRoll.aidingCharacters[member], - `system.groupRoll.aidingCharacters.${member}.rollData` - ); - } - - static async #rerollLeaderDice(_, button) { - this.rerollDice(button, this.party.system.groupRoll.leader, `system.groupRoll.leader.rollData`); - } - - static #markSuccessfull(_event, button) { - const previousValue = this.party.system.groupRoll.aidingCharacters[button.dataset.member].successfull; - const newValue = Boolean(button.dataset.successfull === 'true'); - this.updatePartyData( - { - [`system.groupRoll.aidingCharacters.${button.dataset.member}.successfull`]: - previousValue === newValue ? null : newValue - }, - this.getUpdatingParts(button) - ); - } - - static async #onCancelRoll(_event, _button, options = { confirm: true }) { - this.cancelRoll(options); - } - - async cancelRoll(options = { confirm: true }) { - if (options.confirm) { - const confirmed = await foundry.applications.api.DialogV2.confirm({ - window: { - title: game.i18n.localize('DAGGERHEART.APPLICATIONS.GroupRollSelect.cancelConfirmTitle') - }, - content: game.i18n.localize('DAGGERHEART.APPLICATIONS.GroupRollSelect.cancelConfirmText') - }); - - if (!confirmed) return; - } - - await this.updatePartyData( - { - 'system.groupRoll': { - leader: null, - aidingCharacters: _replace({}) - } - }, - [], - { render: false } - ); - - this.close(); - game.socket.emit(`system.${CONFIG.DH.id}`, { - action: socketEvent.Refresh, - data: { refreshType: RefreshType.GroupRoll, action: 'close' } - }); - } - - static async #finishRoll() { - const totalRoll = this.party.system.groupRoll.leader.roll; - for (const character of Object.values(this.party.system.groupRoll.aidingCharacters)) { - totalRoll.terms.push(new foundry.dice.terms.OperatorTerm({ operator: character.successfull ? '+' : '-' })); - totalRoll.terms.push(new foundry.dice.terms.NumericTerm({ number: 1 })); - } - - await totalRoll._evaluate(); - - const systemData = totalRoll.options; - const actor = game.actors.get(this.party.system.groupRoll.leader.id); - - const cls = getDocumentClass('ChatMessage'), - msgData = { - type: 'dualityRoll', - user: game.user.id, - title: game.i18n.localize('DAGGERHEART.APPLICATIONS.GroupRollSelect.title'), - speaker: cls.getSpeaker({ actor }), - system: systemData, - rolls: [JSON.stringify(totalRoll)], - sound: null, - flags: { core: { RollTable: true } } - }; - - await cls.create(msgData); - - const resourceMap = new ResourceUpdateMap(actor); - if (totalRoll.isCritical) { - resourceMap.addResources([ - { key: 'stress', value: -1, total: 1 }, - { key: 'hope', value: 1, total: 1 } - ]); - } else if (totalRoll.withHope) { - resourceMap.addResources([{ key: 'hope', value: 1, total: 1 }]); - } else { - resourceMap.addResources([{ key: 'fear', value: 1, total: 1 }]); - } - - resourceMap.updateResources(); - - /* Fin */ - this.cancelRoll({ confirm: false }); - } -} diff --git a/module/applications/dialogs/itemTransfer.mjs b/module/applications/dialogs/itemTransfer.mjs index 42e3a727..ad3cf103 100644 --- a/module/applications/dialogs/itemTransfer.mjs +++ b/module/applications/dialogs/itemTransfer.mjs @@ -38,15 +38,13 @@ export default class ItemTransferDialog extends HandlebarsApplicationMixin(Appli originActor ??= item?.actor; const homebrewKey = CONFIG.DH.SETTINGS.gameSettings.Homebrew; const currencySetting = game.settings.get(CONFIG.DH.id, homebrewKey).currency?.[currency] ?? null; - const max = item?.system.quantity ?? originActor.system.gold[currency] ?? 0; return { originActor, targetActor, itemImage: item?.img, currencyIcon: currencySetting?.icon, - max, - initial: targetActor.system.metadata.quantifiable?.includes(item.type) ? max : 1, + max: item?.system.quantity ?? originActor.system.gold[currency] ?? 0, title: item?.name ?? currencySetting?.label }; } diff --git a/module/applications/dialogs/tagTeamDialog.mjs b/module/applications/dialogs/tagTeamDialog.mjs index 026c4bc0..5236afb8 100644 --- a/module/applications/dialogs/tagTeamDialog.mjs +++ b/module/applications/dialogs/tagTeamDialog.mjs @@ -20,7 +20,7 @@ export default class TagTeamDialog extends HandlebarsApplicationMixin(Applicatio owned: member.testUserPermission(game.user, CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER) })); - this.initiator = { cost: 3 }; + this.initiator = null; this.openForAllPlayers = true; this.tabGroups.application = Object.keys(party.system.tagTeam.members).length @@ -115,12 +115,6 @@ export default class TagTeamDialog extends HandlebarsApplicationMixin(Applicatio async _onRender(context, options) { await super._onRender(context, options); - // if (this.element.querySelector('.roll-selection')) { - // for (const element of this.element.querySelectorAll('.team-member-container')) { - // element.classList.add('select-padding'); - // } - // } - if (this.element.querySelector('.team-container')) return; const initializationPart = this.element.querySelector('.initialization-container'); initializationPart.insertAdjacentHTML('afterend', '
'); @@ -139,10 +133,7 @@ export default class TagTeamDialog extends HandlebarsApplicationMixin(Applicatio context.members = {}; context.allHaveRolled = Object.keys(this.party.system.tagTeam.members).every(key => { const data = this.party.system.tagTeam.members[key]; - const hasRolled = Boolean(data.rollData); - if (!hasRolled) return false; - - return !data.rollData.options.hasDamage || Boolean(data.rollData.options.damage); + return Boolean(data.rollData); }); return context; @@ -375,7 +366,8 @@ export default class TagTeamDialog extends HandlebarsApplicationMixin(Applicatio let rollIsSelected = false; for (const member of Object.values(members)) { const rollFinished = Boolean(member.rollData); - const damageFinished = member.rollData?.options?.hasDamage ? Boolean(member.rollData.options.damage) : true; + const damageFinished = + member.rollData?.options?.hasDamage !== undefined ? member.rollData.options.damage : true; rollsAreFinished = rollsAreFinished && rollFinished && damageFinished; rollIsSelected = rollIsSelected || member.selected; diff --git a/module/applications/hud/tokenHUD.mjs b/module/applications/hud/tokenHUD.mjs index 943f3506..77caaaff 100644 --- a/module/applications/hud/tokenHUD.mjs +++ b/module/applications/hud/tokenHUD.mjs @@ -122,14 +122,15 @@ export default class DHTokenHUD extends foundry.applications.hud.TokenHUD { async toggleClowncar(actors) { const animationDuration = 500; - const scene = game.scenes.get(game.user.viewedScene); - /* getDependentTokens returns already removed tokens with id = null. Need to filter that until it's potentially fixed from Foundry */ - const activeTokens = actors.flatMap(member => member.getDependentTokens({ scenes: scene }).filter(x => x._id)); + const activeTokens = actors.flatMap(member => member.getActiveTokens()); const { x: actorX, y: actorY } = this.document; if (activeTokens.length > 0) { for (let token of activeTokens) { - await token.update({ x: actorX, y: actorY, alpha: 0 }, { animation: { duration: animationDuration } }); - setTimeout(() => token.delete(), animationDuration); + await token.document.update( + { x: actorX, y: actorY, alpha: 0 }, + { animation: { duration: animationDuration } } + ); + setTimeout(() => token.document.delete(), animationDuration); } } else { const activeScene = game.scenes.find(x => x.id === game.user.viewedScene); @@ -139,16 +140,11 @@ export default class DHTokenHUD extends foundry.applications.hud.TokenHUD { tokenData.push(data.toObject()); } - const viewedLevel = game.scenes.get(game.user.viewedScene).levels.get(game.user.viewedLevel); - const elevation = this.actor.token?.elevation ?? viewedLevel.elevation.bottom; - const newTokens = await activeScene.createEmbeddedDocuments( 'Token', tokenData.map(tokenData => ({ ...tokenData, alpha: 0, - level: viewedLevel, - elevation: elevation, x: actorX, y: actorY })) diff --git a/module/applications/settings/appearanceSettings.mjs b/module/applications/settings/appearanceSettings.mjs index 9de9e752..151648e1 100644 --- a/module/applications/settings/appearanceSettings.mjs +++ b/module/applications/settings/appearanceSettings.mjs @@ -118,13 +118,8 @@ export default class DHAppearanceSettings extends HandlebarsApplicationMixin(App break; case 'footer': partContext.buttons = [ - { - type: 'button', - action: 'reset', - icon: 'fa-solid fa-arrow-rotate-left', - label: game.i18n.localize('SETTINGS.UI.ACTIONS.Reset') - }, - { type: 'submit', icon: 'fa-solid fa-floppy-disk', label: game.i18n.localize('EDITOR.Save') } + { type: 'button', action: 'reset', icon: 'fa-solid fa-arrow-rotate-left', label: 'Reset' }, + { type: 'submit', icon: 'fa-solid fa-floppy-disk', label: 'Save Changes' } ]; break; } diff --git a/module/applications/sheets-configs/action-base-config.mjs b/module/applications/sheets-configs/action-base-config.mjs index a94abb26..0ae39477 100644 --- a/module/applications/sheets-configs/action-base-config.mjs +++ b/module/applications/sheets-configs/action-base-config.mjs @@ -264,9 +264,7 @@ export default class DHActionBaseConfig extends DaggerheartSheet(ApplicationV2) key = event.target.closest('[data-key]').dataset.key; if (!this.action[key]) return; - const value = key === 'areas' ? { name: this.action.item.name } : {}; - - data[key].push(this.action.defaultValues[key] ?? value); + data[key].push(this.action.defaultValues[key] ?? {}); this.constructor.updateForm.bind(this)(null, null, { object: foundry.utils.flattenObject(data) }); } diff --git a/module/applications/sheets-configs/action-config.mjs b/module/applications/sheets-configs/action-config.mjs index ef529e9b..e073cfa6 100644 --- a/module/applications/sheets-configs/action-config.mjs +++ b/module/applications/sheets-configs/action-config.mjs @@ -19,17 +19,15 @@ export default class DHActionConfig extends DHActionBaseConfig { return context; } - static async addEffect(event) { - const { areaIndex } = event.target.dataset; + static async addEffect(_event) { if (!this.action.effects) return; const data = this.action.toObject(); const created = await this.action.item.createEmbeddedDocuments('ActiveEffect', [ - game.system.api.data.activeEffects.BaseEffect.getDefaultObject({ transfer: false }) + game.system.api.data.activeEffects.BaseEffect.getDefaultObject() ]); - if (areaIndex !== undefined) data.areas[areaIndex].effects.push(created[0]._id); - else data.effects.push({ _id: created[0]._id }); + data.effects.push({ _id: created[0]._id }); this.constructor.updateForm.bind(this)(null, null, { object: foundry.utils.flattenObject(data) }); this.action.item.effects.get(created[0]._id).sheet.render(true); } @@ -54,19 +52,9 @@ export default class DHActionConfig extends DHActionBaseConfig { static removeEffect(event, button) { if (!this.action.effects) return; - - const { areaIndex, index } = button.dataset; - let effectId = null; - if (areaIndex !== undefined) { - effectId = this.action.areas[areaIndex].effects[index]; - const data = this.action.toObject(); - data.areas[areaIndex].effects.splice(index, 1); - this.constructor.updateForm.call(this, null, null, { object: foundry.utils.flattenObject(data) }); - } else { + const index = button.dataset.index, effectId = this.action.effects[index]._id; - this.constructor.removeElement.call(this, event, button); - } - + this.constructor.removeElement.bind(this)(event, button); this.action.item.deleteEmbeddedDocuments('ActiveEffect', [effectId]); } diff --git a/module/applications/sheets-configs/action-settings-config.mjs b/module/applications/sheets-configs/action-settings-config.mjs index 24553069..9cb866bc 100644 --- a/module/applications/sheets-configs/action-settings-config.mjs +++ b/module/applications/sheets-configs/action-settings-config.mjs @@ -31,35 +31,21 @@ export default class DHActionSettingsConfig extends DHActionBaseConfig { } static async addEffect(_event) { - const { areaIndex } = event.target.dataset; if (!this.action.effects) return; - - const effectData = game.system.api.data.activeEffects.BaseEffect.getDefaultObject({ transfer: false }); + const effectData = game.system.api.data.activeEffects.BaseEffect.getDefaultObject(); const data = this.action.toObject(); this.sheetUpdate(data, effectData); this.effects = [...this.effects, effectData]; - - if (areaIndex !== undefined) data.areas[areaIndex].effects.push(effectData.id); - else data.effects.push({ _id: effectData.id }); - + data.effects.push({ _id: effectData.id }); this.constructor.updateForm.bind(this)(null, null, { object: foundry.utils.flattenObject(data) }); } static removeEffect(event, button) { if (!this.action.effects) return; - const { areaIndex, index } = button.dataset; - let effectId = null; - if (areaIndex !== undefined) { - effectId = this.action.areas[areaIndex].effects[index]; - const data = this.action.toObject(); - data.areas[areaIndex].effects.splice(index, 1); - this.constructor.updateForm.call(this, null, null, { object: foundry.utils.flattenObject(data) }); - } else { + const index = button.dataset.index, effectId = this.action.effects[index]._id; - this.constructor.removeElement.call(this, event, button); - } - + this.constructor.removeElement.bind(this)(event, button); this.sheetUpdate( this.action.toObject(), this.effects.find(x => x.id === effectId), diff --git a/module/applications/sheets/actors/adversary.mjs b/module/applications/sheets/actors/adversary.mjs index 04be3efb..d8a3df29 100644 --- a/module/applications/sheets/actors/adversary.mjs +++ b/module/applications/sheets/actors/adversary.mjs @@ -217,8 +217,8 @@ export default class AdversarySheet extends DHBaseActorSheet { static #reactionRoll(event) { const config = { event, - title: game.i18n.localize('DAGGERHEART.GENERAL.reactionRoll'), - headerTitle: game.i18n.localize('DAGGERHEART.ACTORS.Adversary.adversaryReactionRoll.headerTitle'), + title: `Reaction Roll: ${this.actor.name}`, + headerTitle: 'Adversary Reaction Roll', roll: { type: 'trait' }, diff --git a/module/applications/sheets/actors/character.mjs b/module/applications/sheets/actors/character.mjs index c59dd64e..f2686fdd 100644 --- a/module/applications/sheets/actors/character.mjs +++ b/module/applications/sheets/actors/character.mjs @@ -12,6 +12,8 @@ export default class CharacterSheet extends DHBaseActorSheet { static DEFAULT_OPTIONS = { classes: ['character'], position: { width: 850, height: 800 }, + /* Foundry adds disabled to all buttons and inputs if editPermission is missing. This is not desired. */ + editPermission: CONST.DOCUMENT_OWNERSHIP_LEVELS.OBSERVER, actions: { toggleVault: CharacterSheet.#toggleVault, rollAttribute: CharacterSheet.#rollAttribute, @@ -66,7 +68,7 @@ export default class CharacterSheet extends DHBaseActorSheet { } }, { - handler: CharacterSheet.#getEquipmentContextOptions, + handler: CharacterSheet.#getEquipamentContextOptions, selector: '[data-item-uuid][data-type="armor"], [data-item-uuid][data-type="weapon"]', options: { parentClassHooks: false, @@ -168,16 +170,6 @@ export default class CharacterSheet extends DHBaseActorSheet { return applicationOptions; } - /** @inheritdoc */ - _toggleDisabled(disabled) { - // Overriden to only disable text inputs by default. - // Everything else is done by checking @root.editable in the sheet - const form = this.form; - for (const input of form.querySelectorAll('input:not([type=search]), .editor.prosemirror')) { - input.disabled = disabled; - } - } - /** @inheritDoc */ async _onRender(context, options) { await super._onRender(context, options); @@ -323,11 +315,11 @@ export default class CharacterSheet extends DHBaseActorSheet { /**@type {import('@client/applications/ux/context-menu.mjs').ContextMenuEntry[]} */ const options = [ { - label: 'toLoadout', + name: 'toLoadout', icon: 'fa-solid fa-arrow-up', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc?.isOwner && doc.system.inVault; + return doc && doc.system.inVault; }, callback: async target => { const doc = await getDocFromElement(target); @@ -337,11 +329,11 @@ export default class CharacterSheet extends DHBaseActorSheet { } }, { - label: 'recall', + name: 'recall', icon: 'fa-solid fa-bolt-lightning', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc?.isOwner && doc.system.inVault; + return doc && doc.system.inVault; }, callback: async (target, event) => { const doc = await getDocFromElement(target); @@ -376,17 +368,17 @@ export default class CharacterSheet extends DHBaseActorSheet { } }, { - label: 'toVault', + name: 'toVault', icon: 'fa-solid fa-arrow-down', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc?.isOwner && !doc.system.inVault; + return doc && !doc.system.inVault; }, callback: async target => (await getDocFromElement(target)).update({ 'system.inVault': true }) } ].map(option => ({ ...option, - label: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.label}`, + name: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.name}`, icon: `` })); @@ -399,29 +391,29 @@ export default class CharacterSheet extends DHBaseActorSheet { * @this {CharacterSheet} * @protected */ - static #getEquipmentContextOptions() { + static #getEquipamentContextOptions() { const options = [ { - label: 'equip', + name: 'equip', icon: 'fa-solid fa-hands', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc.isOwner && doc && !doc.system.equipped; + return doc && !doc.system.equipped; }, callback: (target, event) => CharacterSheet.#toggleEquipItem.call(this, event, target) }, { - label: 'unequip', + name: 'unequip', icon: 'fa-solid fa-hands', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc.isOwner && doc && doc.system.equipped; + return doc && doc.system.equipped; }, callback: (target, event) => CharacterSheet.#toggleEquipItem.call(this, event, target) } ].map(option => ({ ...option, - label: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.label}`, + name: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.name}`, icon: `` })); diff --git a/module/applications/sheets/actors/party.mjs b/module/applications/sheets/actors/party.mjs index a7eeccdf..c5e77112 100644 --- a/module/applications/sheets/actors/party.mjs +++ b/module/applications/sheets/actors/party.mjs @@ -1,9 +1,10 @@ import DHBaseActorSheet from '../api/base-actor.mjs'; -import { getDocFromElement, sortBy } from '../../../helpers/utils.mjs'; +import { getDocFromElement } from '../../../helpers/utils.mjs'; import { ItemBrowser } from '../../ui/itemBrowser.mjs'; import FilterMenu from '../../ux/filter-menu.mjs'; import DaggerheartMenu from '../../sidebar/tabs/daggerheartMenu.mjs'; import { socketEvent } from '../../../systemRegistration/socket.mjs'; +import GroupRollDialog from '../../dialogs/group-roll-dialog.mjs'; import DhpActor from '../../../documents/actor.mjs'; export default class Party extends DHBaseActorSheet { @@ -17,14 +18,13 @@ export default class Party extends DHBaseActorSheet { static DEFAULT_OPTIONS = { classes: ['party'], position: { - width: 600, + width: 550, height: 900 }, window: { resizable: true }, actions: { - openDocument: Party.#openDocument, deletePartyMember: Party.#deletePartyMember, deleteItem: Party.#deleteItem, toggleHope: Party.#toggleHope, @@ -45,6 +45,10 @@ export default class Party extends DHBaseActorSheet { header: { template: 'systems/daggerheart/templates/sheets/actors/party/header.hbs' }, tabs: { template: 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs' }, partyMembers: { template: 'systems/daggerheart/templates/sheets/actors/party/party-members.hbs' }, + resources: { + template: 'systems/daggerheart/templates/sheets/actors/party/resources.hbs', + scrollable: [''] + }, /* NOT YET IMPLEMENTED */ // projects: { // template: 'systems/daggerheart/templates/sheets/actors/party/projects.hbs', @@ -62,6 +66,7 @@ export default class Party extends DHBaseActorSheet { primary: { tabs: [ { id: 'partyMembers' }, + { id: 'resources' }, /* NOT YET IMPLEMENTED */ // { id: 'projects' }, { id: 'inventory' }, @@ -91,8 +96,6 @@ export default class Party extends DHBaseActorSheet { case 'header': await this._prepareHeaderContext(context, options); break; - case 'partyMembers': - await this._prepareMembersContext(context, options); case 'notes': await this._prepareNotesContext(context, options); break; @@ -116,60 +119,6 @@ export default class Party extends DHBaseActorSheet { relativeTo: this.document }); context.tagTeamActive = Boolean(this.document.system.tagTeam.initiator); - context.groupRollActive = Boolean(this.document.system.groupRoll.leader); - } - - async _prepareMembersContext(context, _options) { - context.partyMembers = []; - const traits = ['agility', 'strength', 'finesse', 'instinct', 'presence', 'knowledge']; - for (const actor of this.document.system.partyMembers) { - const weapons = []; - if (actor.type === 'character') { - if (actor.system.usedUnarmed) { - weapons.push(actor.system.usedUnarmed); - } - const equipped = actor.items.filter(i => i.system.equipped && i.type === 'weapon'); - weapons.push(...sortBy(equipped, i => (i.system.secondary ? 1 : 0))); - } - - context.partyMembers.push({ - uuid: actor.uuid, - img: actor.img, - name: actor.name, - subtitle: (() => { - if (!['character', 'companion'].includes(actor.type)) { - return game.i18n.format(`TYPES.Actor.${actor.type}`); - } - - const { value: classItem, subclass } = actor.system.class ?? {}; - const partner = actor.system.partner; - const ancestry = actor.system.ancestry; - const community = actor.system.community; - if (partner || (classItem && subclass && ancestry && community)) { - return game.i18n.format(`DAGGERHEART.ACTORS.Party.Subtitle.${actor.type}`, { - class: classItem?.name, - subclass: subclass?.name, - partner: partner?.name, - ancestry: ancestry?.name, - community: community?.name - }); - } - })(), - type: actor.type, - resources: actor.system.resources, - armorScore: actor.system.armorScore, - damageThresholds: actor.system.damageThresholds, - evasion: actor.system.evasion, - difficulty: actor.system.difficulty, - traits: actor.system.traits - ? traits.map(t => ({ - label: game.i18n.localize(`DAGGERHEART.CONFIG.Traits.${t}.short`), - value: actor.system.traits[t].value - })) - : null, - weapons - }); - } } /** @@ -200,12 +149,6 @@ export default class Party extends DHBaseActorSheet { } } - static async #openDocument(_, target) { - const uuid = target.dataset.uuid; - const document = await foundry.utils.fromUuid(uuid); - document?.sheet?.render(true); - } - /** * Toggles a hope resource value. * @type {ApplicationClickAction} @@ -247,7 +190,7 @@ export default class Party extends DHBaseActorSheet { * @type {ApplicationClickAction} */ static async #toggleArmorSlot(_, target) { - const actor = await foundry.utils.fromUuid(target.dataset.actorId); + const actor = game.actors.get(target.dataset.actorId); const { value, max } = actor.system.armorScore; const inputValue = Number.parseInt(target.dataset.value); const newValue = value >= inputValue ? inputValue - 1 : inputValue; @@ -288,7 +231,7 @@ export default class Party extends DHBaseActorSheet { title: game.i18n.localize(`DAGGERHEART.APPLICATIONS.Downtime.${button.dataset.type}.title`), icon: button.dataset.type === 'shortRest' ? 'fa-solid fa-utensils' : 'fa-solid fa-bed' }, - content: game.i18n.localize('DAGGERHEART.ACTORS.Party.triggerRestContent'), + content: 'This will trigger a dialog to players make their downtime moves, are you sure?', classes: ['daggerheart', 'dialog', 'dh-style'] }); @@ -318,7 +261,9 @@ export default class Party extends DHBaseActorSheet { } static async #groupRoll(_params) { - new game.system.api.applications.dialogs.GroupRollDialog(this.document).render({ force: true }); + new GroupRollDialog( + this.document.system.partyMembers.filter(x => Party.DICE_ROLL_ACTOR_TYPES.includes(x.type)) + ).render({ force: true }); } /* -------------------------------------------- */ @@ -480,23 +425,25 @@ export default class Party extends DHBaseActorSheet { } static async #deletePartyMember(event, target) { - const doc = await foundry.utils.fromUuid(target.closest('[data-uuid]')?.dataset.uuid); + const doc = await getDocFromElement(target.closest('.inventory-item')); + if (!event.shiftKey) { const confirmed = await foundry.applications.api.DialogV2.confirm({ window: { - title: game.i18n.format('DAGGERHEART.ACTORS.Party.RemoveConfirmation.title', { + title: game.i18n.format('DAGGERHEART.APPLICATIONS.DeleteConfirmation.title', { + type: game.i18n.localize('TYPES.Actor.adversary'), name: doc.name }) }, - content: game.i18n.format('DAGGERHEART.ACTORS.Party.RemoveConfirmation.text', { name: doc.name }) + content: game.i18n.format('DAGGERHEART.APPLICATIONS.DeleteConfirmation.text', { name: doc.name }) }); if (!confirmed) return; } const currentMembers = this.document.system.partyMembers.map(x => x.uuid); - const newMembersList = currentMembers.filter(uuid => uuid !== doc.uuid); - await this.document.update({ 'system.partyMembers': newMembersList }); + const newMemberdList = currentMembers.filter(uuid => uuid !== doc.uuid); + await this.document.update({ 'system.partyMembers': newMemberdList }); } static async #deleteItem(event, target) { diff --git a/module/applications/sheets/api/application-mixin.mjs b/module/applications/sheets/api/application-mixin.mjs index 5faa5d5c..64f62405 100644 --- a/module/applications/sheets/api/application-mixin.mjs +++ b/module/applications/sheets/api/application-mixin.mjs @@ -418,18 +418,18 @@ export default function DHApplicationMixin(Base) { /**@type {import('@client/applications/ux/context-menu.mjs').ContextMenuEntry[]} */ const options = [ { - label: 'disableEffect', + name: 'disableEffect', icon: 'fa-solid fa-lightbulb', - visible: element => { + condition: element => { const target = element.closest('[data-item-uuid]'); return !target.dataset.disabled && target.dataset.itemType !== 'beastform'; }, callback: async target => (await getDocFromElement(target)).update({ disabled: true }) }, { - label: 'enableEffect', + name: 'enableEffect', icon: 'fa-regular fa-lightbulb', - visible: element => { + condition: element => { const target = element.closest('[data-item-uuid]'); return target.dataset.disabled && target.dataset.itemType !== 'beastform'; }, @@ -437,7 +437,7 @@ export default function DHApplicationMixin(Base) { } ].map(option => ({ ...option, - label: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.label}`, + name: `DAGGERHEART.APPLICATIONS.ContextMenu.${option.name}`, icon: `` })); @@ -468,14 +468,14 @@ export default function DHApplicationMixin(Base) { _getContextMenuCommonOptions({ usable = false, toChat = false, deletable = true }) { const options = [ { - label: 'CONTROLS.CommonEdit', + name: 'CONTROLS.CommonEdit', icon: 'fa-solid fa-pen-to-square', - visible: target => { + condition: target => { const { dataset } = target.closest('[data-item-uuid]'); const doc = getDocFromElementSync(target); return ( (!dataset.noCompendiumEdit && !doc) || - (doc?.isOwner && (!doc?.hasOwnProperty('systemPath') || doc?.inCollection)) + (doc && (!doc?.hasOwnProperty('systemPath') || doc?.inCollection)) ); }, callback: async target => (await getDocFromElement(target)).sheet.render({ force: true }) @@ -484,14 +484,14 @@ export default function DHApplicationMixin(Base) { if (usable) { options.unshift({ - label: 'DAGGERHEART.GENERAL.damage', + name: 'DAGGERHEART.GENERAL.damage', icon: 'fa-solid fa-explosion', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - const hasDamage = + return ( !foundry.utils.isEmpty(doc?.system?.attack?.damage.parts) || - !foundry.utils.isEmpty(doc?.damage?.parts); - return doc?.isOwner && hasDamage; + !foundry.utils.isEmpty(doc?.damage?.parts) + ); }, callback: async (target, event) => { const doc = await getDocFromElement(target), @@ -507,11 +507,11 @@ export default function DHApplicationMixin(Base) { }); options.unshift({ - label: 'DAGGERHEART.APPLICATIONS.ContextMenu.useItem', + name: 'DAGGERHEART.APPLICATIONS.ContextMenu.useItem', icon: 'fa-solid fa-burst', - visible: target => { + condition: target => { const doc = getDocFromElementSync(target); - return doc?.isOwner && !(doc.type === 'domainCard' && doc.system.inVault); + return doc && !(doc.type === 'domainCard' && doc.system.inVault); }, callback: async (target, event) => (await getDocFromElement(target)).use(event) }); @@ -519,19 +519,18 @@ export default function DHApplicationMixin(Base) { if (toChat) options.push({ - label: 'DAGGERHEART.APPLICATIONS.ContextMenu.sendToChat', + name: 'DAGGERHEART.APPLICATIONS.ContextMenu.sendToChat', icon: 'fa-solid fa-message', callback: async target => (await getDocFromElement(target)).toChat(this.document.uuid) }); if (deletable) options.push({ - label: 'CONTROLS.CommonDelete', + name: 'CONTROLS.CommonDelete', icon: 'fa-solid fa-trash', - visible: element => { + condition: element => { const target = element.closest('[data-item-uuid]'); - const doc = getDocFromElementSync(target); - return doc?.isOwner && target.dataset.itemType !== 'beastform'; + return target.dataset.itemType !== 'beastform'; }, callback: async (target, event) => { const doc = await getDocFromElement(target); @@ -645,12 +644,12 @@ export default function DHApplicationMixin(Base) { buttons: [ { action: 'create', - label: game.i18n.localize('DAGGERHEART.APPLICATIONS.CreateItemDialog.createItem'), + label: 'Create Item', icon: 'fa-solid fa-plus' }, { action: 'browse', - label: game.i18n.localize('DAGGERHEART.APPLICATIONS.CreateItemDialog.browseCompendium'), + label: 'Browse Compendium', icon: 'fa-solid fa-book' } ] diff --git a/module/applications/sheets/api/base-actor.mjs b/module/applications/sheets/api/base-actor.mjs index e23a4426..4a550d72 100644 --- a/module/applications/sheets/api/base-actor.mjs +++ b/module/applications/sheets/api/base-actor.mjs @@ -73,7 +73,7 @@ export default class DHBaseActorSheet extends DHApplicationMixin(ActorSheetV2) { .hideAttribution; // Prepare inventory data - if (this.document.system.metadata.hasInventory) { + if (['party', 'character'].includes(this.document.type)) { context.inventory = { currencies: {}, weapons: this.document.itemTypes.weapon.sort((a, b) => a.sort - b.sort), @@ -283,7 +283,11 @@ export default class DHBaseActorSheet extends DHApplicationMixin(ActorSheetV2) { async _onDropItem(event, item) { const data = foundry.applications.ux.TextEditor.implementation.getDragEventData(event); const originActor = item.actor; - if (!originActor || originActor.uuid === this.document.uuid || !this.document.system.metadata.hasInventory) { + if ( + item.actor?.uuid === this.document.uuid || + !originActor || + !['character', 'party'].includes(this.document.type) + ) { return super._onDropItem(event, item); } @@ -298,79 +302,47 @@ export default class DHBaseActorSheet extends DHApplicationMixin(ActorSheetV2) { ); } - // Perform the actual transfer, showing a dialog when doing it - const availableQuantity = Math.max(1, item.system.quantity); - const actorItem = originActor.items.get(data.originId) ?? item; - if (availableQuantity > 1) { - const quantityTransferred = await game.system.api.applications.dialogs.ItemTransferDialog.configure({ + if (item.system.metadata.isQuantifiable) { + const actorItem = originActor.items.get(data.originId); + const quantityTransfered = await game.system.api.applications.dialogs.ItemTransferDialog.configure({ item, targetActor: this.document }); - return this.#transferItem(actorItem, quantityTransferred); + + if (quantityTransfered) { + const existingItem = this.document.items.find(x => itemIsIdentical(x, item)); + if (existingItem) { + await existingItem.update({ + 'system.quantity': existingItem.system.quantity + quantityTransfered + }); + } else { + const createData = item.toObject(); + await this.document.createEmbeddedDocuments('Item', [ + { + ...createData, + system: { + ...createData.system, + quantity: quantityTransfered + } + } + ]); + } + + if (quantityTransfered === actorItem.system.quantity) { + await originActor.deleteEmbeddedDocuments('Item', [data.originId]); + } else { + await actorItem.update({ + 'system.quantity': actorItem.system.quantity - quantityTransfered + }); + } + } } else { - return this.#transferItem(actorItem, availableQuantity); + await this.document.createEmbeddedDocuments('Item', [item.toObject()]); + await originActor.deleteEmbeddedDocuments('Item', [data.originId]); } } } - /** - * Helper to perform the actual transfer of an item to this actor, including stack/unstack logic based on target quantifiability. - * Make sure item is the actor item before calling this method or there will be issues - */ - async #transferItem(item, quantity) { - const originActor = item.actor; - const targetActor = this.document; - const allowStacking = targetActor.system.metadata.quantifiable?.includes(item.type); - - const batch = []; - - // First add/update the item to the target actor - const existing = allowStacking ? targetActor.items.find(x => itemIsIdentical(x, item)) : null; - if (existing) { - batch.push({ - action: 'update', - documentName: 'Item', - parent: targetActor, - updates: [{ '_id': existing.id, 'system.quantity': existing.system.quantity + quantity }] - }); - } else { - const itemsToCreate = []; - if (allowStacking) { - itemsToCreate.push(foundry.utils.mergeObject(item.toObject(true), { system: { quantity } })); - } else { - const createData = new Array(Math.max(1, quantity)) - .fill(0) - .map(() => foundry.utils.mergeObject(item.toObject(), { system: { quantity: 1 } })); - itemsToCreate.push(...createData); - } - batch.push({ - action: 'create', - documentName: 'Item', - parent: targetActor, - data: itemsToCreate - }); - } - - // Remove the item from the original actor (by either deleting it, or updating its quantity) - if (quantity >= item.system.quantity) { - batch.push({ - action: 'delete', - documentName: 'Item', - parent: originActor, - ids: [item.id] - }); - } else { - batch.push({ - action: 'update', - documentName: 'Item', - parent: originActor, - updates: [{ '_id': item.id, 'system.quantity': item.system.quantity - quantity }] - }); - } - - return foundry.documents.modifyBatch(batch); - } - /** * On dragStart on the item. * @param {DragEvent} event - The drag event diff --git a/module/applications/sheets/items/ancestry.mjs b/module/applications/sheets/items/ancestry.mjs index cf040e02..8c0a5620 100644 --- a/module/applications/sheets/items/ancestry.mjs +++ b/module/applications/sheets/items/ancestry.mjs @@ -31,12 +31,11 @@ export default class AncestrySheet extends DHHeritageSheet { if (data.type === 'ActiveEffect') return super._onDrop(event); const target = event.target.closest('fieldset.drop-section'); - if (target) { - const typeField = - this.document.system[target.dataset.type === 'primary' ? 'primaryFeature' : 'secondaryFeature']; - if (!typeField) { - super._onDrop(event); - } + const typeField = + this.document.system[target.dataset.type === 'primary' ? 'primaryFeature' : 'secondaryFeature']; + + if (!typeField) { + super._onDrop(event); } } } diff --git a/module/applications/sheets/items/feature.mjs b/module/applications/sheets/items/feature.mjs index 7f9028d5..6ff98ca7 100644 --- a/module/applications/sheets/items/feature.mjs +++ b/module/applications/sheets/items/feature.mjs @@ -31,7 +31,7 @@ export default class FeatureSheet extends DHBaseItemSheet { labelPrefix: 'DAGGERHEART.GENERAL.Tabs' } }; - //Might be wrong location but testing out if here is okay. +//Might be wrong location but testing out if here is okay. /**@override */ async _prepareContext(options) { const context = await super._prepareContext(options); diff --git a/module/applications/sidebar/tabs/actorDirectory.mjs b/module/applications/sidebar/tabs/actorDirectory.mjs index 89da1426..9d8f16e1 100644 --- a/module/applications/sidebar/tabs/actorDirectory.mjs +++ b/module/applications/sidebar/tabs/actorDirectory.mjs @@ -46,67 +46,50 @@ export default class DhActorDirectory extends foundry.applications.sidebar.tabs. _getEntryContextOptions() { const options = super._getEntryContextOptions(); - options.push( - { - label: 'DAGGERHEART.UI.Sidebar.actorDirectory.duplicateToNewTier', - icon: ``, - visible: li => { - const actor = game.actors.get(li.dataset.entryId); - return actor?.type === 'adversary' && actor.system.type !== 'social'; - }, - callback: async li => { - const actor = game.actors.get(li.dataset.entryId); - if (!actor) throw new Error('Unexpected missing actor'); - - const tiers = [1, 2, 3, 4].filter(t => t !== actor.system.tier); - const content = document.createElement('div'); - const select = document.createElement('select'); - select.name = 'tier'; - select.append( - ...tiers.map(t => { - const option = document.createElement('option'); - option.value = t; - option.textContent = game.i18n.localize(`DAGGERHEART.GENERAL.Tiers.${t}`); - return option; - }) - ); - content.append(select); - - const tier = await foundry.applications.api.Dialog.input({ - classes: ['dh-style', 'dialog'], - window: { title: 'DAGGERHEART.UI.Sidebar.actorDirectory.pickTierTitle' }, - content, - ok: { - label: 'DAGGERHEART.UI.Sidebar.actorDirectory.createAdversary', - callback: (event, button, dialog) => Number(button.form.elements.tier.value) - } - }); - - if (tier === actor.system.tier) { - ui.notifications.warn('This actor is already at this tier'); - } else if (tier) { - const source = actor.system.adjustForTier(tier); - await Actor.create(source); - ui.notifications.info(`Tier ${tier} ${actor.name} created`); - } - } + options.push({ + name: 'DAGGERHEART.UI.Sidebar.actorDirectory.duplicateToNewTier', + icon: ``, + condition: li => { + const actor = game.actors.get(li.dataset.entryId); + return actor?.type === 'adversary' && actor.system.type !== 'social'; }, - { - label: 'DAGGERHEART.UI.Sidebar.actorDirectory.activateParty', - icon: ``, - visible: li => { - const actor = game.actors.get(li.dataset.entryId); - return actor && actor.type === 'party' && !actor.system.active; - }, - callback: async li => { - const actor = game.actors.get(li.dataset.entryId); - if (!actor) throw new Error('Unexpected missing actor'); + callback: async li => { + const actor = game.actors.get(li.dataset.entryId); + if (!actor) throw new Error('Unexpected missing actor'); - await game.settings.set(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty, actor.id); - ui.actors.render(); + const tiers = [1, 2, 3, 4].filter(t => t !== actor.system.tier); + const content = document.createElement('div'); + const select = document.createElement('select'); + select.name = 'tier'; + select.append( + ...tiers.map(t => { + const option = document.createElement('option'); + option.value = t; + option.textContent = game.i18n.localize(`DAGGERHEART.GENERAL.Tiers.${t}`); + return option; + }) + ); + content.append(select); + + const tier = await foundry.applications.api.Dialog.input({ + classes: ['dh-style', 'dialog'], + window: { title: 'DAGGERHEART.UI.Sidebar.actorDirectory.pickTierTitle' }, + content, + ok: { + label: 'Create Adversary', + callback: (event, button, dialog) => Number(button.form.elements.tier.value) + } + }); + + if (tier === actor.system.tier) { + ui.notifications.warn('This actor is already at this tier'); + } else if (tier) { + const source = actor.system.adjustForTier(tier); + await Actor.create(source); + ui.notifications.info(`Tier ${tier} ${actor.name} created`); } } - ); + }); return options; } diff --git a/module/applications/ui/chatLog.mjs b/module/applications/ui/chatLog.mjs index 34b25591..8cbacb09 100644 --- a/module/applications/ui/chatLog.mjs +++ b/module/applications/ui/chatLog.mjs @@ -1,6 +1,8 @@ +import { abilities } from '../../config/actorConfig.mjs'; import { enrichedDualityRoll } from '../../enrichers/DualityRollEnricher.mjs'; import { enrichedFateRoll, getFateTypeData } from '../../enrichers/FateRollEnricher.mjs'; import { getCommandTarget, rollCommandToJSON } from '../../helpers/utils.mjs'; +import { emitAsGM, GMUpdateEvent } from '../../systemRegistration/socket.mjs'; export default class DhpChatLog extends foundry.applications.sidebar.tabs.ChatLog { constructor(options) { @@ -103,10 +105,23 @@ export default class DhpChatLog extends foundry.applications.sidebar.tabs.ChatLo _getEntryContextOptions() { return [ ...super._getEntryContextOptions(), + // { + // name: 'Reroll', + // icon: '', + // condition: li => { + // const message = game.messages.get(li.dataset.messageId); + + // return (game.user.isGM || message.isAuthor) && message.rolls.length > 0; + // }, + // callback: li => { + // const message = game.messages.get(li.dataset.messageId); + // new game.system.api.applications.dialogs.RerollDialog(message).render({ force: true }); + // } + // }, { - label: 'DAGGERHEART.UI.ChatLog.rerollDamage', + name: game.i18n.localize('DAGGERHEART.UI.ChatLog.rerollDamage'), icon: '', - visible: li => { + condition: li => { const message = game.messages.get(li.dataset.messageId); const hasRolledDamage = message.system.hasDamage ? Object.keys(message.system.damage).length > 0 @@ -135,6 +150,18 @@ export default class DhpChatLog extends foundry.applications.sidebar.tabs.ChatLo html.querySelectorAll('.reroll-button').forEach(element => element.addEventListener('click', event => this.rerollEvent(event, message)) ); + html.querySelectorAll('.group-roll-button').forEach(element => + element.addEventListener('click', event => this.groupRollButton(event, message)) + ); + html.querySelectorAll('.group-roll-reroll').forEach(element => + element.addEventListener('click', event => this.groupRollReroll(event, message)) + ); + html.querySelectorAll('.group-roll-success').forEach(element => + element.addEventListener('click', event => this.groupRollSuccessEvent(event, message)) + ); + html.querySelectorAll('.group-roll-header-expand-section').forEach(element => + element.addEventListener('click', this.groupRollExpandSection) + ); html.querySelectorAll('.risk-it-all-button').forEach(element => element.addEventListener('click', event => this.riskItAllClearStressAndHitPoints(event, data)) ); @@ -278,6 +305,174 @@ export default class DhpChatLog extends foundry.applications.sidebar.tabs.ChatLo } } + async groupRollButton(event, message) { + const path = event.currentTarget.dataset.path; + const isLeader = path === 'leader'; + const { actor: actorData, trait } = foundry.utils.getProperty(message.system, path); + const actor = game.actors.get(actorData._id); + + if (!actor) { + return ui.notifications.error( + game.i18n.format('DAGGERHEART.UI.Notifications.documentIsMissing', { + documentType: game.i18n.localize('TYPES.Actor.character') + }) + ); + } + + if (!actor.testUserPermission(game.user, 'OWNER')) { + return ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.noActorOwnership')); + } + + const traitLabel = game.i18n.localize(abilities[trait].label); + const config = { + event: event, + title: `${game.i18n.localize('DAGGERHEART.GENERAL.dualityRoll')}: ${actor.name}`, + headerTitle: game.i18n.format('DAGGERHEART.UI.Chat.dualityRoll.abilityCheckTitle', { + ability: traitLabel + }), + roll: { + trait: trait, + advantage: 0, + modifiers: [{ label: traitLabel, value: actor.system.traits[trait].value }] + }, + hasRoll: true, + skips: { + createMessage: true, + resources: !isLeader, + updateCountdowns: !isLeader + } + }; + const result = await actor.diceRoll({ + ...config, + headerTitle: `${game.i18n.localize('DAGGERHEART.GENERAL.dualityRoll')}: ${actor.name}`, + title: game.i18n.format('DAGGERHEART.UI.Chat.dualityRoll.abilityCheckTitle', { + ability: traitLabel + }) + }); + + if (!result) return; + + const newMessageData = foundry.utils.deepClone(message.system); + foundry.utils.setProperty(newMessageData, `${path}.result`, result.roll); + const renderData = { system: new game.system.api.models.chatMessages.config.groupRoll(newMessageData) }; + + const updatedContent = await foundry.applications.handlebars.renderTemplate( + 'systems/daggerheart/templates/ui/chat/groupRoll.hbs', + { ...renderData, user: game.user } + ); + const mess = game.messages.get(message._id); + + await emitAsGM( + GMUpdateEvent.UpdateDocument, + mess.update.bind(mess), + { + ...renderData, + content: updatedContent + }, + mess.uuid + ); + } + + async groupRollReroll(event, message) { + const path = event.currentTarget.dataset.path; + const { actor: actorData, trait } = foundry.utils.getProperty(message.system, path); + const actor = game.actors.get(actorData._id); + + if (!actor.testUserPermission(game.user, 'OWNER')) { + return ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.noActorOwnership')); + } + + const traitLabel = game.i18n.localize(abilities[trait].label); + + const config = { + event: event, + title: `${game.i18n.localize('DAGGERHEART.GENERAL.dualityRoll')}: ${actor.name}`, + headerTitle: game.i18n.format('DAGGERHEART.UI.Chat.dualityRoll.abilityCheckTitle', { + ability: traitLabel + }), + roll: { + trait: trait, + advantage: 0, + modifiers: [{ label: traitLabel, value: actor.system.traits[trait].value }] + }, + hasRoll: true, + skips: { + createMessage: true, + updateCountdowns: true + } + }; + const result = await actor.diceRoll({ + ...config, + headerTitle: `${game.i18n.localize('DAGGERHEART.GENERAL.dualityRoll')}: ${actor.name}`, + title: game.i18n.format('DAGGERHEART.UI.Chat.dualityRoll.abilityCheckTitle', { + ability: traitLabel + }) + }); + + const newMessageData = foundry.utils.deepClone(message.system); + foundry.utils.setProperty(newMessageData, `${path}.result`, { ...result.roll, rerolled: true }); + const renderData = { system: new game.system.api.models.chatMessages.config.groupRoll(newMessageData) }; + + const updatedContent = await foundry.applications.handlebars.renderTemplate( + 'systems/daggerheart/templates/ui/chat/groupRoll.hbs', + { ...renderData, user: game.user } + ); + const mess = game.messages.get(message._id); + await emitAsGM( + GMUpdateEvent.UpdateDocument, + mess.update.bind(mess), + { + ...renderData, + content: updatedContent + }, + mess.uuid + ); + } + + async groupRollSuccessEvent(event, message) { + if (!game.user.isGM) { + return ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.gmOnly')); + } + + const { path, success } = event.currentTarget.dataset; + const { actor: actorData } = foundry.utils.getProperty(message.system, path); + const actor = game.actors.get(actorData._id); + + if (!actor.testUserPermission(game.user, 'OWNER')) { + return ui.notifications.warn(game.i18n.localize('DAGGERHEART.UI.Notifications.noActorOwnership')); + } + + const newMessageData = foundry.utils.deepClone(message.system); + foundry.utils.setProperty(newMessageData, `${path}.manualSuccess`, Boolean(success)); + const renderData = { system: new game.system.api.models.chatMessages.config.groupRoll(newMessageData) }; + + const updatedContent = await foundry.applications.handlebars.renderTemplate( + 'systems/daggerheart/templates/ui/chat/groupRoll.hbs', + { ...renderData, user: game.user } + ); + const mess = game.messages.get(message._id); + await emitAsGM( + GMUpdateEvent.UpdateDocument, + mess.update.bind(mess), + { + ...renderData, + content: updatedContent + }, + mess.uuid + ); + } + + async groupRollExpandSection(event) { + event.target + .closest('.group-roll-header-expand-section') + .querySelectorAll('i') + .forEach(element => { + element.classList.toggle('fa-angle-up'); + element.classList.toggle('fa-angle-down'); + }); + event.target.closest('.group-roll-section').querySelector('.group-roll-content').classList.toggle('closed'); + } + async riskItAllClearStressAndHitPoints(event, data) { const resourceValue = event.target.dataset.resourceValue; const actor = game.actors.get(event.target.dataset.actorId); diff --git a/module/applications/ui/combatTracker.mjs b/module/applications/ui/combatTracker.mjs index fb19a17e..1043e128 100644 --- a/module/applications/ui/combatTracker.mjs +++ b/module/applications/ui/combatTracker.mjs @@ -84,15 +84,15 @@ export default class DhCombatTracker extends foundry.applications.sidebar.tabs.C _getCombatContextOptions() { return [ { - label: 'COMBAT.ClearMovementHistories', + name: 'COMBAT.ClearMovementHistories', icon: '', - visible: () => game.user.isGM && this.viewed?.combatants.size > 0, + condition: () => game.user.isGM && this.viewed?.combatants.size > 0, callback: () => this.viewed.clearMovementHistories() }, { - label: 'COMBAT.Delete', + name: 'COMBAT.Delete', icon: '', - visible: () => game.user.isGM && !!this.viewed, + condition: () => game.user.isGM && !!this.viewed, callback: () => this.viewed.endCombat() } ]; diff --git a/module/applications/ui/countdowns.mjs b/module/applications/ui/countdowns.mjs index 79a59a07..0f83a05f 100644 --- a/module/applications/ui/countdowns.mjs +++ b/module/applications/ui/countdowns.mjs @@ -137,8 +137,6 @@ export default class DhCountdowns extends HandlebarsApplicationMixin(Application } static #getPlayerOwnership(user, setting, countdown) { - if (user.isGM) return CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER; - const playerOwnership = countdown.ownership[user.id]; return playerOwnership === undefined || playerOwnership === CONST.DOCUMENT_OWNERSHIP_LEVELS.INHERIT ? setting.defaultOwnership diff --git a/module/applications/ui/fearTracker.mjs b/module/applications/ui/fearTracker.mjs index 4e5e1132..82dda215 100644 --- a/module/applications/ui/fearTracker.mjs +++ b/module/applications/ui/fearTracker.mjs @@ -22,7 +22,7 @@ export default class FearTracker extends HandlebarsApplicationMixin(ApplicationV tag: 'div', window: { frame: true, - title: 'DAGGERHEART.GENERAL.fear', + title: 'Fear', positioned: true, resizable: true, minimizable: false diff --git a/module/applications/ui/itemBrowser.mjs b/module/applications/ui/itemBrowser.mjs index 67a16f6a..2d2e8cdc 100644 --- a/module/applications/ui/itemBrowser.mjs +++ b/module/applications/ui/itemBrowser.mjs @@ -37,7 +37,7 @@ export class ItemBrowser extends HandlebarsApplicationMixin(ApplicationV2) { tag: 'div', window: { frame: true, - title: 'DAGGERHEART.UI.ItemBrowser.windowTitle', + title: 'Compendium Browser', icon: 'fa-solid fa-book-atlas', positioned: true, resizable: true @@ -207,23 +207,8 @@ export class ItemBrowser extends HandlebarsApplicationMixin(ApplicationV2) { label: game.i18n.localize(col.label) })); - const splitPath = folderId?.split('.') ?? []; - const { pathLabels } = splitPath.reduce( - (acc, curr) => { - acc.currentPath = !acc.currentPath ? curr : [acc.currentPath, curr].join('.'); - if (curr === 'folder') return acc; - - const label = foundry.utils.getProperty(this.config, acc.currentPath)?.label; - if (label) acc.pathLabels.push(game.i18n.localize(label)); - - return acc; - }, - { pathLabels: [], currentPath: '' } - ); - this.selectedMenu = { - path: splitPath, - pathLabels: pathLabels, + path: folderId?.split('.') ?? [], data: { ...folderData, columns: columns @@ -583,9 +568,7 @@ export class ItemBrowser extends HandlebarsApplicationMixin(ApplicationV2) { const { itemUuid } = event.target.closest('[data-item-uuid]').dataset, item = await foundry.utils.fromUuid(itemUuid), dragData = item.toDragData(); - event.dataTransfer.setData('text/plain', JSON.stringify(dragData)); - event.dataTransfer.setDragImage(event.target.querySelector('img'), 0, 0); } _canDragStart() { diff --git a/module/applications/ux/contextMenu.mjs b/module/applications/ux/contextMenu.mjs index 0b208585..4e4ec6a4 100644 --- a/module/applications/ux/contextMenu.mjs +++ b/module/applications/ux/contextMenu.mjs @@ -6,11 +6,8 @@ export default class DHContextMenu extends foundry.applications.ux.ContextMenu { static triggerContextMenu(event, altSelector) { event.preventDefault(); event.stopPropagation(); - - const selector = altSelector ?? '[data-item-uuid]'; - if (ui.context?.selector === selector) return; - const { clientX, clientY } = event; + const selector = altSelector ?? '[data-item-uuid]'; const target = event.target.closest(selector) ?? event.currentTarget.closest(selector); target?.dispatchEvent( new PointerEvent('contextmenu', { diff --git a/module/applications/ux/filter-menu.mjs b/module/applications/ux/filter-menu.mjs index 791c0e1f..065d08f9 100644 --- a/module/applications/ux/filter-menu.mjs +++ b/module/applications/ux/filter-menu.mjs @@ -188,7 +188,7 @@ export default class FilterMenu extends foundry.applications.ux.ContextMenu { })); const damageTypeFilter = Object.values(CONFIG.DH.GENERAL.damageTypes).map(({ id, abbreviation }) => ({ - group: game.i18n.localize('DAGGERHEART.GENERAL.damageType'), + group: 'Damage Type', //TODO localize name: game.i18n.localize(abbreviation), filter: { field: 'system.damage.type', diff --git a/module/canvas/placeables/regionLayer.mjs b/module/canvas/placeables/regionLayer.mjs index c53cf782..81fd96db 100644 --- a/module/canvas/placeables/regionLayer.mjs +++ b/module/canvas/placeables/regionLayer.mjs @@ -95,61 +95,4 @@ export default class DhRegionLayer extends foundry.canvas.layers.RegionLayer { }); return inBounds.length === 1 ? inBounds[0] : null; } - - static getTemplateShape({ type, angle, range, direction } = {}) { - const { line, rectangle, inFront, cone, circle, emanation } = CONFIG.DH.GENERAL.templateTypes; - - /* Length calculation */ - const { grid, distance } = CONFIG.Scene.documentClass.schema.fields.grid.fields; - const sceneGridSize = canvas.scene?.grid.size ?? grid.size.initial; - const sceneGridDistance = canvas.scene?.grid.distance ?? distance.getInitialValue(); - const dimensionConstant = sceneGridSize / sceneGridDistance; - - const settings = canvas.scene?.rangeSettings; - const rangeNumber = Number(range); - const length = (!Number.isNaN(rangeNumber) ? rangeNumber : settings ? settings[range] : 0) * dimensionConstant; - /*----*/ - - const shapeData = { - ...canvas.mousePosition, - type: type, - direction: direction ?? 0 - }; - - switch (type) { - case rectangle.id: - shapeData.width = length; - shapeData.height = length; - break; - case line.id: - shapeData.length = length; - shapeData.width = 5 * dimensionConstant; - break; - case cone.id: - shapeData.angle = angle ?? CONFIG.MeasuredTemplate.defaults.angle; - shapeData.radius = length; - break; - case inFront.id: - shapeData.angle = '180'; - shapeData.radius = length; - shapeData.type = cone.id; - break; - case circle.id: - shapeData.radius = length; - break; - case emanation.id: - shapeData.radius = length; - shapeData.base = { - type: 'token', - x: 0, - y: 0, - width: 1, - height: 1, - shape: game.canvas.grid.isHexagonal ? CONST.TOKEN_SHAPES.ELLIPSE_1 : CONST.TOKEN_SHAPES.RECTANGLE_1 - }; - break; - } - - return shapeData; - } } diff --git a/module/canvas/tokens.mjs b/module/canvas/tokens.mjs index 9ca140e0..9813cd48 100644 --- a/module/canvas/tokens.mjs +++ b/module/canvas/tokens.mjs @@ -1 +1,16 @@ -export default class DhTokenLayer extends foundry.canvas.layers.TokenLayer {} +export default class DhTokenLayer extends foundry.canvas.layers.TokenLayer { + async _createPreview(createData, options) { + if (options.actor) { + const tokenSizes = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).tokenSizes; + if (options.actor?.system.metadata.usesSize) { + const tokenSize = tokenSizes[options.actor.system.size]; + if (tokenSize && options.actor.system.size !== CONFIG.DH.ACTOR.tokenSize.custom.id) { + createData.width = tokenSize; + createData.height = tokenSize; + } + } + } + + return super._createPreview(createData, options); + } +} diff --git a/module/config/actionConfig.mjs b/module/config/actionConfig.mjs index a6c04e18..0b1bf91d 100644 --- a/module/config/actionConfig.mjs +++ b/module/config/actionConfig.mjs @@ -115,10 +115,3 @@ export const advantageState = { value: 1 } }; - -export const areaTypes = { - placed: { - id: 'placed', - label: 'Placed Area' - } -}; diff --git a/module/config/generalConfig.mjs b/module/config/generalConfig.mjs index 6fc85ec5..f3484e43 100644 --- a/module/config/generalConfig.mjs +++ b/module/config/generalConfig.mjs @@ -70,40 +70,14 @@ export const range = { } }; -export const groupAttackRange = { - melee: range.melee, - veryClose: range.veryClose, - close: range.close, - far: range.far, - veryFar: range.veryFar -}; - /* circle|cone|rect|ray used to be CONST.MEASURED_TEMPLATE_TYPES. Hardcoded for now */ export const templateTypes = { - circle: { - id: 'circle', - label: 'Circle' - }, - cone: { - id: 'cone', - label: 'Cone' - }, - rectangle: { - id: 'rectangle', - label: 'Rectangle' - }, - line: { - id: 'line', - label: 'Line' - }, - emanation: { - id: 'emanation', - label: 'Emanation' - }, - inFront: { - id: 'inFront', - label: 'In Front' - } + CIRCLE: 'circle', + CONE: 'cone', + RECTANGLE: 'rectangle', + LINE: 'line', + EMANATION: 'emanation', + INFRONT: 'inFront' }; export const rangeInclusion = { @@ -510,7 +484,7 @@ export const defaultRestOptions = { value: { custom: { enabled: true, - formula: '@system.armorScore.max' + formula: '@system.armorScore' } } } @@ -734,14 +708,14 @@ const getDiceSoNiceSFX = sfxOptions => { if (sfxOptions.critical && criticalAnimationData.class) { return { specialEffect: criticalAnimationData.class, - options: { ...criticalAnimationData.options } + options: {} }; } if (sfxOptions.higher && sfxOptions.data.higher) { return { specialEffect: sfxOptions.data.higher.class, - options: { ...sfxOptions.data.higher.options } + options: {} }; } @@ -973,15 +947,15 @@ export const countdownAppMode = { export const sceneRangeMeasurementSetting = { disable: { id: 'disable', - label: 'DAGGERHEART.CONFIG.SceneRangeMeasurementTypes.disable' + label: 'Disable Daggerheart Range Measurement' }, default: { id: 'default', - label: 'DAGGERHEART.CONFIG.SceneRangeMeasurementTypes.default' + label: 'Default' }, custom: { id: 'custom', - label: 'DAGGERHEART.CONFIG.SceneRangeMeasurementTypes.custom' + label: 'Custom' } }; @@ -1110,18 +1084,3 @@ export const fallAndCollisionDamage = { damageFormula: '1d20 + 5' } }; - -export const simpleDispositions = { - [-1]: { - id: -1, - label: 'TOKEN.DISPOSITION.HOSTILE' - }, - [0]: { - id: 0, - label: 'TOKEN.DISPOSITION.NEUTRAL' - }, - [1]: { - id: 1, - label: 'TOKEN.DISPOSITION.FRIENDLY' - } -}; diff --git a/module/config/hooksConfig.mjs b/module/config/hooksConfig.mjs index c0930d90..8d04be6d 100644 --- a/module/config/hooksConfig.mjs +++ b/module/config/hooksConfig.mjs @@ -1,6 +1,5 @@ export const hooksConfig = { effectDisplayToggle: 'DHEffectDisplayToggle', lockedTooltipDismissed: 'DHLockedTooltipDismissed', - tagTeamStart: 'DHTagTeamRollStart', - groupRollStart: 'DHGroupRollStart' + tagTeamStart: 'DHTagTeamRollStart' }; diff --git a/module/config/itemBrowserConfig.mjs b/module/config/itemBrowserConfig.mjs index 5c0a219b..3b10409c 100644 --- a/module/config/itemBrowserConfig.mjs +++ b/module/config/itemBrowserConfig.mjs @@ -7,12 +7,7 @@ export const typeConfig = { }, { key: 'system.type', - label: 'DAGGERHEART.GENERAL.type', - format: type => { - if (!type) return '-'; - - return CONFIG.DH.ACTOR.allAdversaryTypes()[type].label; - } + label: 'DAGGERHEART.GENERAL.type' } ], filters: [ @@ -74,18 +69,12 @@ export const typeConfig = { columns: [ { key: 'type', - label: 'DAGGERHEART.GENERAL.type', - format: type => (type ? `TYPES.Item.${type}` : '-') + label: 'DAGGERHEART.GENERAL.type' }, { key: 'system.secondary', label: 'DAGGERHEART.UI.ItemBrowser.subtype', - format: isSecondary => - isSecondary - ? 'DAGGERHEART.ITEMS.Weapon.secondaryWeapon.short' - : isSecondary === false - ? 'DAGGERHEART.ITEMS.Weapon.primaryWeapon.short' - : '-' + format: isSecondary => (isSecondary ? 'secondary' : isSecondary === false ? 'primary' : '-') }, { key: 'system.tier', @@ -105,8 +94,8 @@ export const typeConfig = { key: 'system.secondary', label: 'DAGGERHEART.UI.ItemBrowser.subtype', choices: [ - { value: false, label: 'DAGGERHEART.ITEMS.Weapon.primaryWeapon.full' }, - { value: true, label: 'DAGGERHEART.ITEMS.Weapon.secondaryWeapon.full' } + { value: false, label: 'DAGGERHEART.ITEMS.Weapon.primaryWeapon' }, + { value: true, label: 'DAGGERHEART.ITEMS.Weapon.secondaryWeapon' } ] }, { @@ -264,13 +253,11 @@ export const typeConfig = { columns: [ { key: 'system.type', - label: 'DAGGERHEART.GENERAL.type', - format: type => (type ? `DAGGERHEART.CONFIG.DomainCardTypes.${type}` : '-') + label: 'DAGGERHEART.GENERAL.type' }, { key: 'system.domain', - label: 'DAGGERHEART.GENERAL.Domain.single', - format: domain => (domain ? CONFIG.DH.DOMAIN.allDomains()[domain].label : '-') + label: 'DAGGERHEART.GENERAL.Domain.single' }, { key: 'system.level', @@ -331,14 +318,7 @@ export const typeConfig = { }, { key: 'system.domains', - label: 'DAGGERHEART.GENERAL.Domain.plural', - format: domains => { - const config = CONFIG.DH.DOMAIN.allDomains(); - return domains - .map(x => (x ? game.i18n.localize(config[x].label) : null)) - .filter(x => x) - .join(', '); - } + label: 'DAGGERHEART.GENERAL.Domain.plural' } ], filters: [ @@ -382,19 +362,18 @@ export const typeConfig = { columns: [ { key: 'system.linkedClass', - label: 'TYPES.Item.class', + label: 'Class', format: linkedClass => linkedClass?.name ?? 'DAGGERHEART.UI.ItemBrowser.missing' }, { key: 'system.spellcastingTrait', - label: 'DAGGERHEART.ITEMS.Subclass.spellcastingTrait', - format: trait => (trait ? `DAGGERHEART.CONFIG.Traits.${trait}.name` : '-') + label: 'DAGGERHEART.ITEMS.Subclass.spellcastingTrait' } ], filters: [ { key: 'system.linkedClass.uuid', - label: 'TYPES.Item.class', + label: 'Class', choices: items => { const list = items .filter(item => item.system.linkedClass) @@ -418,8 +397,7 @@ export const typeConfig = { }, { key: 'system.mainTrait', - label: 'DAGGERHEART.GENERAL.Trait.single', - format: trait => (trait ? `DAGGERHEART.CONFIG.Traits.${trait}.name` : '-') + label: 'DAGGERHEART.GENERAL.Trait.single' } ], filters: [ diff --git a/module/config/settingsConfig.mjs b/module/config/settingsConfig.mjs index 50841084..de4d96be 100644 --- a/module/config/settingsConfig.mjs +++ b/module/config/settingsConfig.mjs @@ -1,6 +1,5 @@ export const keybindings = { - spotlight: 'DHSpotlight', - partySheet: 'DHPartySheet' + spotlight: 'DHSpotlight' }; export const menu = { @@ -41,21 +40,24 @@ export const gameSettings = { LastMigrationVersion: 'LastMigrationVersion', SpotlightRequestQueue: 'SpotlightRequestQueue', CompendiumBrowserSettings: 'CompendiumBrowserSettings', - SpotlightTracker: 'SpotlightTracker', - ActiveParty: 'ActiveParty' + SpotlightTracker: 'SpotlightTracker' }; export const actionAutomationChoices = { never: { id: 'never', - label: 'DAGGERHEART.CONFIG.ActionAutomationChoices.never' + label: 'Never' }, showDialog: { id: 'showDialog', - label: 'DAGGERHEART.CONFIG.ActionAutomationChoices.showDialog' + label: 'Show Dialog only' }, + // npcOnly: { + // id: "npcOnly", + // label: "Always for non-characters" + // }, always: { id: 'always', - label: 'DAGGERHEART.CONFIG.ActionAutomationChoices.always' + label: 'Always' } }; diff --git a/module/data/_module.mjs b/module/data/_module.mjs index a54da0e1..0e7e295e 100644 --- a/module/data/_module.mjs +++ b/module/data/_module.mjs @@ -4,7 +4,6 @@ export { default as DhRollTable } from './rollTable.mjs'; export { default as RegisteredTriggers } from './registeredTriggers.mjs'; export { default as CompendiumBrowserSettings } from './compendiumBrowserSettings.mjs'; export { default as TagTeamData } from './tagTeamData.mjs'; -export { default as GroupRollData } from './groupRollData.mjs'; export { default as SpotlightTracker } from './spotlightTracker.mjs'; export * as countdowns from './countdowns.mjs'; @@ -15,4 +14,3 @@ export * as chatMessages from './chat-message/_modules.mjs'; export * as fields from './fields/_module.mjs'; export * as items from './item/_module.mjs'; export * as scenes from './scene/_module.mjs'; -export * as regionBehaviors from './regionBehavior/_module.mjs'; diff --git a/module/data/action/attackAction.mjs b/module/data/action/attackAction.mjs index 15cc1696..a2d47309 100644 --- a/module/data/action/attackAction.mjs +++ b/module/data/action/attackAction.mjs @@ -13,7 +13,7 @@ export default class DHAttackAction extends DHDamageAction { if (!!this.item?.system?.attack) { if (this.damage.includeBase) { const baseDamage = this.getParentDamage(); - this.damage.parts.hitPoints = new DHDamageData(baseDamage); + this.damage.parts.unshift(new DHDamageData(baseDamage)); } if (this.roll.useDefault) { this.roll.trait = this.item.system.attack.roll.trait; @@ -51,7 +51,7 @@ export default class DHAttackAction extends DHDamageAction { async use(event, options) { const result = await super.use(event, options); - if (result?.message?.system.action?.roll?.type === 'attack') { + if (result.message?.system.action.roll?.type === 'attack') { const { updateCountdowns } = game.system.api.applications.ui.DhCountdowns; await updateCountdowns(CONFIG.DH.GENERAL.countdownProgressionTypes.characterAttack.id); } diff --git a/module/data/action/baseAction.mjs b/module/data/action/baseAction.mjs index b3775dc9..1f75d382 100644 --- a/module/data/action/baseAction.mjs +++ b/module/data/action/baseAction.mjs @@ -15,7 +15,7 @@ const fields = foundry.data.fields; */ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel) { - static extraSchemas = ['areas', 'cost', 'uses', 'range']; + static extraSchemas = ['cost', 'uses', 'range']; /** @inheritDoc */ static defineSchema() { @@ -110,11 +110,6 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel return this._id; } - /** Returns true if the current user is the owner of the containing item */ - get isOwner() { - return this.item?.isOwner ?? true; - } - /** * Return Item the action is attached too. */ @@ -148,12 +143,6 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel : null; } - /** Returns true if the action is usable */ - get usable() { - const actor = this.actor; - return this.isOwner && actor?.type === 'character'; - } - static getRollType(parent) { return 'trait'; } @@ -291,26 +280,6 @@ export default class DHBaseAction extends ActionMixin(foundry.abstract.DataModel } }; - if (this.damage) { - config.isDirect = this.damage.direct; - - const groupAttackTokens = this.damage.groupAttack - ? game.system.api.fields.ActionFields.DamageField.getGroupAttackTokens( - this.actor.id, - this.damage.groupAttack - ) - : null; - - config.damageOptions = { - groupAttack: this.damage.groupAttack - ? { - numAttackers: Math.max(groupAttackTokens.length, 1), - range: this.damage.groupAttack - } - : null - }; - } - DHBaseAction.applyKeybindings(config); return config; } diff --git a/module/data/activeEffect/baseEffect.mjs b/module/data/activeEffect/baseEffect.mjs index 9b17164d..bac50c56 100644 --- a/module/data/activeEffect/baseEffect.mjs +++ b/module/data/activeEffect/baseEffect.mjs @@ -93,12 +93,6 @@ export default class BaseEffect extends foundry.data.ActiveEffectTypeDataModel { max: new fields.NumberField({ integer: true, label: 'DAGGERHEART.GENERAL.max' }) }, { nullable: true, initial: null } - ), - targetDispositions: new fields.SetField( - new fields.NumberField({ - choices: CONFIG.DH.GENERAL.simpleDispositions - }), - { label: 'DAGGERHEART.ACTIVEEFFECT.Config.targetDispositions' } ) }; } @@ -137,14 +131,13 @@ export default class BaseEffect extends foundry.data.ActiveEffectTypeDataModel { return armorChange.getArmorData(); } - static getDefaultObject(options = { transfer: true }) { + static getDefaultObject() { return { name: 'New Effect', id: foundry.utils.randomID(), disabled: false, img: 'icons/magic/life/heart-cross-blue.webp', description: '', - transfer: options.transfer, statuses: [], changes: [], system: { diff --git a/module/data/activeEffect/changeTypes/armor.mjs b/module/data/activeEffect/changeTypes/armor.mjs index 217ff9dd..713ef03d 100644 --- a/module/data/activeEffect/changeTypes/armor.mjs +++ b/module/data/activeEffect/changeTypes/armor.mjs @@ -82,7 +82,7 @@ export default class ArmorChange extends foundry.abstract.DataModel { { ...change, key: 'system.damageThresholds.major', - type: CONFIG.DH.GENERAL.activeEffectModes.add.id, + type: CONFIG.DH.GENERAL.activeEffectModes.override.id, priority: 50, value: major }, @@ -96,7 +96,7 @@ export default class ArmorChange extends foundry.abstract.DataModel { { ...change, key: 'system.damageThresholds.severe', - type: CONFIG.DH.GENERAL.activeEffectModes.add.id, + type: CONFIG.DH.GENERAL.activeEffectModes.override.id, priority: 50, value: severe }, @@ -111,8 +111,6 @@ export default class ArmorChange extends foundry.abstract.DataModel { }; get isSuppressed() { - if (!this.parent.parent?.actor) return false; - switch (this.value.interaction) { case CONFIG.DH.GENERAL.activeEffectArmorInteraction.active.id: return !this.parent.parent?.actor.system.armor; diff --git a/module/data/actor/adversary.mjs b/module/data/actor/adversary.mjs index d30e090a..73673896 100644 --- a/module/data/actor/adversary.mjs +++ b/module/data/actor/adversary.mjs @@ -133,7 +133,7 @@ export default class DhpAdversary extends DhCreature { } isItemValid(source) { - return super.isItemValid(source) || source.type === 'feature'; + return source.type === 'feature'; } async _preUpdate(changes, options, user) { diff --git a/module/data/actor/base.mjs b/module/data/actor/base.mjs index 13ff0a38..89ba5db2 100644 --- a/module/data/actor/base.mjs +++ b/module/data/actor/base.mjs @@ -107,8 +107,7 @@ export default class BaseDataActor extends foundry.abstract.TypeDataModel { hasResistances: true, hasAttribution: false, hasLimitedView: true, - usesSize: false, - hasInventory: false + usesSize: false }; } @@ -169,11 +168,6 @@ export default class BaseDataActor extends foundry.abstract.TypeDataModel { /* -------------------------------------------- */ - isItemValid(source) { - const inventoryTypes = ['weapon', 'armor', 'consumable', 'loot']; - return this.metadata.hasInventory && inventoryTypes.includes(source.type); - } - /** * Obtain a data object used to evaluate any dice rolls associated with this Item Type * @param {object} [options] - Options which modify the getRollData method. diff --git a/module/data/actor/character.mjs b/module/data/actor/character.mjs index 1bb3560f..2878ad0c 100644 --- a/module/data/actor/character.mjs +++ b/module/data/actor/character.mjs @@ -3,7 +3,7 @@ import ForeignDocumentUUIDField from '../fields/foreignDocumentUUIDField.mjs'; import DhLevelData from '../levelData.mjs'; import { commonActorRules } from './base.mjs'; import DhCreature from './creature.mjs'; -import { attributeField, stressDamageReductionRule, bonusField, GoldField } from '../fields/actorField.mjs'; +import { attributeField, stressDamageReductionRule, bonusField } from '../fields/actorField.mjs'; import { ActionField } from '../fields/actionField.mjs'; import DHCharacterSettings from '../../applications/sheets-configs/character-settings.mjs'; import { getArmorSources } from '../../helpers/utils.mjs'; @@ -18,9 +18,7 @@ export default class DhCharacter extends DhCreature { label: 'TYPES.Actor.character', type: 'character', settingSheet: DHCharacterSettings, - isNPC: false, - hasInventory: true, - quantifiable: ['loot', 'consumable'] + isNPC: false }); } @@ -64,7 +62,12 @@ export default class DhCharacter extends DhCreature { core: new fields.BooleanField({ initial: false }) }) ), - gold: new GoldField(), + gold: new fields.SchemaField({ + coins: new fields.NumberField({ initial: 0, integer: true }), + handfuls: new fields.NumberField({ initial: 1, integer: true }), + bags: new fields.NumberField({ initial: 0, integer: true }), + chests: new fields.NumberField({ initial: 0, integer: true }) + }), scars: new fields.NumberField({ initial: 0, integer: true, label: 'DAGGERHEART.GENERAL.scars' }), biography: new fields.SchemaField({ background: new fields.HTMLField(), @@ -150,6 +153,7 @@ export default class DhCharacter extends DhCreature { shortMoves: new fields.NumberField({ required: true, integer: true, + min: 0, initial: 0, label: 'DAGGERHEART.GENERAL.Bonuses.rest.shortRest.shortRestMoves.label', hint: 'DAGGERHEART.GENERAL.Bonuses.rest.shortRest.shortRestMoves.hint' @@ -157,6 +161,7 @@ export default class DhCharacter extends DhCreature { longMoves: new fields.NumberField({ required: true, integer: true, + min: 0, initial: 0, label: 'DAGGERHEART.GENERAL.Bonuses.rest.shortRest.longRestMoves.label', hint: 'DAGGERHEART.GENERAL.Bonuses.rest.shortRest.longRestMoves.hint' @@ -166,6 +171,7 @@ export default class DhCharacter extends DhCreature { shortMoves: new fields.NumberField({ required: true, integer: true, + min: 0, initial: 0, label: 'DAGGERHEART.GENERAL.Bonuses.rest.longRest.shortRestMoves.label', hint: 'DAGGERHEART.GENERAL.Bonuses.rest.longRest.shortRestMoves.hint' @@ -173,6 +179,7 @@ export default class DhCharacter extends DhCreature { longMoves: new fields.NumberField({ required: true, integer: true, + min: 0, initial: 0, label: 'DAGGERHEART.GENERAL.Bonuses.rest.longRest.longRestMoves.label', hint: 'DAGGERHEART.GENERAL.Bonuses.rest.longRest.longRestMoves.hint' @@ -286,22 +293,6 @@ export default class DhCharacter extends DhCreature { guaranteedCritical: new fields.BooleanField({ label: 'DAGGERHEART.ACTORS.Character.roll.guaranteedCritical.label', hint: 'DAGGERHEART.ACTORS.Character.roll.guaranteedCritical.hint' - }), - defaultAdvantageDice: new fields.NumberField({ - nullable: true, - required: true, - integer: true, - choices: CONFIG.DH.GENERAL.dieFaces, - initial: null, - label: 'DAGGERHEART.ACTORS.Character.defaultAdvantageDice' - }), - defaultDisadvantageDice: new fields.NumberField({ - nullable: true, - required: true, - integer: true, - choices: CONFIG.DH.GENERAL.dieFaces, - initial: null, - label: 'DAGGERHEART.ACTORS.Character.defaultDisadvantageDice' }) }) }) @@ -447,11 +438,6 @@ export default class DhCharacter extends DhCreature { return attack; } - /* All items are valid on characters */ - isItemValid() { - return true; - } - /** @inheritDoc */ isItemAvailable(item) { if (!super.isItemAvailable(this)) return false; @@ -750,22 +736,13 @@ export default class DhCharacter extends DhCreature { } } - /* Armor and ArmorEffects can set a Base Damage Threshold. Characters only gain level*2 bonus to severe if this is not present */ - const severeThresholdMulitplier = - this.armor || - this.parent.appliedEffects.some(x => - x.system.changes.some(x => x.type === 'armor' && x.value.damageThresholds) - ) - ? 1 - : 2; - this.damageThresholds = { major: this.armor ? this.armor.system.baseThresholds.major + this.levelData.level.current : this.levelData.level.current, severe: this.armor ? this.armor.system.baseThresholds.severe + this.levelData.level.current - : this.levelData.level.current * severeThresholdMulitplier + : this.levelData.level.current * 2 }; const globalHopeMax = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).maxHope; diff --git a/module/data/actor/companion.mjs b/module/data/actor/companion.mjs index 538031fb..81d0aa8a 100644 --- a/module/data/actor/companion.mjs +++ b/module/data/actor/companion.mjs @@ -61,24 +61,6 @@ export default class DhCompanion extends DhCreature { initial: false, label: 'DAGGERHEART.GENERAL.Rules.conditionImmunities.vulnerable' }) - }), - roll: new fields.SchemaField({ - defaultAdvantageDice: new fields.NumberField({ - nullable: true, - required: true, - integer: true, - choices: CONFIG.DH.GENERAL.dieFaces, - initial: null, - label: 'DAGGERHEART.ACTORS.Character.defaultAdvantageDice' - }), - defaultDisadvantageDice: new fields.NumberField({ - nullable: true, - required: true, - integer: true, - choices: CONFIG.DH.GENERAL.dieFaces, - initial: null, - label: 'DAGGERHEART.ACTORS.Character.defaultDisadvantageDice' - }) }) }), attack: new ActionField({ @@ -136,6 +118,10 @@ export default class DhCompanion extends DhCreature { return this.levelupChoicesLeft > 0; } + isItemValid() { + return false; + } + prepareBaseData() { super.prepareBaseData(); this.attack.roll.bonus = this.partner?.system?.spellcastModifier ?? 0; diff --git a/module/data/actor/environment.mjs b/module/data/actor/environment.mjs index e037e004..e06f038c 100644 --- a/module/data/actor/environment.mjs +++ b/module/data/actor/environment.mjs @@ -56,7 +56,7 @@ export default class DhEnvironment extends BaseDataActor { } isItemValid(source) { - return super.isItemValid(source) || source.type === 'feature'; + return source.type === 'feature'; } _onUpdate(changes, options, userId) { diff --git a/module/data/actor/party.mjs b/module/data/actor/party.mjs index 93596cda..2c797803 100644 --- a/module/data/actor/party.mjs +++ b/module/data/actor/party.mjs @@ -1,18 +1,8 @@ import BaseDataActor from './base.mjs'; import ForeignDocumentUUIDArrayField from '../fields/foreignDocumentUUIDArrayField.mjs'; import TagTeamData from '../tagTeamData.mjs'; -import GroupRollData from '../groupRollData.mjs'; -import { GoldField } from '../fields/actorField.mjs'; export default class DhParty extends BaseDataActor { - /** @inheritdoc */ - static get metadata() { - return foundry.utils.mergeObject(super.metadata, { - hasInventory: true, - quantifiable: ['weapon', 'armor', 'loot', 'consumable'] - }); - } - /**@inheritdoc */ static defineSchema() { const fields = foundry.data.fields; @@ -20,16 +10,16 @@ export default class DhParty extends BaseDataActor { ...super.defineSchema(), partyMembers: new ForeignDocumentUUIDArrayField({ type: 'Actor' }, { prune: true }), notes: new fields.HTMLField(), - gold: new GoldField(), - tagTeam: new fields.EmbeddedDataField(TagTeamData), - groupRoll: new fields.EmbeddedDataField(GroupRollData) + gold: new fields.SchemaField({ + coins: new fields.NumberField({ initial: 0, integer: true }), + handfuls: new fields.NumberField({ initial: 1, integer: true }), + bags: new fields.NumberField({ initial: 0, integer: true }), + chests: new fields.NumberField({ initial: 0, integer: true }) + }), + tagTeam: new fields.EmbeddedDataField(TagTeamData) }; } - get active() { - return game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty) === this.parent.id; - } - /* -------------------------------------------- */ /**@inheritdoc */ @@ -37,6 +27,10 @@ export default class DhParty extends BaseDataActor { /* -------------------------------------------- */ + isItemValid(source) { + return ['weapon', 'armor', 'consumable', 'loot'].includes(source.type); + } + prepareBaseData() { super.prepareBaseData(); @@ -48,16 +42,6 @@ export default class DhParty extends BaseDataActor { } } - _onCreate(data, options, userId) { - super._onCreate(data, options, userId); - - if (game.user.isActiveGM && !game.actors.party) { - game.settings.set(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty, this.parent.id).then(_ => { - ui.actors.render(); - }); - } - } - _onDelete(options, userId) { super._onDelete(options, userId); @@ -65,11 +49,5 @@ export default class DhParty extends BaseDataActor { for (const member of this.partyMembers) { member?.parties?.delete(this.parent); } - - // If this *was* the active party, delete it. We can't use game.actors.party as this actor was already deleted - const isWorldActor = !this.parent?.parent && !this.parent.compendium; - const activePartyId = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty); - if (isWorldActor && this.id === activePartyId) - game.settings.set(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty, null); } } diff --git a/module/data/chat-message/_modules.mjs b/module/data/chat-message/_modules.mjs index 450d1ba2..c671de31 100644 --- a/module/data/chat-message/_modules.mjs +++ b/module/data/chat-message/_modules.mjs @@ -1,5 +1,6 @@ import DHAbilityUse from './abilityUse.mjs'; import DHActorRoll from './actorRoll.mjs'; +import DHGroupRoll from './groupRoll.mjs'; import DHSystemMessage from './systemMessage.mjs'; export const config = { @@ -8,5 +9,6 @@ export const config = { damageRoll: DHActorRoll, dualityRoll: DHActorRoll, fateRoll: DHActorRoll, + groupRoll: DHGroupRoll, systemMessage: DHSystemMessage }; diff --git a/module/data/chat-message/abilityUse.mjs b/module/data/chat-message/abilityUse.mjs index 465461c0..07209fe2 100644 --- a/module/data/chat-message/abilityUse.mjs +++ b/module/data/chat-message/abilityUse.mjs @@ -7,31 +7,26 @@ export default class DHAbilityUse extends foundry.abstract.TypeDataModel { img: new fields.StringField({}), name: new fields.StringField({}), description: new fields.StringField({}), - source: new fields.SchemaField({ - actor: new fields.StringField(), - item: new fields.StringField(), - action: new fields.StringField() - }) + actions: new fields.ArrayField( + new fields.ObjectField({ + name: new fields.StringField({}), + damage: new fields.SchemaField({ + type: new fields.StringField({}), + value: new fields.StringField({}) + }), + healing: new fields.SchemaField({ + type: new fields.StringField({}), + value: new fields.StringField({}) + }), + cost: new fields.SchemaField({ + type: new fields.StringField({}), + value: new fields.NumberField({}) + }), + target: new fields.SchemaField({ + type: new fields.StringField({ nullable: true }) + }) + }) + ) }; } - - get actionActor() { - if (!this.source.actor) return null; - return fromUuidSync(this.source.actor); - } - - get actionItem() { - const actionActor = this.actionActor; - if (!actionActor || !this.source.item) return null; - - const item = actionActor.items.get(this.source.item); - return item ? item.system.actions?.find(a => a.id === this.source.action) : null; - } - - get action() { - const { actionItem: itemAction } = this; - if (!this.source.action) return null; - if (itemAction) return itemAction; - return null; - } } diff --git a/module/data/chat-message/actorRoll.mjs b/module/data/chat-message/actorRoll.mjs index eaa1cdc2..89f34949 100644 --- a/module/data/chat-message/actorRoll.mjs +++ b/module/data/chat-message/actorRoll.mjs @@ -48,7 +48,6 @@ export default class DHActorRoll extends foundry.abstract.TypeDataModel { action: new fields.StringField() }), damage: new fields.ObjectField(), - damageOptions: new fields.ObjectField(), costs: new fields.ArrayField(new fields.ObjectField()), successConsumed: new fields.BooleanField({ initial: false }) }; diff --git a/module/data/chat-message/groupRoll.mjs b/module/data/chat-message/groupRoll.mjs new file mode 100644 index 00000000..a5308323 --- /dev/null +++ b/module/data/chat-message/groupRoll.mjs @@ -0,0 +1,39 @@ +import { abilities } from '../../config/actorConfig.mjs'; + +export default class DHGroupRoll extends foundry.abstract.TypeDataModel { + static defineSchema() { + const fields = foundry.data.fields; + + return { + leader: new fields.EmbeddedDataField(GroupRollMemberField), + members: new fields.ArrayField(new fields.EmbeddedDataField(GroupRollMemberField)) + }; + } + + get totalModifier() { + return this.members.reduce((acc, m) => { + if (m.manualSuccess === null) return acc; + + return acc + (m.manualSuccess ? 1 : -1); + }, 0); + } +} + +class GroupRollMemberField extends foundry.abstract.DataModel { + static defineSchema() { + const fields = foundry.data.fields; + + return { + actor: new fields.ObjectField(), + trait: new fields.StringField({ choices: abilities }), + difficulty: new fields.StringField(), + result: new fields.ObjectField({ nullable: true, initial: null }), + manualSuccess: new fields.BooleanField({ nullable: true, initial: null }) + }; + } + + /* Can be expanded if we handle automation of success/failure */ + get success() { + return manualSuccess; + } +} diff --git a/module/data/countdowns.mjs b/module/data/countdowns.mjs index 7d27197d..b944bf73 100644 --- a/module/data/countdowns.mjs +++ b/module/data/countdowns.mjs @@ -5,6 +5,10 @@ export default class DhCountdowns extends foundry.abstract.DataModel { const fields = foundry.data.fields; return { + /* Outdated and unused. Needed for migration. Remove in next minor version. (1.3) */ + narrative: new fields.EmbeddedDataField(DhCountdownData), + encounter: new fields.EmbeddedDataField(DhCountdownData), + /**/ countdowns: new fields.TypedObjectField(new fields.EmbeddedDataField(DhCountdown)), defaultOwnership: new fields.NumberField({ required: true, @@ -15,6 +19,122 @@ export default class DhCountdowns extends foundry.abstract.DataModel { } } +/* Outdated and unused. Needed for migration. Remove in next minor version. (1.3) */ +class DhCountdownData extends foundry.abstract.DataModel { + static defineSchema() { + const fields = foundry.data.fields; + return { + countdowns: new fields.TypedObjectField(new fields.EmbeddedDataField(DhOldCountdown)), + ownership: new fields.SchemaField({ + default: new fields.NumberField({ + required: true, + choices: Object.values(CONST.DOCUMENT_OWNERSHIP_LEVELS), + initial: CONST.DOCUMENT_OWNERSHIP_LEVELS.NONE + }), + players: new fields.TypedObjectField( + new fields.SchemaField({ + type: new fields.NumberField({ + required: true, + choices: Object.values(CONST.DOCUMENT_OWNERSHIP_LEVELS), + initial: CONST.DOCUMENT_OWNERSHIP_LEVELS.INHERIT + }) + }) + ) + }), + window: new fields.SchemaField({}) + }; + } + + get playerOwnership() { + return Array.from(game.users).reduce((acc, user) => { + acc[user.id] = { + value: user.isGM + ? CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER + : this.ownership.players[user.id] && this.ownership.players[user.id].type !== -1 + ? this.ownership.players[user.id].type + : this.ownership.default, + isGM: user.isGM + }; + + return acc; + }, {}); + } +} + +/* Outdated and unused. Needed for migration. Remove in next minor version. (1.3) */ +class DhOldCountdown extends foundry.abstract.DataModel { + static defineSchema() { + const fields = foundry.data.fields; + return { + name: new fields.StringField({ + required: true, + label: 'DAGGERHEART.APPLICATIONS.Countdown.FIELDS.countdowns.element.name.label' + }), + img: new fields.FilePathField({ + categories: ['IMAGE'], + base64: false, + initial: 'icons/magic/time/hourglass-yellow-green.webp' + }), + ownership: new fields.SchemaField({ + default: new fields.NumberField({ + required: true, + choices: Object.values(CONST.DOCUMENT_OWNERSHIP_LEVELS), + initial: CONST.DOCUMENT_OWNERSHIP_LEVELS.NONE + }), + players: new fields.TypedObjectField( + new fields.SchemaField({ + type: new fields.NumberField({ + required: true, + choices: Object.values(CONST.DOCUMENT_OWNERSHIP_LEVELS), + initial: CONST.DOCUMENT_OWNERSHIP_LEVELS.INHERIT + }) + }) + ) + }), + progress: new fields.SchemaField({ + current: new fields.NumberField({ + required: true, + integer: true, + initial: 1, + label: 'DAGGERHEART.APPLICATIONS.Countdown.FIELDS.countdowns.element.progress.current.label' + }), + max: new fields.NumberField({ + required: true, + integer: true, + initial: 1, + label: 'DAGGERHEART.APPLICATIONS.Countdown.FIELDS.countdowns.element.progress.max.label' + }), + type: new fields.SchemaField({ + value: new fields.StringField({ + required: true, + choices: CONFIG.DH.GENERAL.countdownProgressionTypes, + initial: CONFIG.DH.GENERAL.countdownProgressionTypes.custom.id, + label: 'DAGGERHEART.GENERAL.type' + }), + label: new fields.StringField({ + label: 'DAGGERHEART.APPLICATIONS.Countdown.FIELDS.countdowns.element.progress.type.label.label' + }) + }) + }) + }; + } + + get playerOwnership() { + return Array.from(game.users).reduce((acc, user) => { + acc[user.id] = { + value: user.isGM + ? CONST.DOCUMENT_OWNERSHIP_LEVELS.OWNER + : this.ownership.players[user.id] && this.ownership.players[user.id].type !== -1 + ? this.ownership.players[user.id].type + : this.ownership.default, + isGM: user.isGM + }; + + return acc; + }, {}); + } +} + export class DhCountdown extends foundry.abstract.DataModel { static defineSchema() { const fields = foundry.data.fields; diff --git a/module/data/fields/action/_module.mjs b/module/data/fields/action/_module.mjs index f6c34817..fa3b1cd5 100644 --- a/module/data/fields/action/_module.mjs +++ b/module/data/fields/action/_module.mjs @@ -1,4 +1,3 @@ -export { default as AreasField } from './areasField.mjs'; export { default as CostField } from './costField.mjs'; export { default as CountdownField } from './countdownField.mjs'; export { default as UsesField } from './usesField.mjs'; diff --git a/module/data/fields/action/areasField.mjs b/module/data/fields/action/areasField.mjs deleted file mode 100644 index 52110045..00000000 --- a/module/data/fields/action/areasField.mjs +++ /dev/null @@ -1,40 +0,0 @@ -const fields = foundry.data.fields; - -export default class AreasField extends fields.ArrayField { - /** - * Action Workflow order - */ - static order = 150; - - /** @inheritDoc */ - constructor(options = {}, context = {}) { - const element = new fields.SchemaField({ - name: new fields.StringField({ - nullable: false, - initial: 'Area', - label: 'DAGGERHEART.GENERAL.name' - }), - type: new fields.StringField({ - nullable: false, - choices: CONFIG.DH.ACTIONS.areaTypes, - initial: CONFIG.DH.ACTIONS.areaTypes.placed.id, - label: 'DAGGERHEART.GENERAL.type' - }), - shape: new fields.StringField({ - nullable: false, - choices: CONFIG.DH.GENERAL.templateTypes, - initial: CONFIG.DH.GENERAL.templateTypes.circle.id, - label: 'DAGGERHEART.ACTIONS.Config.area.shape' - }), - /* Could be opened up to allow numbers to be input aswell. Probably best handled via an autocomplete in that case to allow the select options but also free text */ - size: new fields.StringField({ - nullable: false, - choices: CONFIG.DH.GENERAL.range, - initial: CONFIG.DH.GENERAL.range.veryClose.id, - label: 'DAGGERHEART.ACTIONS.Config.area.size' - }), - effects: new fields.ArrayField(new fields.DocumentIdField()) - }); - super(element, options, context); - } -} diff --git a/module/data/fields/action/countdownField.mjs b/module/data/fields/action/countdownField.mjs index 719ca749..f49e71ad 100644 --- a/module/data/fields/action/countdownField.mjs +++ b/module/data/fields/action/countdownField.mjs @@ -57,10 +57,6 @@ export default class CountdownField extends fields.ArrayField { data.countdowns[foundry.utils.randomID()] = { ...countdown, - ownership: game.users.reduce((acc, curr) => { - if (!curr.isGM) acc[curr.id] = countdown.defaultOwnership; - return acc; - }, {}), progress: { ...countdown.progress, current: countdownStart, diff --git a/module/data/fields/action/damageField.mjs b/module/data/fields/action/damageField.mjs index 30a5ad7c..5d40a470 100644 --- a/module/data/fields/action/damageField.mjs +++ b/module/data/fields/action/damageField.mjs @@ -18,12 +18,7 @@ export default class DamageField extends fields.SchemaField { initial: false, label: 'DAGGERHEART.ACTIONS.Settings.includeBase.label' }), - direct: new fields.BooleanField({ initial: false, label: 'DAGGERHEART.CONFIG.DamageType.direct.name' }), - groupAttack: new fields.StringField({ - choices: CONFIG.DH.GENERAL.groupAttackRange, - blank: true, - label: 'DAGGERHEART.ACTIONS.Settings.groupAttack.label' - }) + direct: new fields.BooleanField({ initial: false, label: 'DAGGERHEART.CONFIG.DamageType.direct.name' }) }; super(damageFields, options, context); } @@ -229,22 +224,6 @@ export default class DamageField extends fields.SchemaField { game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Automation).roll.damageApply.players) ); } - - static getGroupAttackTokens(actorId, range) { - if (!canvas.scene) return []; - - const targets = Array.from(game.user.targets); - const rangeSettings = canvas.scene?.rangeSettings; - if (!rangeSettings) return []; - - const maxDistance = rangeSettings[range]; - return canvas.scene.tokens.filter(x => { - if (x.actor?.id !== actorId) return false; - if (targets.every(target => x.object.distanceTo(target) > maxDistance)) return false; - - return true; - }); - } } export class DHActionDiceData extends foundry.abstract.DataModel { @@ -320,7 +299,7 @@ export class DHDamageData extends DHResourceData { required: true }), { - label: game.i18n.localize('DAGGERHEART.GENERAL.type') + label: 'Type' } ) }; diff --git a/module/data/fields/action/summonField.mjs b/module/data/fields/action/summonField.mjs index ec7881f7..dce6414c 100644 --- a/module/data/fields/action/summonField.mjs +++ b/module/data/fields/action/summonField.mjs @@ -1,4 +1,3 @@ -import { itemAbleRollParse } from '../../../helpers/utils.mjs'; import FormulaField from '../formulaField.mjs'; const fields = foundry.data.fields; @@ -37,23 +36,20 @@ export default class DHSummonField extends fields.ArrayField { const rolls = []; const summonData = []; for (const summon of this.summon) { - const roll = new Roll(itemAbleRollParse(summon.count, this.actor, this.item)); - await roll.evaluate(); - const count = roll.total; - if (!roll.isDeterministic && game.modules.get('dice-so-nice')?.active) rolls.push(roll); + let count = summon.count; + const roll = new Roll(summon.count); + if (!roll.isDeterministic) { + await roll.evaluate(); + if (game.modules.get('dice-so-nice')?.active) rolls.push(roll); + count = roll.total; + } - const actor = await DHSummonField.getWorldActor(await foundry.utils.fromUuid(summon.actorUUID)); + const actor = DHSummonField.getWorldActor(await foundry.utils.fromUuid(summon.actorUUID)); /* Extending summon data in memory so it's available in actionField.toChat. Think it's harmless, but ugly. Could maybe find a better way. */ + summon.rolledCount = count; summon.actor = actor.toObject(); - const countNumber = Number.parseInt(count); - for (let i = 0; i < countNumber; i++) { - const remaining = countNumber - i; - summonData.push({ - actor, - tokenPreviewName: `${actor.prototypeToken.name}${remaining > 1 ? ` (${remaining}x)` : ''}` - }); - } + summonData.push({ actor, count: count }); } if (rolls.length) await Promise.all(rolls.map(roll => game.dice3d.showForRoll(roll, game.user, true))); @@ -62,22 +58,32 @@ export default class DHSummonField extends fields.ArrayField { DHSummonField.handleSummon(summonData, this.actor); } - /* Check for any available instances of the actor present in the world if we're missing artwork in the compendium. If none exists, create one. */ - static async getWorldActor(baseActor) { + /* Check for any available instances of the actor present in the world if we're missing artwork in the compendium */ + static getWorldActor(baseActor) { const dataType = game.system.api.data.actors[`Dh${baseActor.type.capitalize()}`]; if (baseActor.inCompendium && dataType && baseActor.img === dataType.DEFAULT_ICON) { const worldActorCopy = game.actors.find(x => x.name === baseActor.name); - if (worldActorCopy) return worldActorCopy; - - return await game.system.api.documents.DhpActor.create(baseActor.toObject()); + return worldActorCopy ?? baseActor; } return baseActor; } - static async handleSummon(summonData, actionActor) { - await CONFIG.ux.TokenManager.createTokensWithPreview(summonData, { elevation: actionActor.token?.elevation }); + static async handleSummon(summonData, actionActor, summonIndex = 0) { + const summon = summonData[summonIndex]; + const result = await CONFIG.ux.TokenManager.createPreviewAsync(summon.actor, { + name: `${summon.actor.prototypeToken.name}${summon.count > 1 ? ` (${summon.count}x)` : ''}` + }); - return actionActor.sheet?.maximize(); + if (!result) return actionActor.sheet?.maximize(); + summon.actor = result.actor; + + summon.count--; + if (summon.count <= 0) { + summonIndex++; + if (summonIndex === summonData.length) return actionActor.sheet?.maximize(); + } + + DHSummonField.handleSummon(summonData, actionActor, summonIndex); } } diff --git a/module/data/fields/actionField.mjs b/module/data/fields/actionField.mjs index 83672c8e..ffdc25cd 100644 --- a/module/data/fields/actionField.mjs +++ b/module/data/fields/actionField.mjs @@ -281,14 +281,8 @@ export function ActionMixin(Base) { name: this.name, img: this.baseAction ? this.parent.parent.img : this.img, tags: this.tags ? this.tags : ['Spell', 'Arcana', 'Lv 10'], - areas: this.areas, summon: this.summon }, - source: { - actor: this.actor.uuid, - item: this.item.id, - action: this.id - }, itemOrigin: this.item, description: this.description || (this.item instanceof Item ? this.item.system.description : '') }; diff --git a/module/data/fields/actorField.mjs b/module/data/fields/actorField.mjs index d6b58675..7a57aa46 100644 --- a/module/data/fields/actorField.mjs +++ b/module/data/fields/actorField.mjs @@ -89,13 +89,13 @@ class ResourcesField extends fields.TypedObjectField { */ _getField(path) { if (path.length === 0) return this; - const name = path.pop(); - if (name === this.element.name) return this.element_getField(path); + const first = path.shift(); + if (first === this.element.name) return this.element_getField(path); const resources = CONFIG.DH.RESOURCE[this.actorType].all; - if (name in resources) { + if (first in resources) { const field = this.element._getField(path); - field.label = resources[name].label; + field.label = resources[first].label; return field; } @@ -103,15 +103,4 @@ class ResourcesField extends fields.TypedObjectField { } } -class GoldField extends fields.SchemaField { - constructor() { - super({ - coins: new fields.NumberField({ initial: 0, integer: true }), - handfuls: new fields.NumberField({ initial: 1, integer: true }), - bags: new fields.NumberField({ initial: 0, integer: true }), - chests: new fields.NumberField({ initial: 0, integer: true }) - }); - } -} - -export { attributeField, ResourcesField, GoldField, stressDamageReductionRule, bonusField }; +export { attributeField, ResourcesField, stressDamageReductionRule, bonusField }; diff --git a/module/data/groupRollData.mjs b/module/data/groupRollData.mjs deleted file mode 100644 index 78a06b13..00000000 --- a/module/data/groupRollData.mjs +++ /dev/null @@ -1,40 +0,0 @@ -export default class GroupRollData extends foundry.abstract.DataModel { - static defineSchema() { - const fields = foundry.data.fields; - - return { - leader: new fields.EmbeddedDataField(CharacterData, { nullable: true, initial: null }), - aidingCharacters: new fields.TypedObjectField(new fields.EmbeddedDataField(CharacterData)) - }; - } - - get participants() { - return { - ...(this.leader ? { [this.leader.id]: this.leader } : {}), - ...this.aidingCharacters - }; - } -} - -export class CharacterData extends foundry.abstract.DataModel { - static defineSchema() { - const fields = foundry.data.fields; - - return { - id: new fields.StringField({ required: true }), - name: new fields.StringField({ required: true }), - img: new fields.StringField({ required: true }), - rollChoice: new fields.StringField({ - choices: CONFIG.DH.ACTOR.abilities, - initial: CONFIG.DH.ACTOR.abilities.agility.id - }), - rollData: new fields.JSONField({ nullable: true, initial: null }), - selected: new fields.BooleanField({ initial: false }), - successfull: new fields.BooleanField({ nullable: true, initial: null }) - }; - } - - get roll() { - return this.rollData ? CONFIG.Dice.daggerheart.DualityRoll.fromData(this.rollData) : null; - } -} diff --git a/module/data/item/base.mjs b/module/data/item/base.mjs index f6c794f1..21a11149 100644 --- a/module/data/item/base.mjs +++ b/module/data/item/base.mjs @@ -4,6 +4,7 @@ * @property {string} label - A localizable label used on application. * @property {string} type - The system type that this data model represents. * @property {boolean} hasDescription - Indicates whether items of this type have description field + * @property {boolean} isQuantifiable - Indicates whether items of this type have quantity field * @property {boolean} isInventoryItem- Indicates whether items of this type is a Inventory Item */ @@ -23,6 +24,7 @@ export default class BaseDataItem extends foundry.abstract.TypeDataModel { type: 'base', hasDescription: false, hasResource: false, + isQuantifiable: false, isInventoryItem: false, hasActions: false, hasAttribution: true @@ -81,7 +83,7 @@ export default class BaseDataItem extends foundry.abstract.TypeDataModel { ); } - if (this.metadata.isInventoryItem) + if (this.metadata.isQuantifiable) schema.quantity = new fields.NumberField({ integer: true, initial: 1, min: 0, required: true }); if (this.metadata.hasActions) schema.actions = new ActionsField(); @@ -108,10 +110,6 @@ export default class BaseDataItem extends foundry.abstract.TypeDataModel { } get actionsList() { - // No actions on non-characters - if (this.metadata.isInventoryItem && this.actor && this.actor.type !== 'character') { - return []; - } return this.actions; } diff --git a/module/data/item/consumable.mjs b/module/data/item/consumable.mjs index e83a1a53..ab527967 100644 --- a/module/data/item/consumable.mjs +++ b/module/data/item/consumable.mjs @@ -7,6 +7,7 @@ export default class DHConsumable extends BaseDataItem { label: 'TYPES.Item.consumable', type: 'consumable', hasDescription: true, + isQuantifiable: true, isInventoryItem: true, hasActions: true }); diff --git a/module/data/item/loot.mjs b/module/data/item/loot.mjs index d4092934..cdb0855e 100644 --- a/module/data/item/loot.mjs +++ b/module/data/item/loot.mjs @@ -7,6 +7,7 @@ export default class DHLoot extends BaseDataItem { label: 'TYPES.Item.loot', type: 'loot', hasDescription: true, + isQuantifiable: true, isInventoryItem: true, hasActions: true }); diff --git a/module/data/item/weapon.mjs b/module/data/item/weapon.mjs index 75e6dc8e..9335037c 100644 --- a/module/data/item/weapon.mjs +++ b/module/data/item/weapon.mjs @@ -99,9 +99,7 @@ export default class DHWeapon extends AttachableItem { /* -------------------------------------------- */ get actionsList() { - // No actions on non-characters - if (this.actor && this.actor.type !== 'character') return []; - return [this.attack, ...super.actionsList]; + return [this.attack, ...this.actions]; } get customActions() { diff --git a/module/data/regionBehavior/_module.mjs b/module/data/regionBehavior/_module.mjs deleted file mode 100644 index d0c8172d..00000000 --- a/module/data/regionBehavior/_module.mjs +++ /dev/null @@ -1 +0,0 @@ -export { default as applyActiveEffect } from './applyActiveEffect.mjs'; diff --git a/module/data/regionBehavior/applyActiveEffect.mjs b/module/data/regionBehavior/applyActiveEffect.mjs deleted file mode 100644 index 51406cfa..00000000 --- a/module/data/regionBehavior/applyActiveEffect.mjs +++ /dev/null @@ -1,40 +0,0 @@ -export default class DhApplyActiveEffect extends CONFIG.RegionBehavior.dataModels.applyActiveEffect { - static async #getApplicableEffects(token) { - const effects = await Promise.all(this.effects.map(foundry.utils.fromUuid)); - return effects.filter( - effect => !effect.system.targetDispositions.size || effect.system.targetDispositions.has(token.disposition) - ); - } - - static async #onTokenEnter(event) { - if (!event.user.isSelf) return; - const { token, movement } = event.data; - const actor = token.actor; - if (!actor) return; - const resumeMovement = movement ? token.pauseMovement() : undefined; - const effects = await DhApplyActiveEffect.#getApplicableEffects.bind(this)(event.data.token); - const toCreate = []; - for (const effect of effects) { - const data = effect.toObject(); - delete data._id; - if (effect.compendium) { - data._stats.duplicateSource = null; - data._stats.compendiumSource = effect.uuid; - } else { - data._stats.duplicateSource = effect.uuid; - data._stats.compendiumSource = null; - } - data._stats.exportSource = null; - data.origin = this.parent.uuid; - toCreate.push(data); - } - if (toCreate.length) await actor.createEmbeddedDocuments('ActiveEffect', toCreate); - await resumeMovement?.(); - } - - /** @override */ - static events = { - ...CONFIG.RegionBehavior.dataModels.applyActiveEffect.events, - [CONST.REGION_EVENTS.TOKEN_ENTER]: this.#onTokenEnter - }; -} diff --git a/module/data/settings/Appearance.mjs b/module/data/settings/Appearance.mjs index 4db27be0..9da3afac 100644 --- a/module/data/settings/Appearance.mjs +++ b/module/data/settings/Appearance.mjs @@ -8,9 +8,6 @@ export default class DhAppearance extends foundry.abstract.DataModel { initial: null, blank: true, choices: CONFIG.DH.GENERAL.diceSoNiceSFXClasses - }), - options: new foundry.data.fields.SchemaField({ - muteSound: new foundry.data.fields.BooleanField() }) }); diff --git a/module/data/tagTeamData.mjs b/module/data/tagTeamData.mjs index 640c2f6c..25158606 100644 --- a/module/data/tagTeamData.mjs +++ b/module/data/tagTeamData.mjs @@ -33,7 +33,7 @@ export class MemberData extends foundry.abstract.DataModel { required: true, choices: CONFIG.DH.GENERAL.tagTeamRollTypes, initial: CONFIG.DH.GENERAL.tagTeamRollTypes.trait.id, - label: game.i18n.localize('DAGGERHEART.APPLICATIONS.TagTeamSelect.rollType') + label: 'Roll Type' }), rollChoice: new fields.StringField({ nullable: true, initial: null }), rollData: new fields.JSONField({ nullable: true, initial: null }), diff --git a/module/dice/damageRoll.mjs b/module/dice/damageRoll.mjs index 98fd8401..1d680a1b 100644 --- a/module/dice/damageRoll.mjs +++ b/module/dice/damageRoll.mjs @@ -144,7 +144,6 @@ export default class DamageRoll extends DHRoll { constructFormula(config) { this.options.isCritical = config.isCritical; for (const [index, part] of this.options.roll.entries()) { - const isHitpointPart = part.applyTo === CONFIG.DH.GENERAL.healingTypes.hitPoints.id; part.roll = new Roll(Roll.replaceFormulaData(part.formula, config.data)); part.roll.terms = Roll.parse(part.roll.formula, config.data); if (part.applyTo === CONFIG.DH.GENERAL.healingTypes.hitPoints.id) { @@ -170,16 +169,7 @@ export default class DamageRoll extends DHRoll { ); } - if (config.damageOptions.groupAttack?.numAttackers > 1 && isHitpointPart) { - const damageTypes = [foundry.dice.terms.Die, foundry.dice.terms.NumericTerm]; - for (const term of part.roll.terms) { - if (damageTypes.some(type => term instanceof type)) { - term.number *= config.damageOptions.groupAttack.numAttackers; - } - } - } - - if (config.isCritical && isHitpointPart) { + if (config.isCritical && part.applyTo === CONFIG.DH.GENERAL.healingTypes.hitPoints.id) { const total = part.roll.dice.reduce((acc, term) => acc + term._faces * term._number, 0); if (total > 0) { part.roll.terms.push(...this.formatModifier(total)); diff --git a/module/dice/dhRoll.mjs b/module/dice/dhRoll.mjs index 209631f6..aa4dd75f 100644 --- a/module/dice/dhRoll.mjs +++ b/module/dice/dhRoll.mjs @@ -145,7 +145,6 @@ export default class DHRoll extends Roll { roll: this, parent: chatData.parent, targetMode: chatData.targetMode, - areas: chatData.action?.areas, metagamingSettings }); } diff --git a/module/dice/dualityRoll.mjs b/module/dice/dualityRoll.mjs index 5e03a680..f9a06d37 100644 --- a/module/dice/dualityRoll.mjs +++ b/module/dice/dualityRoll.mjs @@ -3,6 +3,7 @@ import D20Roll from './d20Roll.mjs'; import { parseRallyDice, setDiceSoNiceForDualityRoll } from '../helpers/utils.mjs'; export default class DualityRoll extends D20Roll { + _advantageFaces = 6; _advantageNumber = 1; _rallyIndex; @@ -10,11 +11,6 @@ export default class DualityRoll extends D20Roll { super(formula, data, options); this.rallyChoices = this.setRallyChoices(); this.guaranteedCritical = options.guaranteedCritical; - - const advantageFaces = data.rules?.roll?.defaultAdvantageDice - ? Number.parseInt(data.rules.roll.defaultAdvantageDice) - : 6; - this.advantageFaces = Number.isNaN(advantageFaces) ? 6 : advantageFaces; } static messageType = 'dualityRoll'; @@ -55,6 +51,14 @@ export default class DualityRoll extends D20Roll { return this.dice[2] instanceof game.system.api.dice.diceTypes.DisadvantageDie ? this.dice[2] : null; } + get advantageFaces() { + return this._advantageFaces; + } + + set advantageFaces(faces) { + this._advantageFaces = this.getFaces(faces); + } + get advantageNumber() { return this._advantageNumber; } diff --git a/module/documents/activeEffect.mjs b/module/documents/activeEffect.mjs index 227e2613..8ec7a751 100644 --- a/module/documents/activeEffect.mjs +++ b/module/documents/activeEffect.mjs @@ -200,6 +200,7 @@ export default class DhActiveEffect extends foundry.documents.ActiveEffect { static effectSafeEval(expression) { let result; try { + // eslint-disable-next-line no-new-func const evl = new Function('sandbox', `with (sandbox) { return ${expression}}`); result = evl(Roll.MATH_PROXY); } catch (err) { diff --git a/module/documents/actor.mjs b/module/documents/actor.mjs index db249033..3e3dfde4 100644 --- a/module/documents/actor.mjs +++ b/module/documents/actor.mjs @@ -113,13 +113,11 @@ export default class DhpActor extends Actor { _onUpdate(changes, options, userId) { super._onUpdate(changes, options, userId); for (const party of this.parties) { - party.render({ parts: ['partyMembers'] }); + party.render(); } } - async _preDelete(options, user) { - if ((await super._preDelete(options, user)) === false) return false; - + async _preDelete() { if (this.prototypeToken.actorLink) { game.system.registeredTriggers.unregisterItemTriggers(this.items); } else { @@ -132,7 +130,7 @@ export default class DhpActor extends Actor { _onDelete(options, userId) { super._onDelete(options, userId); for (const party of this.parties) { - party.render({ parts: ['partyMembers'] }); + party.render(); } } @@ -602,7 +600,6 @@ export default class DhpActor extends Actor { rollData.system = this.system.getRollData(); rollData.prof = this.system.proficiency ?? 1; rollData.cast = this.system.spellcastModifier ?? 1; - return rollData; } diff --git a/module/documents/chatMessage.mjs b/module/documents/chatMessage.mjs index 2e20fb87..307677bb 100644 --- a/module/documents/chatMessage.mjs +++ b/module/documents/chatMessage.mjs @@ -137,10 +137,6 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage { element.addEventListener('click', this.onApplyEffect.bind(this)) ); - for (const element of html.querySelectorAll('.action-areas')) { - element.addEventListener('click', this.onCreateAreas.bind(this)); - } - html.querySelectorAll('.roll-target').forEach(element => { element.addEventListener('mouseenter', this.hoverTarget); element.addEventListener('mouseleave', this.unhoverTarget); @@ -182,8 +178,8 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage { const pendingingSaves = targets.filter(t => t.saved.success === null); if (pendingingSaves.length) { const confirm = await foundry.applications.api.DialogV2.confirm({ - window: { title: game.i18n.localize('DAGGERHEART.APPLICATIONS.PendingReactionsDialog.title') }, - content: `

${game.i18n.localize('DAGGERHEART.APPLICATIONS.PendingReactionsDialog.unfinishedRolls')}

${game.i18n.localize('DAGGERHEART.APPLICATIONS.PendingReactionsDialog.confirmation')}

${game.i18n.localize('DAGGERHEART.APPLICATIONS.PendingReactionsDialog.warning')}

` + window: { title: 'Pending Reaction Rolls found' }, + content: `

Some Tokens still need to roll their Reaction Roll.

Are you sure you want to continue ?

Undone reaction rolls will be considered as failed

` }); if (!confirm) return; } @@ -253,54 +249,6 @@ export default class DhpChatMessage extends foundry.documents.ChatMessage { this.system.action?.workflow.get('effects')?.execute(config, targets, true); } - async onCreateAreas(event) { - const createArea = async selectedArea => { - const effects = selectedArea.effects.map(effect => this.system.action.item.effects.get(effect).uuid); - const { shape: type, size: range } = selectedArea; - const shapeData = CONFIG.Canvas.layers.regions.layerClass.getTemplateShape({ type, range }); - - await canvas.regions.placeRegion( - { - name: selectedArea.name, - shapes: [shapeData], - restriction: { enabled: false, type: 'move', priority: 0 }, - behaviors: [ - { - name: game.i18n.localize('TYPES.RegionBehavior.applyActiveEffect'), - type: 'applyActiveEffect', - system: { - effects: effects - } - } - ], - displayMeasurements: true, - locked: false, - ownership: { default: CONST.DOCUMENT_OWNERSHIP_LEVELS.NONE }, - visibility: CONST.REGION_VISIBILITY.ALWAYS - }, - { create: true } - ); - }; - - if (this.system.action.areas.length === 1) createArea(this.system.action.areas[0]); - else if (this.system.action.areas.length > 1) { - new foundry.applications.ux.ContextMenu.implementation( - event.target, - '.action-areas', - this.system.action.areas.map(area => ({ - label: area.name, - onClick: () => createArea(area) - })), - { - jQuery: false, - fixed: true - } - ); - - CONFIG.ux.ContextMenu.triggerContextMenu(event, '.action-areas'); - } - } - filterPermTargets(targets) { return targets.filter(t => fromUuidSync(t.actorId)?.canUserModify(game.user, 'update')); } diff --git a/module/documents/collections/actorCollection.mjs b/module/documents/collections/actorCollection.mjs index 115dd694..a3714b30 100644 --- a/module/documents/collections/actorCollection.mjs +++ b/module/documents/collections/actorCollection.mjs @@ -1,11 +1,4 @@ export default class DhActorCollection extends foundry.documents.collections.Actors { - /** @returns the active party */ - get party() { - const id = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty); - const actor = game.actors.get(id); - return actor?.type === 'party' ? actor : null; - } - /** Ensure companions are initialized after all other subtypes. */ _initialize() { super._initialize(); diff --git a/module/documents/item.mjs b/module/documents/item.mjs index 8ece56fa..d1a618c7 100644 --- a/module/documents/item.mjs +++ b/module/documents/item.mjs @@ -31,13 +31,8 @@ export default class DHItem extends foundry.documents.Item { static async createDocuments(sources, operation) { // Ensure that items being created are valid to the actor its being added to const actor = operation.parent; - const filtered = actor ? sources.filter(s => actor.system.isItemValid(s)) : sources; - if (actor && filtered.length === 0 && sources.length > 0) { - const itemType = _loc(`TYPES.Item.${sources[0].type}`); - const actorType = _loc(`TYPES.Actor.${actor.type}`); - ui.notifications.error('DAGGERHEART.ACTORS.Base.CannotAddType', { format: { itemType, actorType } }); - } - return super.createDocuments(filtered, operation); + sources = actor?.system?.isItemValid ? sources.filter(s => actor.system.isItemValid(s)) : sources; + return super.createDocuments(sources, operation); } /* -------------------------------------------- */ @@ -76,13 +71,6 @@ export default class DHItem extends foundry.documents.Item { return this.system.metadata.isInventoryItem ?? false; } - /** Returns true if the item can be used */ - get usable() { - const actor = this.actor; - const actionsList = this.system.actionsList; - return this.isOwner && actor?.type === 'character' && (actionsList?.size || actionsList?.length); - } - /** @inheritdoc */ static async createDialog(data = {}, createOptions = {}, options = {}) { const { folders, types, template, context = {}, ...dialogOptions } = options; diff --git a/module/documents/scene.mjs b/module/documents/scene.mjs index 59b8091f..1c2faa34 100644 --- a/module/documents/scene.mjs +++ b/module/documents/scene.mjs @@ -1,16 +1,6 @@ import DHToken from './token.mjs'; export default class DhScene extends Scene { - get rangeSettings() { - const { custom } = CONFIG.DH.GENERAL.sceneRangeMeasurementSetting; - const sceneMeasurements = this.flags.daggerheart?.rangeMeasurement; - const globalMeasurements = game.settings.get( - CONFIG.DH.id, - CONFIG.DH.SETTINGS.gameSettings.variantRules - ).rangeMeasurement; - return sceneMeasurements?.setting === custom.id ? sceneMeasurements : globalMeasurements; - } - /** A map of `TokenDocument` IDs embedded in this scene long with new dimensions from actor size-category changes */ #sizeSyncBatch = new Map(); diff --git a/module/documents/tokenManager.mjs b/module/documents/tokenManager.mjs index 3ccff4e2..f766a677 100644 --- a/module/documents/tokenManager.mjs +++ b/module/documents/tokenManager.mjs @@ -1,68 +1,104 @@ /** - * A singleton class that handles creating tokens. + * A singleton class that handles preview tokens. */ export default class DhTokenManager { + #activePreview; + #actor; + #resolve; + /** - * Create a token previer - * @param {Actor} actor - * @param {object} tokenData + * Create a template preview, deactivating any existing ones. + * @param {object} data */ async createPreview(actor, tokenData) { - const tokenSizes = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew).tokenSizes; - if (actor?.system.metadata.usesSize) { - const tokenSize = tokenSizes[actor.system.size]; - if (tokenSize && actor.system.size !== CONFIG.DH.ACTOR.tokenSize.custom.id) { - tokenData.width = tokenSize; - tokenData.height = tokenSize; - } - } - - return await canvas.tokens.placeTokens( - [ - { - ...actor.prototypeToken.toObject(), - actorId: actor.id, - displayName: 50, - ...tokenData - } - ], - { create: false } + this.#actor = actor; + const token = await canvas.tokens._createPreview( + { + ...actor.prototypeToken, + displayName: 50, + ...tokenData + }, + { renderSheet: false, actor } ); + + this.#activePreview = { + document: token.document, + object: token, + origin: { x: token.document.x, y: token.document.y } + }; + + this.#activePreview.events = { + contextmenu: this.#cancelTemplate.bind(this), + mousedown: this.#confirmTemplate.bind(this), + mousemove: this.#onDragMouseMove.bind(this) + }; + + canvas.stage.on('mousemove', this.#activePreview.events.mousemove); + canvas.stage.on('mousedown', this.#activePreview.events.mousedown); + canvas.app.view.addEventListener('contextmenu', this.#activePreview.events.contextmenu); + } + + /* Currently intended for using as a preview of where to create a token. (note the flag) */ + async createPreviewAsync(actor, tokenData = {}) { + return new Promise(resolve => { + this.#resolve = resolve; + this.createPreview(actor, { ...tokenData, flags: { daggerheart: { createPlacement: true } } }); + }); } /** - * Creates new tokens on the canvas by placing previews. - * @param {object} tokenData - * @param {object} options + * Handles the movement of the token preview on mousedrag. + * @param {mousemove Event} event */ - async createTokensWithPreview(tokensData, { elevation } = {}) { - const scene = game.scenes.get(game.user.viewedScene); - if (!scene) return; + #onDragMouseMove(event) { + event.stopPropagation(); + const { moveTime, object } = this.#activePreview; + const update = {}; - const level = scene.levels.get(game.user.viewedLevel); - if (!level) return; + const now = Date.now(); + if (now - (moveTime || 0) <= 16) return; + this.#activePreview.moveTime = now; - const createElevation = elevation ?? level.elevation.bottom; - for (const tokenData of tokensData) { - const previewTokens = await this.createPreview(tokenData.actor, { - name: tokenData.tokenPreviewName, - level: game.user.viewedLevel, - elevation: createElevation, - flags: { daggerheart: { createPlacement: true } } - }); - if (!previewTokens?.length) return null; + let cursor = event.getLocalPosition(canvas.templates); - await canvas.scene.createEmbeddedDocuments( - 'Token', - previewTokens.map(x => ({ - ...x.toObject(), - name: tokenData.actor.prototypeToken.name, - displayName: tokenData.actor.prototypeToken.displayName, - flags: tokenData.actor.prototypeToken.flags - })), - { controlObject: true, parent: canvas.scene } - ); - } + Object.assign(update, canvas.grid.getTopLeftPoint(cursor)); + + object.document.updateSource(update); + object.renderFlags.set({ refresh: true }); + } + + /** + * Cancels the preview token on right-click. + * @param {contextmenu Event} event + */ + #cancelTemplate(_event, resolved) { + const { mousemove, mousedown, contextmenu } = this.#activePreview.events; + this.#activePreview.object.destroy(); + + canvas.stage.off('mousemove', mousemove); + canvas.stage.off('mousedown', mousedown); + canvas.app.view.removeEventListener('contextmenu', contextmenu); + if (this.#resolve && !resolved) this.#resolve(false); + } + + /** + * Creates a real Actor and token at the preview location and cancels the preview. + * @param {click Event} event + */ + async #confirmTemplate(event) { + event.stopPropagation(); + this.#cancelTemplate(event, true); + + const actor = this.#actor.inCompendium + ? await game.system.api.documents.DhpActor.create(this.#actor.toObject()) + : this.#actor; + const tokenData = await actor.getTokenDocument(); + const result = await canvas.scene.createEmbeddedDocuments('Token', [ + { ...tokenData.toObject(), x: this.#activePreview.document.x, y: this.#activePreview.document.y } + ]); + + this.#activePreview = undefined; + if (this.#resolve && result.length) this.#resolve(result[0]); } } diff --git a/module/enrichers/TemplateEnricher.mjs b/module/enrichers/TemplateEnricher.mjs index 8db3ec14..1a075518 100644 --- a/module/enrichers/TemplateEnricher.mjs +++ b/module/enrichers/TemplateEnricher.mjs @@ -12,7 +12,7 @@ export default function DhTemplateEnricher(match, _options) { )?.id : params.range; - if (!CONFIG.DH.GENERAL.templateTypes[type] || !range) return match[0]; + if (!Object.values(CONFIG.DH.GENERAL.templateTypes).find(x => x === type) || !range) return match[0]; const label = game.i18n.localize(`DAGGERHEART.CONFIG.TemplateTypes.${type}`); const rangeDisplay = Number.isNaN(Number(range)) @@ -49,6 +49,8 @@ export default function DhTemplateEnricher(match, _options) { } export const renderMeasuredTemplate = async event => { + const { LINE, RECTANGLE, INFRONT, CONE } = CONFIG.DH.GENERAL.templateTypes; + const button = event.currentTarget, type = button.dataset.type, range = button.dataset.range, @@ -57,16 +59,49 @@ export const renderMeasuredTemplate = async event => { if (!type || !range || !game.canvas.scene) return; - const shapeData = CONFIG.Canvas.layers.regions.layerClass.getTemplateShape({ - type, - angle, - range, - direction - }); + const usedType = type === 'inFront' ? 'cone' : type; + const usedAngle = + type === CONE ? (angle ?? CONFIG.MeasuredTemplate.defaults.angle) : type === INFRONT ? '180' : undefined; + + let baseDistance = getTemplateDistance(range); + + const { grid, distance } = CONFIG.Scene.documentClass.schema.fields.grid.fields; + const sceneGridSize = canvas.scene?.grid.size ?? grid.size.initial; + const sceneGridDistance = canvas.scene?.grid.distance ?? distance.getInitialValue(); + const dimensionConstant = sceneGridSize / sceneGridDistance; + + baseDistance *= dimensionConstant; + + const length = baseDistance; + const radius = length; + + const shapeWidth = type === LINE ? 5 * dimensionConstant : type === RECTANGLE ? length : undefined; + + const { width, height } = game.canvas.scene.dimensions; + const shapeData = { + x: width / 2, + y: height / 2, + base: { + type: 'token', + x: 0, + y: 0, + width: 1, + height: 1, + shape: game.canvas.grid.isHexagonal ? CONST.TOKEN_SHAPES.ELLIPSE_1 : CONST.TOKEN_SHAPES.RECTANGLE_1 + }, + t: usedType, + length: length, + width: shapeWidth, + height: length, + angle: usedAngle, + radius: radius, + direction: direction, + type: usedType + }; await canvas.regions.placeRegion( { - name: type.capitalize(), + name: usedType.capitalize(), shapes: [shapeData], restriction: { enabled: false, type: 'move', priority: 0 }, behaviors: [], @@ -78,3 +113,18 @@ export const renderMeasuredTemplate = async event => { { create: true } ); }; + +const getTemplateDistance = range => { + const rangeNumber = Number(range); + if (!Number.isNaN(rangeNumber)) return rangeNumber; + + const { custom } = CONFIG.DH.GENERAL.sceneRangeMeasurementSetting; + const sceneMeasurements = canvas.scene?.flags.daggerheart?.rangeMeasurement; + const globalMeasurements = game.settings.get( + CONFIG.DH.id, + CONFIG.DH.SETTINGS.gameSettings.variantRules + ).rangeMeasurement; + + const settings = sceneMeasurements?.setting === custom.id ? sceneMeasurements : globalMeasurements; + return settings[range]; +}; diff --git a/module/helpers/utils.mjs b/module/helpers/utils.mjs index 4527da1a..131f94b7 100644 --- a/module/helpers/utils.mjs +++ b/module/helpers/utils.mjs @@ -189,13 +189,7 @@ export const getDeleteKeys = (property, innerProperty, innerPropertyDefaultValue // Fix on Foundry native formula replacement for DH const nativeReplaceFormulaData = Roll.replaceFormulaData; -Roll.replaceFormulaData = function (formula, baseData = {}, { missing, warn = false } = {}) { - /* Inserting global data */ - const data = { - ...baseData, - partySize: game.actors?.party?.system.partyMembers.length ?? 0 - }; - +Roll.replaceFormulaData = function (formula, data = {}, { missing, warn = false } = {}) { const terms = Object.keys(CONFIG.DH.GENERAL.multiplierTypes).map(type => { return { term: type, default: 1 }; }); diff --git a/module/systemRegistration/handlebars.mjs b/module/systemRegistration/handlebars.mjs index 1b08e0ad..63e591c6 100644 --- a/module/systemRegistration/handlebars.mjs +++ b/module/systemRegistration/handlebars.mjs @@ -10,7 +10,6 @@ export const preloadHandlebarsTemplates = async function () { 'templates/generic/tab-navigation.hbs', 'systems/daggerheart/templates/sheets/global/tabs/tab-navigation.hbs', 'systems/daggerheart/templates/sheets/global/partials/action-item.hbs', - 'systems/daggerheart/templates/sheets/global/partials/gold.hbs', 'systems/daggerheart/templates/sheets/global/partials/domain-card-item.hbs', 'systems/daggerheart/templates/sheets/global/partials/item-resource.hbs', 'systems/daggerheart/templates/sheets/global/partials/resource-section/resource-section.hbs', @@ -29,7 +28,6 @@ export const preloadHandlebarsTemplates = async function () { 'systems/daggerheart/templates/actionTypes/uses.hbs', 'systems/daggerheart/templates/actionTypes/roll.hbs', 'systems/daggerheart/templates/actionTypes/save.hbs', - 'systems/daggerheart/templates/actionTypes/areas.hbs', 'systems/daggerheart/templates/actionTypes/cost.hbs', 'systems/daggerheart/templates/actionTypes/range-target.hbs', 'systems/daggerheart/templates/actionTypes/effect.hbs', diff --git a/module/systemRegistration/migrations.mjs b/module/systemRegistration/migrations.mjs index b4c446b2..458ee6ef 100644 --- a/module/systemRegistration/migrations.mjs +++ b/module/systemRegistration/migrations.mjs @@ -1,4 +1,3 @@ -import { defaultRestOptions } from '../config/generalConfig.mjs'; import { RefreshType, socketEvent } from './socket.mjs'; export async function runMigrations() { @@ -342,18 +341,6 @@ export async function runMigrations() { lastMigrationVersion = '2.0.0'; } - - if (foundry.utils.isNewerVersion('2.1.0', lastMigrationVersion)) { - const downtimeMoves = game.settings.get(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew); - if (downtimeMoves.restMoves.longRest.moves.repairArmor) { - await downtimeMoves.updateSource({ - 'restMoves.longRest.moves.repairArmor': defaultRestOptions.longRest().repairArmor - }); - game.settings.set(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.Homebrew, downtimeMoves.toObject()); - } - - lastMigrationVersion = '2.1.0'; - } //#endregion await game.settings.set(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.LastMigrationVersion, lastMigrationVersion); diff --git a/module/systemRegistration/settings.mjs b/module/systemRegistration/settings.mjs index 41cab011..63611cda 100644 --- a/module/systemRegistration/settings.mjs +++ b/module/systemRegistration/settings.mjs @@ -52,27 +52,6 @@ export const registerKeyBindings = () => { reservedModifiers: [], precedence: CONST.KEYBINDING_PRECEDENCE.NORMAL }); - - game.keybindings.register(CONFIG.DH.id, CONFIG.DH.SETTINGS.keybindings.partySheet, { - name: _loc('DAGGERHEART.SETTINGS.Keybindings.partySheet.name'), - hint: _loc('DAGGERHEART.SETTINGS.Keybindings.partySheet.hint'), - editable: [{ key: 'KeyP' }], - onDown: () => { - const controlled = canvas.ready ? canvas.tokens.controlled : []; - const selectedParty = controlled.find(c => c.actor?.type === 'party')?.actor; - const party = selectedParty ?? game.actors.party; - if (!party) return; - - const sheet = party.sheet; - if (!sheet.rendered) { - sheet.render(true); - } else if (sheet.minimized) { - sheet.maximize(); - } else { - sheet.close(); - } - } - }); }; const registerMenuSettings = () => { @@ -210,11 +189,4 @@ const registerNonConfigSettings = () => { config: false, type: SpotlightTracker }); - - game.settings.register(CONFIG.DH.id, CONFIG.DH.SETTINGS.gameSettings.ActiveParty, { - scope: 'world', - config: false, - type: String, - default: null - }); }; diff --git a/module/systemRegistration/socket.mjs b/module/systemRegistration/socket.mjs index 8fed346d..fb152959 100644 --- a/module/systemRegistration/socket.mjs +++ b/module/systemRegistration/socket.mjs @@ -18,8 +18,6 @@ export function handleSocketEvent({ action = null, data = {} } = {}) { case socketEvent.TagTeamStart: Hooks.callAll(CONFIG.DH.HOOKS.hooksConfig.tagTeamStart, data); break; - case socketEvent.GroupRollStart: - Hooks.callAll(CONFIG.DH.HOOKS.hooksConfig.groupRollStart, data); } } @@ -28,8 +26,7 @@ export const socketEvent = { Refresh: 'DhRefresh', DhpFearUpdate: 'DhFearUpdate', DowntimeTrigger: 'DowntimeTrigger', - TagTeamStart: 'DhTagTeamStart', - GroupRollStart: 'DhGroupRollStart' + TagTeamStart: 'DhTagTeamStart' }; export const GMUpdateEvent = { @@ -44,7 +41,6 @@ export const GMUpdateEvent = { export const RefreshType = { Countdown: 'DhCoundownRefresh', TagTeamRoll: 'DhTagTeamRollRefresh', - GroupRoll: 'DhGroupRollRefresh', EffectsDisplay: 'DhEffectsDisplayRefresh', Scene: 'DhSceneRefresh', CompendiumBrowser: 'DhCompendiumBrowserRefresh' diff --git a/package-lock.json b/package-lock.json index b8fef1cd..864d027c 100644 --- a/package-lock.json +++ b/package-lock.json @@ -16,9 +16,6 @@ "@rollup/plugin-commonjs": "^25.0.7", "@rollup/plugin-node-resolve": "^15.2.3", "concurrently": "^8.2.2", - "eslint": "^10.2.1", - "eslint-plugin-prettier": "^5.5.5", - "globals": "^17.5.0", "husky": "^9.1.5", "lint-staged": "^15.2.10", "postcss": "^8.4.32", @@ -35,152 +32,6 @@ "node": ">=6.9.0" } }, - "node_modules/@eslint-community/eslint-utils": { - "version": "4.9.1", - "resolved": "https://registry.npmjs.org/@eslint-community/eslint-utils/-/eslint-utils-4.9.1.tgz", - "integrity": "sha512-phrYmNiYppR7znFEdqgfWHXR6NCkZEK7hwWDHZUjit/2/U0r6XvkDl0SYnoM51Hq7FhCGdLDT6zxCCOY1hexsQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "eslint-visitor-keys": "^3.4.3" - }, - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - }, - "peerDependencies": { - "eslint": "^6.0.0 || ^7.0.0 || >=8.0.0" - } - }, - "node_modules/@eslint-community/eslint-utils/node_modules/eslint-visitor-keys": { - "version": "3.4.3", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-3.4.3.tgz", - "integrity": "sha512-wpc+LXeiyiisxPlEkUzU6svyS1frIO3Mgxj1fdy7Pm8Ygzguax2N3Fa/D/ag1WqbOprdI+uY6wMUl8/a2G+iag==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^12.22.0 || ^14.17.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/@eslint-community/regexpp": { - "version": "4.12.2", - "resolved": "https://registry.npmjs.org/@eslint-community/regexpp/-/regexpp-4.12.2.tgz", - "integrity": "sha512-EriSTlt5OC9/7SXkRSCAhfSxxoSUgBm33OH+IkwbdpgoqsSsUg7y3uh+IICI/Qg4BBWr3U2i39RpmycbxMq4ew==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.0.0 || ^14.0.0 || >=16.0.0" - } - }, - "node_modules/@eslint/config-array": { - "version": "0.23.5", - "resolved": "https://registry.npmjs.org/@eslint/config-array/-/config-array-0.23.5.tgz", - "integrity": "sha512-Y3kKLvC1dvTOT+oGlqNQ1XLqK6D1HU2YXPc52NmAlJZbMMWDzGYXMiPRJ8TYD39muD/OTjlZmNJ4ib7dvSrMBA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/object-schema": "^3.0.5", - "debug": "^4.3.1", - "minimatch": "^10.2.4" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - } - }, - "node_modules/@eslint/config-array/node_modules/balanced-match": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-4.0.4.tgz", - "integrity": "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/@eslint/config-array/node_modules/brace-expansion": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.5.tgz", - "integrity": "sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^4.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/@eslint/config-array/node_modules/minimatch": { - "version": "10.2.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.5.tgz", - "integrity": "sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.5" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, - "node_modules/@eslint/config-helpers": { - "version": "0.5.5", - "resolved": "https://registry.npmjs.org/@eslint/config-helpers/-/config-helpers-0.5.5.tgz", - "integrity": "sha512-eIJYKTCECbP/nsKaaruF6LW967mtbQbsw4JTtSVkUQc9MneSkbrgPJAbKl9nWr0ZeowV8BfsarBmPpBzGelA2w==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/core": "^1.2.1" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - } - }, - "node_modules/@eslint/core": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/@eslint/core/-/core-1.2.1.tgz", - "integrity": "sha512-MwcE1P+AZ4C6DWlpin/OmOA54mmIZ/+xZuJiQd4SyB29oAJjN30UW9wkKNptW2ctp4cEsvhlLY/CsQ1uoHDloQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@types/json-schema": "^7.0.15" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - } - }, - "node_modules/@eslint/object-schema": { - "version": "3.0.5", - "resolved": "https://registry.npmjs.org/@eslint/object-schema/-/object-schema-3.0.5.tgz", - "integrity": "sha512-vqTaUEgxzm+YDSdElad6PiRoX4t8VGDjCtt05zn4nU810UIx/uNEV7/lZJ6KwFThKZOzOxzXy48da+No7HZaMw==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - } - }, - "node_modules/@eslint/plugin-kit": { - "version": "0.7.1", - "resolved": "https://registry.npmjs.org/@eslint/plugin-kit/-/plugin-kit-0.7.1.tgz", - "integrity": "sha512-rZAP3aVgB9ds9KOeUSL+zZ21hPmo8dh6fnIFwRQj5EAZl9gzR7wxYbYXYysAM8CTqGmUGyp2S4kUdV17MnGuWQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@eslint/core": "^1.2.1", - "levn": "^0.4.1" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - } - }, "node_modules/@foundryvtt/foundryvtt-cli": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/@foundryvtt/foundryvtt-cli/-/foundryvtt-cli-1.1.0.tgz", @@ -221,91 +72,12 @@ "node": ">=10.13.0" } }, - "node_modules/@humanfs/core": { - "version": "0.19.2", - "resolved": "https://registry.npmjs.org/@humanfs/core/-/core-0.19.2.tgz", - "integrity": "sha512-UhXNm+CFMWcbChXywFwkmhqjs3PRCmcSa/hfBgLIb7oQ5HNb1wS0icWsGtSAUNgefHeI+eBrA8I1fxmbHsGdvA==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/types": "^0.15.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/node": { - "version": "0.16.8", - "resolved": "https://registry.npmjs.org/@humanfs/node/-/node-0.16.8.tgz", - "integrity": "sha512-gE1eQNZ3R++kTzFUpdGlpmy8kDZD/MLyHqDwqjkVQI0JMdI1D51sy1H958PNXYkM2rAac7e5/CnIKZrHtPh3BQ==", - "dev": true, - "license": "Apache-2.0", - "dependencies": { - "@humanfs/core": "^0.19.2", - "@humanfs/types": "^0.15.0", - "@humanwhocodes/retry": "^0.4.0" - }, - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanfs/types": { - "version": "0.15.0", - "resolved": "https://registry.npmjs.org/@humanfs/types/-/types-0.15.0.tgz", - "integrity": "sha512-ZZ1w0aoQkwuUuC7Yf+7sdeaNfqQiiLcSRbfI08oAxqLtpXQr9AIVX7Ay7HLDuiLYAaFPu8oBYNq/QIi9URHJ3Q==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18.0" - } - }, - "node_modules/@humanwhocodes/module-importer": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/@humanwhocodes/module-importer/-/module-importer-1.0.1.tgz", - "integrity": "sha512-bxveV4V8v5Yb4ncFTT3rPSgZBOpCkjfK0y4oVVVJwIuDVBRMDXrPyXRL988i5ap9m9bnyEEjWfm5WkBmtffLfA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=12.22" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, - "node_modules/@humanwhocodes/retry": { - "version": "0.4.3", - "resolved": "https://registry.npmjs.org/@humanwhocodes/retry/-/retry-0.4.3.tgz", - "integrity": "sha512-bV0Tgo9K4hfPCek+aMAn81RppFKv2ySDQeMoSZuvTASywNTnVJCArCZE2FWqpvIatKu7VMRLWlR1EazvVhDyhQ==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": ">=18.18" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/nzakas" - } - }, "node_modules/@jridgewell/sourcemap-codec": { "version": "1.5.0", "resolved": "https://registry.npmjs.org/@jridgewell/sourcemap-codec/-/sourcemap-codec-1.5.0.tgz", "integrity": "sha512-gv3ZRaISU3fjPAgNsriBRqGWQL6quFx04YMPW/zD8XMLsU32mhCCbfbO6KZFLjvYpCZ8zyDEgqsgf+PwPaM7GQ==", "dev": true }, - "node_modules/@pkgr/core": { - "version": "0.2.9", - "resolved": "https://registry.npmjs.org/@pkgr/core/-/core-0.2.9.tgz", - "integrity": "sha512-QNqXyfVS2wm9hweSYD2O7F0G06uurj9kZ96TRQE5Y9hU7+tgdZwIkbAKc5Ocy1HxEY2kuDQa6cQ1WRs/O5LFKA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "^12.20.0 || ^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/pkgr" - } - }, "node_modules/@rollup/plugin-commonjs": { "version": "25.0.8", "resolved": "https://registry.npmjs.org/@rollup/plugin-commonjs/-/plugin-commonjs-25.0.8.tgz", @@ -643,25 +415,11 @@ "node": ">=10.13.0" } }, - "node_modules/@types/esrecurse": { - "version": "4.3.1", - "resolved": "https://registry.npmjs.org/@types/esrecurse/-/esrecurse-4.3.1.tgz", - "integrity": "sha512-xJBAbDifo5hpffDBuHl0Y8ywswbiAp/Wi7Y/GtAgSlZyIABppyurxVueOPE8LUQOxdlgi6Zqce7uoEpqNTeiUw==", - "dev": true, - "license": "MIT" - }, "node_modules/@types/estree": { "version": "1.0.8", "resolved": "https://registry.npmjs.org/@types/estree/-/estree-1.0.8.tgz", "integrity": "sha512-dWHzHa2WqEXI/O1E9OjrocMTKJl2mSrEolh1Iomrv6U+JuNwaHXsXx9bLu5gG7BUWFIN0skIQJQ/L1rIex4X6w==" }, - "node_modules/@types/json-schema": { - "version": "7.0.15", - "resolved": "https://registry.npmjs.org/@types/json-schema/-/json-schema-7.0.15.tgz", - "integrity": "sha512-5+fP8P8MFNC+AyZCDxrB2pkZFPGzqQWUzpSeuuVLvm8VMcorNYavBqoFcxK8bQz4Qsbn4oUEEem4wDLfcysGHA==", - "dev": true, - "license": "MIT" - }, "node_modules/@types/resolve": { "version": "1.20.2", "resolved": "https://registry.npmjs.org/@types/resolve/-/resolve-1.20.2.tgz", @@ -700,46 +458,6 @@ "node": ">=12" } }, - "node_modules/acorn": { - "version": "8.16.0", - "resolved": "https://registry.npmjs.org/acorn/-/acorn-8.16.0.tgz", - "integrity": "sha512-UVJyE9MttOsBQIDKw1skb9nAwQuR5wuGD3+82K6JgJlm/Y+KI92oNsMNGZCYdDsVtRHSak0pcV5Dno5+4jh9sw==", - "dev": true, - "license": "MIT", - "bin": { - "acorn": "bin/acorn" - }, - "engines": { - "node": ">=0.4.0" - } - }, - "node_modules/acorn-jsx": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/acorn-jsx/-/acorn-jsx-5.3.2.tgz", - "integrity": "sha512-rq9s+JNhf0IChjtDXxllJ7g41oZk5SlXtp0LHwyA5cejwn7vKmKp4pPri6YEePv2PU65sAsegbXtIinmDFDXgQ==", - "dev": true, - "license": "MIT", - "peerDependencies": { - "acorn": "^6.0.0 || ^7.0.0 || ^8.0.0" - } - }, - "node_modules/ajv": { - "version": "6.14.0", - "resolved": "https://registry.npmjs.org/ajv/-/ajv-6.14.0.tgz", - "integrity": "sha512-IWrosm/yrn43eiKqkfkHis7QioDleaXQHdDVPKg0FSwwd/DuvyX79TZnFOnYpB7dcsFAMmtFztZuXPDvSePkFw==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-deep-equal": "^3.1.1", - "fast-json-stable-stringify": "^2.0.0", - "json-schema-traverse": "^0.4.1", - "uri-js": "^4.2.2" - }, - "funding": { - "type": "github", - "url": "https://github.com/sponsors/epoberezkin" - } - }, "node_modules/ansi-colors": { "version": "1.1.0", "resolved": "https://registry.npmjs.org/ansi-colors/-/ansi-colors-1.1.0.tgz", @@ -1699,13 +1417,6 @@ } } }, - "node_modules/deep-is": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/deep-is/-/deep-is-0.1.4.tgz", - "integrity": "sha512-oIPzksmTg4/MriiaYGO+okXDT7ztn/w3Eptv/+gSIdMdKsJo0u4CfYNFJPy+4SKMuCqGw2wxnA+URMg3t8a/bQ==", - "dev": true, - "license": "MIT" - }, "node_modules/deepmerge": { "version": "4.3.1", "resolved": "https://registry.npmjs.org/deepmerge/-/deepmerge-4.3.1.tgz", @@ -1911,190 +1622,6 @@ "node": ">=6" } }, - "node_modules/escape-string-regexp": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/escape-string-regexp/-/escape-string-regexp-4.0.0.tgz", - "integrity": "sha512-TtpcNJ3XAzx3Gq8sWRzJaVajRs0uVxA2YAkdb1jm2YkPz4G6egUFAyA3n5vtEIZefPk5Wa4UXbKuS5fKkJWdgA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/eslint": { - "version": "10.2.1", - "resolved": "https://registry.npmjs.org/eslint/-/eslint-10.2.1.tgz", - "integrity": "sha512-wiyGaKsDgqXvF40P8mDwiUp/KQjE1FdrIEJsM8PZ3XCiniTMXS3OHWWUe5FI5agoCnr8x4xPrTDZuxsBlNHl+Q==", - "dev": true, - "license": "MIT", - "dependencies": { - "@eslint-community/eslint-utils": "^4.8.0", - "@eslint-community/regexpp": "^4.12.2", - "@eslint/config-array": "^0.23.5", - "@eslint/config-helpers": "^0.5.5", - "@eslint/core": "^1.2.1", - "@eslint/plugin-kit": "^0.7.1", - "@humanfs/node": "^0.16.6", - "@humanwhocodes/module-importer": "^1.0.1", - "@humanwhocodes/retry": "^0.4.2", - "@types/estree": "^1.0.6", - "ajv": "^6.14.0", - "cross-spawn": "^7.0.6", - "debug": "^4.3.2", - "escape-string-regexp": "^4.0.0", - "eslint-scope": "^9.1.2", - "eslint-visitor-keys": "^5.0.1", - "espree": "^11.2.0", - "esquery": "^1.7.0", - "esutils": "^2.0.2", - "fast-deep-equal": "^3.1.3", - "file-entry-cache": "^8.0.0", - "find-up": "^5.0.0", - "glob-parent": "^6.0.2", - "ignore": "^5.2.0", - "imurmurhash": "^0.1.4", - "is-glob": "^4.0.0", - "json-stable-stringify-without-jsonify": "^1.0.1", - "minimatch": "^10.2.4", - "natural-compare": "^1.4.0", - "optionator": "^0.9.3" - }, - "bin": { - "eslint": "bin/eslint.js" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - }, - "funding": { - "url": "https://eslint.org/donate" - }, - "peerDependencies": { - "jiti": "*" - }, - "peerDependenciesMeta": { - "jiti": { - "optional": true - } - } - }, - "node_modules/eslint-plugin-prettier": { - "version": "5.5.5", - "resolved": "https://registry.npmjs.org/eslint-plugin-prettier/-/eslint-plugin-prettier-5.5.5.tgz", - "integrity": "sha512-hscXkbqUZ2sPithAuLm5MXL+Wph+U7wHngPBv9OMWwlP8iaflyxpjTYZkmdgB4/vPIhemRlBEoLrH7UC1n7aUw==", - "dev": true, - "license": "MIT", - "dependencies": { - "prettier-linter-helpers": "^1.0.1", - "synckit": "^0.11.12" - }, - "engines": { - "node": "^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/eslint-plugin-prettier" - }, - "peerDependencies": { - "@types/eslint": ">=8.0.0", - "eslint": ">=8.0.0", - "eslint-config-prettier": ">= 7.0.0 <10.0.0 || >=10.1.0", - "prettier": ">=3.0.0" - }, - "peerDependenciesMeta": { - "@types/eslint": { - "optional": true - }, - "eslint-config-prettier": { - "optional": true - } - } - }, - "node_modules/eslint-scope": { - "version": "9.1.2", - "resolved": "https://registry.npmjs.org/eslint-scope/-/eslint-scope-9.1.2.tgz", - "integrity": "sha512-xS90H51cKw0jltxmvmHy2Iai1LIqrfbw57b79w/J7MfvDfkIkFZ+kj6zC3BjtUwh150HsSSdxXZcsuv72miDFQ==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "@types/esrecurse": "^4.3.1", - "@types/estree": "^1.0.8", - "esrecurse": "^4.3.0", - "estraverse": "^5.2.0" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint-visitor-keys": { - "version": "5.0.1", - "resolved": "https://registry.npmjs.org/eslint-visitor-keys/-/eslint-visitor-keys-5.0.1.tgz", - "integrity": "sha512-tD40eHxA35h0PEIZNeIjkHoDR4YjjJp34biM0mDvplBe//mB+IHCqHDGV7pxF+7MklTvighcCPPZC7ynWyjdTA==", - "dev": true, - "license": "Apache-2.0", - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/eslint/node_modules/balanced-match": { - "version": "4.0.4", - "resolved": "https://registry.npmjs.org/balanced-match/-/balanced-match-4.0.4.tgz", - "integrity": "sha512-BLrgEcRTwX2o6gGxGOCNyMvGSp35YofuYzw9h1IMTRmKqttAZZVU67bdb9Pr2vUHA8+j3i2tJfjO6C6+4myGTA==", - "dev": true, - "license": "MIT", - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/eslint/node_modules/brace-expansion": { - "version": "5.0.5", - "resolved": "https://registry.npmjs.org/brace-expansion/-/brace-expansion-5.0.5.tgz", - "integrity": "sha512-VZznLgtwhn+Mact9tfiwx64fA9erHH/MCXEUfB/0bX/6Fz6ny5EGTXYltMocqg4xFAQZtnO3DHWWXi8RiuN7cQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "balanced-match": "^4.0.2" - }, - "engines": { - "node": "18 || 20 || >=22" - } - }, - "node_modules/eslint/node_modules/glob-parent": { - "version": "6.0.2", - "resolved": "https://registry.npmjs.org/glob-parent/-/glob-parent-6.0.2.tgz", - "integrity": "sha512-XxwI8EOhVQgWp6iDL+3b0r86f4d6AX6zSU55HfB4ydCEuXLXc5FcYeOu+nnGftS4TEju/11rt4KJPTMgbfmv4A==", - "dev": true, - "license": "ISC", - "dependencies": { - "is-glob": "^4.0.3" - }, - "engines": { - "node": ">=10.13.0" - } - }, - "node_modules/eslint/node_modules/minimatch": { - "version": "10.2.5", - "resolved": "https://registry.npmjs.org/minimatch/-/minimatch-10.2.5.tgz", - "integrity": "sha512-MULkVLfKGYDFYejP07QOurDLLQpcjk7Fw+7jXS2R2czRQzR56yHRveU5NDJEOviH+hETZKSkIk5c+T23GjFUMg==", - "dev": true, - "license": "BlueOak-1.0.0", - "dependencies": { - "brace-expansion": "^5.0.5" - }, - "engines": { - "node": "18 || 20 || >=22" - }, - "funding": { - "url": "https://github.com/sponsors/isaacs" - } - }, "node_modules/esm": { "version": "3.2.25", "resolved": "https://registry.npmjs.org/esm/-/esm-3.2.25.tgz", @@ -2104,76 +1631,12 @@ "node": ">=6" } }, - "node_modules/espree": { - "version": "11.2.0", - "resolved": "https://registry.npmjs.org/espree/-/espree-11.2.0.tgz", - "integrity": "sha512-7p3DrVEIopW1B1avAGLuCSh1jubc01H2JHc8B4qqGblmg5gI9yumBgACjWo4JlIc04ufug4xJ3SQI8HkS/Rgzw==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "acorn": "^8.16.0", - "acorn-jsx": "^5.3.2", - "eslint-visitor-keys": "^5.0.1" - }, - "engines": { - "node": "^20.19.0 || ^22.13.0 || >=24" - }, - "funding": { - "url": "https://opencollective.com/eslint" - } - }, - "node_modules/esquery": { - "version": "1.7.0", - "resolved": "https://registry.npmjs.org/esquery/-/esquery-1.7.0.tgz", - "integrity": "sha512-Ap6G0WQwcU/LHsvLwON1fAQX9Zp0A2Y6Y/cJBl9r/JbW90Zyg4/zbG6zzKa2OTALELarYHmKu0GhpM5EO+7T0g==", - "dev": true, - "license": "BSD-3-Clause", - "dependencies": { - "estraverse": "^5.1.0" - }, - "engines": { - "node": ">=0.10" - } - }, - "node_modules/esrecurse": { - "version": "4.3.0", - "resolved": "https://registry.npmjs.org/esrecurse/-/esrecurse-4.3.0.tgz", - "integrity": "sha512-KmfKL3b6G+RXvP8N1vr3Tq1kL/oCFgn2NYXEtqP8/L3pKapUA4G8cFVaoF3SU323CD4XypR/ffioHmkti6/Tag==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "estraverse": "^5.2.0" - }, - "engines": { - "node": ">=4.0" - } - }, - "node_modules/estraverse": { - "version": "5.3.0", - "resolved": "https://registry.npmjs.org/estraverse/-/estraverse-5.3.0.tgz", - "integrity": "sha512-MMdARuVEQziNTeJD8DgMqmhwR11BRQ/cBP+pLtYdSTnf3MIO8fFeiINEbX36ZdNlfU/7A9f3gUw49B3oQsvwBA==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=4.0" - } - }, "node_modules/estree-walker": { "version": "2.0.2", "resolved": "https://registry.npmjs.org/estree-walker/-/estree-walker-2.0.2.tgz", "integrity": "sha512-Rfkk/Mp/DL7JVje3u18FxFujQlTNR2q6QfMSMB7AvCBx91NGj/ba3kCfza0f6dVDbw7YlRf/nDrn7pQrCCyQ/w==", "dev": true }, - "node_modules/esutils": { - "version": "2.0.3", - "resolved": "https://registry.npmjs.org/esutils/-/esutils-2.0.3.tgz", - "integrity": "sha512-kVscqXk4OCp68SZ0dkgEKVi6/8ij300KBWTJq32P/dYeWTSwK41WyTxalN1eRmA5Z9UU/LX9D7FWSmV9SAYx6g==", - "dev": true, - "license": "BSD-2-Clause", - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/eventemitter3": { "version": "5.0.1", "resolved": "https://registry.npmjs.org/eventemitter3/-/eventemitter3-5.0.1.tgz", @@ -2231,32 +1694,11 @@ "node": ">=0.10.0" } }, - "node_modules/fast-deep-equal": { - "version": "3.1.3", - "resolved": "https://registry.npmjs.org/fast-deep-equal/-/fast-deep-equal-3.1.3.tgz", - "integrity": "sha512-f3qQ9oQy9j2AhBe/H9VC91wLmKBCCU/gDOnKNAYG5hswO7BLKj09Hc5HYNz9cGI++xlpDCIgDaitVs03ATR84Q==", - "dev": true, - "license": "MIT" - }, - "node_modules/fast-diff": { - "version": "1.3.0", - "resolved": "https://registry.npmjs.org/fast-diff/-/fast-diff-1.3.0.tgz", - "integrity": "sha512-VxPP4NqbUjj6MaAOafWeUn2cXWLcCtljklUtZf0Ind4XQ+QPtmA0b18zZy0jIQx+ExRVCR/ZQpBmik5lXshNsw==", - "dev": true, - "license": "Apache-2.0" - }, "node_modules/fast-fifo": { "version": "1.3.2", "resolved": "https://registry.npmjs.org/fast-fifo/-/fast-fifo-1.3.2.tgz", "integrity": "sha512-/d9sfos4yxzpwkDkuN7k2SqFKtYNmCTzgfEpz82x34IM9/zc8KGxQoXg1liNC/izpRM/MBdt44Nmx41ZWqk+FQ==" }, - "node_modules/fast-json-stable-stringify": { - "version": "2.1.0", - "resolved": "https://registry.npmjs.org/fast-json-stable-stringify/-/fast-json-stable-stringify-2.1.0.tgz", - "integrity": "sha512-lhd/wF+Lk98HZoTCtlVraHtfh5XYijIjalXck7saUtuanSDyLMxnHhSXEDJqHxD7msR8D0uCmqlkwjCV8xvwHw==", - "dev": true, - "license": "MIT" - }, "node_modules/fast-levenshtein": { "version": "3.0.0", "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-3.0.0.tgz", @@ -2281,19 +1723,6 @@ "reusify": "^1.0.4" } }, - "node_modules/file-entry-cache": { - "version": "8.0.0", - "resolved": "https://registry.npmjs.org/file-entry-cache/-/file-entry-cache-8.0.0.tgz", - "integrity": "sha512-XXTUwCvisa5oacNGRP9SfNtYBNAMi+RPwBFmblZEF7N7swHYQS6/Zfk7SRwx4D5j3CH211YNRco1DEMNVfZCnQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "flat-cache": "^4.0.0" - }, - "engines": { - "node": ">=16.0.0" - } - }, "node_modules/fill-range": { "version": "7.1.1", "resolved": "https://registry.npmjs.org/fill-range/-/fill-range-7.1.1.tgz", @@ -2305,23 +1734,6 @@ "node": ">=8" } }, - "node_modules/find-up": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/find-up/-/find-up-5.0.0.tgz", - "integrity": "sha512-78/PXT1wlLLDgTzDs7sjq9hzz0vXD+zn+7wypEe4fXQxCmdmqfGsEPQxmiCSQI3ajFV91bVSsvNtrJRiW6nGng==", - "dev": true, - "license": "MIT", - "dependencies": { - "locate-path": "^6.0.0", - "path-exists": "^4.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/findup-sync": { "version": "5.0.0", "resolved": "https://registry.npmjs.org/findup-sync/-/findup-sync-5.0.0.tgz", @@ -2359,27 +1771,6 @@ "node": ">= 10.13.0" } }, - "node_modules/flat-cache": { - "version": "4.0.1", - "resolved": "https://registry.npmjs.org/flat-cache/-/flat-cache-4.0.1.tgz", - "integrity": "sha512-f7ccFPK3SXFHpx15UIGyRJ/FJQctuKZ0zVuN3frBo4HnK3cay9VEW0R6yPYFHC0AgqhukPzKjq22t5DmAyqGyw==", - "dev": true, - "license": "MIT", - "dependencies": { - "flatted": "^3.2.9", - "keyv": "^4.5.4" - }, - "engines": { - "node": ">=16" - } - }, - "node_modules/flatted": { - "version": "3.4.2", - "resolved": "https://registry.npmjs.org/flatted/-/flatted-3.4.2.tgz", - "integrity": "sha512-PjDse7RzhcPkIJwy5t7KPWQSZ9cAbzQXcafsetQoD7sOJRQlGikNbx7yZp2OotDnJyrDcbyRq3Ttb18iYOqkxA==", - "dev": true, - "license": "ISC" - }, "node_modules/for-each": { "version": "0.3.5", "resolved": "https://registry.npmjs.org/for-each/-/for-each-0.3.5.tgz", @@ -2642,19 +2033,6 @@ "which": "bin/which" } }, - "node_modules/globals": { - "version": "17.5.0", - "resolved": "https://registry.npmjs.org/globals/-/globals-17.5.0.tgz", - "integrity": "sha512-qoV+HK2yFl/366t2/Cb3+xxPUo5BuMynomoDmiaZBIdbs+0pYbjfZU+twLhGKp4uCZ/+NbtpVepH5bGCxRyy2g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=18" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/glogg": { "version": "2.2.0", "resolved": "https://registry.npmjs.org/glogg/-/glogg-2.2.0.tgz", @@ -3003,16 +2381,6 @@ } ] }, - "node_modules/ignore": { - "version": "5.3.2", - "resolved": "https://registry.npmjs.org/ignore/-/ignore-5.3.2.tgz", - "integrity": "sha512-hsBTNUqQTDwkWtcdYI2i06Y/nUBEsNEDJKjWdigLvegy8kDuJAS8uRlpkkcQpyEXL0Z/pjDy5HBmMjRCJ2gq+g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 4" - } - }, "node_modules/image-size": { "version": "0.5.5", "resolved": "https://registry.npmjs.org/image-size/-/image-size-0.5.5.tgz", @@ -3055,16 +2423,6 @@ "node": ">=8" } }, - "node_modules/imurmurhash": { - "version": "0.1.4", - "resolved": "https://registry.npmjs.org/imurmurhash/-/imurmurhash-0.1.4.tgz", - "integrity": "sha512-JmXMZ6wuvDmLiHEml9ykzqO6lwFbof0GG4IkcGaENdCRDDmMVnny7s5HsIgHCbaq0w2MyPhDqkhTUgS2LU2PHA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.8.19" - } - }, "node_modules/inflight": { "version": "1.0.6", "resolved": "https://registry.npmjs.org/inflight/-/inflight-1.0.6.tgz", @@ -3411,37 +2769,6 @@ "js-yaml": "bin/js-yaml.js" } }, - "node_modules/json-buffer": { - "version": "3.0.1", - "resolved": "https://registry.npmjs.org/json-buffer/-/json-buffer-3.0.1.tgz", - "integrity": "sha512-4bV5BfR2mqfQTJm+V5tPPdf+ZpuhiIvTuAB5g8kcrXOZpTT/QwwVRWBywX1ozr6lEuPdbHxwaJlm9G6mI2sfSQ==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-schema-traverse": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/json-schema-traverse/-/json-schema-traverse-0.4.1.tgz", - "integrity": "sha512-xbbCH5dCYU5T8LcEhhuh7HJ88HXuW3qsI3Y0zOZFKfZEHcpWiHU/Jxzk629Brsab/mMiHQti9wMP+845RPe3Vg==", - "dev": true, - "license": "MIT" - }, - "node_modules/json-stable-stringify-without-jsonify": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/json-stable-stringify-without-jsonify/-/json-stable-stringify-without-jsonify-1.0.1.tgz", - "integrity": "sha512-Bdboy+l7tA3OGW6FjyFHWkP5LuByj1Tk33Ljyq0axyzdk9//JSi2u3fP1QSmd1KNwq6VOKYGlAu87CisVir6Pw==", - "dev": true, - "license": "MIT" - }, - "node_modules/keyv": { - "version": "4.5.4", - "resolved": "https://registry.npmjs.org/keyv/-/keyv-4.5.4.tgz", - "integrity": "sha512-oxVHkHR/EJf2CNXnWxRLW6mg7JyCCUcG0DtEGmL2ctUo1PNTin1PUil+r/+4r5MpVgC/fn1kjsx7mjSujKqIpw==", - "dev": true, - "license": "MIT", - "dependencies": { - "json-buffer": "3.0.1" - } - }, "node_modules/last-run": { "version": "2.0.0", "resolved": "https://registry.npmjs.org/last-run/-/last-run-2.0.0.tgz", @@ -3505,20 +2832,6 @@ "node": ">=12" } }, - "node_modules/levn": { - "version": "0.4.1", - "resolved": "https://registry.npmjs.org/levn/-/levn-0.4.1.tgz", - "integrity": "sha512-+bT2uH4E5LGE7h/n3evcS/sQlJXCpIp6ym8OWJ5eV6+67Dsql/LaaT7qJBAt2rzfoa/5QBGBhxDix1dMt2kQKQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "prelude-ls": "^1.2.1", - "type-check": "~0.4.0" - }, - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/lie": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/lie/-/lie-3.1.1.tgz", @@ -3619,22 +2932,6 @@ "lie": "3.1.1" } }, - "node_modules/locate-path": { - "version": "6.0.0", - "resolved": "https://registry.npmjs.org/locate-path/-/locate-path-6.0.0.tgz", - "integrity": "sha512-iPZK6eYjbxRu3uB4/WZ3EsEIMJFMqAoopl3R+zuq0UjcAm/MO6KCweDgPfP3elTztoKP3KtnVHxTn2NHBSDVUw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-locate": "^5.0.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/lodash": { "version": "4.17.21", "resolved": "https://registry.npmjs.org/lodash/-/lodash-4.17.21.tgz", @@ -3905,13 +3202,6 @@ "integrity": "sha512-hmEVtAGYzVQpCKdbQea4skABsdXW4RUh5t5mJ2zzqowJS2OyXZTU1KhDVFhx+NlWZ4ap9mqR9TcDO3LTTttd+g==", "dev": true }, - "node_modules/natural-compare": { - "version": "1.4.0", - "resolved": "https://registry.npmjs.org/natural-compare/-/natural-compare-1.4.0.tgz", - "integrity": "sha512-OWND8ei3VtNC9h7V60qff3SVobHr996CTwgxubgyQYEpg290h9J0buyECNNJexkFm5sOajh5G116RYA1c8ZMSw==", - "dev": true, - "license": "MIT" - }, "node_modules/nedb-promises": { "version": "6.2.3", "resolved": "https://registry.npmjs.org/nedb-promises/-/nedb-promises-6.2.3.tgz", @@ -4080,31 +3370,6 @@ "url": "https://github.com/sponsors/sindresorhus" } }, - "node_modules/optionator": { - "version": "0.9.4", - "resolved": "https://registry.npmjs.org/optionator/-/optionator-0.9.4.tgz", - "integrity": "sha512-6IpQ7mKUxRcZNLIObR0hz7lxsapSSIYNZJwXPGeF0mTVqGKFIXj1DQcMoT22S3ROcLyY/rz0PWaWZ9ayWmad9g==", - "dev": true, - "license": "MIT", - "dependencies": { - "deep-is": "^0.1.3", - "fast-levenshtein": "^2.0.6", - "levn": "^0.4.1", - "prelude-ls": "^1.2.1", - "type-check": "^0.4.0", - "word-wrap": "^1.2.5" - }, - "engines": { - "node": ">= 0.8.0" - } - }, - "node_modules/optionator/node_modules/fast-levenshtein": { - "version": "2.0.6", - "resolved": "https://registry.npmjs.org/fast-levenshtein/-/fast-levenshtein-2.0.6.tgz", - "integrity": "sha512-DCXu6Ifhqcks7TZKY3Hxp3y6qphY5SJZmrWMDrKcERSOXWQdMhU9Ig/PYrzyw/ul9jOIyh0N4M0tbC5hodg8dw==", - "dev": true, - "license": "MIT" - }, "node_modules/p-finally": { "version": "1.0.0", "resolved": "https://registry.npmjs.org/p-finally/-/p-finally-1.0.0.tgz", @@ -4114,38 +3379,6 @@ "node": ">=4" } }, - "node_modules/p-limit": { - "version": "3.1.0", - "resolved": "https://registry.npmjs.org/p-limit/-/p-limit-3.1.0.tgz", - "integrity": "sha512-TYOanM3wGwNGsZN2cVTYPArw454xnXj5qmWF1bEoAc4+cU/ol7GVh7odevjp1FNHduHc3KZMcFduxU5Xc6uJRQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "yocto-queue": "^0.1.0" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, - "node_modules/p-locate": { - "version": "5.0.0", - "resolved": "https://registry.npmjs.org/p-locate/-/p-locate-5.0.0.tgz", - "integrity": "sha512-LaNjtRWUBY++zB5nE/NwcaoMylSPk+S+ZHNB1TzdbMJMny6dynpAGt7X/tl/QYq3TIeE6nxHppbo2LGymrG5Pw==", - "dev": true, - "license": "MIT", - "dependencies": { - "p-limit": "^3.0.2" - }, - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } - }, "node_modules/p-queue": { "version": "6.6.2", "resolved": "https://registry.npmjs.org/p-queue/-/p-queue-6.6.2.tgz", @@ -4209,16 +3442,6 @@ "node": ">=0.10.0" } }, - "node_modules/path-exists": { - "version": "4.0.0", - "resolved": "https://registry.npmjs.org/path-exists/-/path-exists-4.0.0.tgz", - "integrity": "sha512-ak9Qy5Q7jYb2Wwcey5Fpvg2KoAc/ZIhLSLOSBmRmygPsGwkVVt0fZa0qrtMz+m6tJTAHfZQ8FnmB4MG4LWy7/w==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=8" - } - }, "node_modules/path-key": { "version": "3.1.1", "resolved": "https://registry.npmjs.org/path-key/-/path-key-3.1.1.tgz", @@ -4917,16 +4140,6 @@ "integrity": "sha512-1NNCs6uurfkVbeXG4S8JFT9t19m45ICnif8zWLd5oPSZ50QnwMfK+H3jv408d4jw/7Bttv5axS5IiHoLaVNHeQ==", "dev": true }, - "node_modules/prelude-ls": { - "version": "1.2.1", - "resolved": "https://registry.npmjs.org/prelude-ls/-/prelude-ls-1.2.1.tgz", - "integrity": "sha512-vkcDPrRZo1QZLbn5RLGPpg/WmIQ65qoWWhcGKf/b5eplkkarX0m9z8ppCat4mlOqUsWpyNuYgO3VRyrYHSzX5g==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/prettier": { "version": "3.5.3", "resolved": "https://registry.npmjs.org/prettier/-/prettier-3.5.3.tgz", @@ -4942,19 +4155,6 @@ "url": "https://github.com/prettier/prettier?sponsor=1" } }, - "node_modules/prettier-linter-helpers": { - "version": "1.0.1", - "resolved": "https://registry.npmjs.org/prettier-linter-helpers/-/prettier-linter-helpers-1.0.1.tgz", - "integrity": "sha512-SxToR7P8Y2lWmv/kTzVLC1t/GDI2WGjMwNhLLE9qtH8Q13C+aEmuRlzDst4Up4s0Wc8sF2M+J57iB3cMLqftfg==", - "dev": true, - "license": "MIT", - "dependencies": { - "fast-diff": "^1.1.2" - }, - "engines": { - "node": ">=6.0.0" - } - }, "node_modules/promise.series": { "version": "0.2.0", "resolved": "https://registry.npmjs.org/promise.series/-/promise.series-0.2.0.tgz", @@ -4981,16 +4181,6 @@ "integrity": "sha512-yPw4Sng1gWghHQWj0B3ZggWUm4qVbPwPFcRG8KyxiU7J2OHFSoEHKS+EZ3fv5l1t9CyCiop6l/ZYeWbrgoQejw==", "optional": true }, - "node_modules/punycode": { - "version": "2.3.1", - "resolved": "https://registry.npmjs.org/punycode/-/punycode-2.3.1.tgz", - "integrity": "sha512-vYt7UD1U9Wg6138shLtLOvdAu+8DsC/ilFtEVHcH+wydcSpNE20AfSOduf6MkRFahL5FY7X1oU7nKVZFtfq8Fg==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=6" - } - }, "node_modules/queue-microtask": { "version": "1.2.3", "resolved": "https://registry.npmjs.org/queue-microtask/-/queue-microtask-1.2.3.tgz", @@ -5760,22 +4950,6 @@ "node": ">= 10" } }, - "node_modules/synckit": { - "version": "0.11.12", - "resolved": "https://registry.npmjs.org/synckit/-/synckit-0.11.12.tgz", - "integrity": "sha512-Bh7QjT8/SuKUIfObSXNHNSK6WHo6J1tHCqJsuaFDP7gP0fkzSfTxI8y85JrppZ0h8l0maIgc2tfuZQ6/t3GtnQ==", - "dev": true, - "license": "MIT", - "dependencies": { - "@pkgr/core": "^0.2.9" - }, - "engines": { - "node": "^14.18.0 || >=16.0.0" - }, - "funding": { - "url": "https://opencollective.com/synckit" - } - }, "node_modules/teex": { "version": "1.0.1", "resolved": "https://registry.npmjs.org/teex/-/teex-1.0.1.tgz", @@ -5836,19 +5010,6 @@ "resolved": "https://registry.npmjs.org/tslib/-/tslib-2.8.1.tgz", "integrity": "sha512-oJFu94HQb+KVduSUQL7wnpmqnfmLsOA/nAh6b6EH0wCEoK0/mPeXU6c3wKDV83MkOuHPRHtSXKKU99IBazS/2w==" }, - "node_modules/type-check": { - "version": "0.4.0", - "resolved": "https://registry.npmjs.org/type-check/-/type-check-0.4.0.tgz", - "integrity": "sha512-XleUoc9uwGXqjWwXaUTZAmzMcFZ5858QA2vvx1Ur5xIcixXIP+8LnFDgRplU30us6teqdlskFfu+ae4K79Ooew==", - "dev": true, - "license": "MIT", - "dependencies": { - "prelude-ls": "^1.2.1" - }, - "engines": { - "node": ">= 0.8.0" - } - }, "node_modules/unc-path-regex": { "version": "0.1.2", "resolved": "https://registry.npmjs.org/unc-path-regex/-/unc-path-regex-0.1.2.tgz", @@ -5909,16 +5070,6 @@ "browserslist": ">= 4.21.0" } }, - "node_modules/uri-js": { - "version": "4.4.1", - "resolved": "https://registry.npmjs.org/uri-js/-/uri-js-4.4.1.tgz", - "integrity": "sha512-7rKUyy33Q1yc98pQ1DAmLtwX109F7TIfWlW1Ydo8Wl1ii1SeHieeh0HHfPeL2fMXK6z0s8ecKs9frCuLJvndBg==", - "dev": true, - "license": "BSD-2-Clause", - "dependencies": { - "punycode": "^2.1.0" - } - }, "node_modules/util": { "version": "0.12.5", "resolved": "https://registry.npmjs.org/util/-/util-0.12.5.tgz", @@ -6071,16 +5222,6 @@ "url": "https://github.com/sponsors/ljharb" } }, - "node_modules/word-wrap": { - "version": "1.2.5", - "resolved": "https://registry.npmjs.org/word-wrap/-/word-wrap-1.2.5.tgz", - "integrity": "sha512-BN22B5eaMMI9UMtjrGd5g5eCYPpCPDUy0FJXbYsaT5zYxjFOckS53SQDE3pWkVoWpHXVb3BrYcEN4Twa55B5cA==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=0.10.0" - } - }, "node_modules/wrap-ansi": { "version": "9.0.0", "resolved": "https://registry.npmjs.org/wrap-ansi/-/wrap-ansi-9.0.0.tgz", @@ -6172,19 +5313,6 @@ "engines": { "node": ">=12" } - }, - "node_modules/yocto-queue": { - "version": "0.1.0", - "resolved": "https://registry.npmjs.org/yocto-queue/-/yocto-queue-0.1.0.tgz", - "integrity": "sha512-rVksvsnNCdJ/ohGc6xgPwyN8eheCxsiLM8mxuE/t/mOVqJewPuO1miLpTHQiRgTKCLexL4MeAFVagts7HmNZ2Q==", - "dev": true, - "license": "MIT", - "engines": { - "node": ">=10" - }, - "funding": { - "url": "https://github.com/sponsors/sindresorhus" - } } } } diff --git a/package.json b/package.json index 28c83549..183d2de2 100644 --- a/package.json +++ b/package.json @@ -17,18 +17,13 @@ "pullYMLtoLDB": "node ./tools/pullYMLtoLDB.mjs", "pullYMLtoLDBBuild": "node ./tools/pullYMLtoLDB.mjs --build", "createSymlink": "node ./tools/create-symlink.mjs", - "setup:dev": "node ./tools/dev-setup.mjs", - "lint": "eslint", - "lint:fix": "eslint --fix" + "setup:dev": "node ./tools/dev-setup.mjs" }, "devDependencies": { "@foundryvtt/foundryvtt-cli": "^1.0.2", "@rollup/plugin-commonjs": "^25.0.7", "@rollup/plugin-node-resolve": "^15.2.3", "concurrently": "^8.2.2", - "eslint": "^10.2.1", - "eslint-plugin-prettier": "^5.5.5", - "globals": "^17.5.0", "husky": "^9.1.5", "lint-staged": "^15.2.10", "postcss": "^8.4.32", diff --git a/src/packs/adversaries/adversary_Acid_Burrower_89yAh30vaNQOALlz.json b/src/packs/adversaries/adversary_Acid_Burrower_89yAh30vaNQOALlz.json index d3c8c955..0dd182fa 100644 --- a/src/packs/adversaries/adversary_Acid_Burrower_89yAh30vaNQOALlz.json +++ b/src/packs/adversaries/adversary_Acid_Burrower_89yAh30vaNQOALlz.json @@ -169,9 +169,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -222,7 +225,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -248,8 +251,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -317,7 +319,7 @@ "_id": "ctXYwil2D1zfsekT", "img": "icons/magic/earth/barrier-stone-explosion-red.webp", "system": { - "description": "

Mark a Stress to have the @Lookup[@name] burst out of the ground. All creatures within Very Close range must succeed on an Agility Reaction Roll or be knocked over, making them Vulnerable until they next act.

", + "description": "

Mark a Stress to have the @Lookup[@name] burst out of the ground. All creatures within Very Close range must succeed on an Agility Reaction Roll or be knocked over, making them Vulnerable until they next act.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "4ppSeiTdbqnMzWAs": { @@ -342,8 +344,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -377,16 +378,7 @@ }, "name": "Roll Save", "img": "icons/magic/earth/barrier-stone-explosion-red.webp", - "range": "veryClose", - "areas": [ - { - "name": "Earth Eruption", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -589,7 +581,7 @@ "_id": "aNIVT5LKhwLyjKpI", "img": "icons/magic/acid/dissolve-drip-droplet-smoke.webp", "system": { - "description": "

When the @Lookup[@name] takes Severe damage, all creatures within Close range are bathed in their acidic blood, taking 1d10 physical damage. This splash covers the ground within Very Close range with blood, and all creatures other than the @Lookup[@name] who move through it take 1d6 physical damage.

", + "description": "

When the @Lookup[@name] takes Severe damage, all creatures within Close range are bathed in their acidic blood, taking 1d10 physical damage. This splash covers the ground within Very Close range with blood, and all creatures other than the @Lookup[@name] who move through it take 1d6 physical damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "XbtTzOBvlTaxOKTy": { @@ -635,8 +627,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -645,23 +636,7 @@ "effects": [], "name": "Splash", "img": "icons/magic/acid/dissolve-drip-droplet-smoke.webp", - "range": "close", - "areas": [ - { - "name": "Acid Bath: Damage Area", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - }, - { - "name": "Acid Ground", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "close" }, "xpcp1ECTWF20kxve": { "type": "damage", @@ -715,8 +690,7 @@ "effects": [], "name": "Acid Ground", "img": "icons/magic/acid/dissolve-pool-bubbles.webp", - "range": "", - "areas": [] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Adult_Flickerfly_G7jiltRjgvVhZewm.json b/src/packs/adversaries/adversary_Adult_Flickerfly_G7jiltRjgvVhZewm.json index ecb93d1b..c4b4eb2a 100644 --- a/src/packs/adversaries/adversary_Adult_Flickerfly_G7jiltRjgvVhZewm.json +++ b/src/packs/adversaries/adversary_Adult_Flickerfly_G7jiltRjgvVhZewm.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -374,7 +376,7 @@ "name": "Whirlwind", "type": "feature", "system": { - "description": "

Spend a Fear to whirl, making an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 3d8 direct physical damage.

", + "description": "

Spend a Fear to whirl, making an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 3d8 direct physical damage.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "RV1wKufKrMPN6MOo": { @@ -427,8 +429,7 @@ } }, "includeBase": false, - "direct": true, - "groupAttack": "" + "direct": true }, "target": { "type": "any", @@ -457,16 +458,7 @@ }, "name": "Attack", "img": "icons/skills/melee/strike-slashes-orange.webp", - "range": "veryClose", - "areas": [ - { - "name": "Whirlwind", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -492,7 +484,7 @@ "name": "Mind Dance", "type": "feature", "system": { - "description": "

Mark a Stress to create a magically dazzling display that grapples the minds of nearby foes. All targets within Close range must make an Instinct Reaction Roll. For each target who failed, you gain a Fear and the @Lookup[@name] learns one of the target’s fears.

", + "description": "

Mark a Stress to create a magically dazzling display that grapples the minds of nearby foes. All targets within Close range must make an Instinct Reaction Roll. For each target who failed, you gain a Fear and the @Lookup[@name] learns one of the target’s fears.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "GNwsDlCabx3fiG4g": { @@ -517,8 +509,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -547,16 +538,7 @@ }, "name": "Roll Save", "img": "icons/magic/light/explosion-glow-spiral-yellow.webp", - "range": "close", - "areas": [ - { - "name": "Mind Dance", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -582,14 +564,14 @@ "name": "Hallucinatory Breath", "type": "feature", "system": { - "description": "

Countdown (Loop 1d6). When the @Lookup[@name] takes damage for the first time, activate the countdown. When it triggers, the @Lookup[@name] breathes hallucinatory gas on all targets in front of them up to Far range. Targets must make an Instinct Reaction Roll or be tormented by fearful hallucinations. Targets whose fears are known to the @Lookup[@name] have disadvantage on this roll. Targets who fail lose 2 Hope and take 3d8+3 direct magic damage.

", + "description": "

Countdown (Loop 1d6). When the @Lookup[@name] takes damage for the first time, activate the countdown. When it triggers, the @Lookup[@name] breathes hallucinatory gas on all targets in front of them up to Far range. Targets must make an Instinct Reaction Roll or be tormented by fearful hallucinations. Targets whose fears are known to the @Lookup[@name] have disadvantage on this roll. Targets who fail lose 2 Hope and take 3d8+3 direct magic damage.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "YOyKyKGTUEWkMmJe": { "type": "attack", "_id": "YOyKyKGTUEWkMmJe", "systemPath": "actions", - "description": "", + "description": "

The @Lookup[@name] breathes hallucinatory gas on all targets in front of them up to Far range. Targets must make an Instinct Reaction Roll or be tormented by fearful hallucinations. Targets whose fears are known to the @Lookup[@name] have disadvantage on this roll. Targets who fail lose 2 Hope and take 3d8+3 direct magic damage.

@Template[type:inFront|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -652,8 +634,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -682,16 +663,7 @@ }, "name": "Roll Save", "img": "icons/magic/air/fog-gas-smoke-purple.webp", - "range": "far", - "areas": [ - { - "name": "Hallucinatory Breath", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "lBhmLc33pcXzJHT3": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Apprentice_Assassin_vNIbYQ4YSzNf0WPE.json b/src/packs/adversaries/adversary_Apprentice_Assassin_vNIbYQ4YSzNf0WPE.json index 12ec35ae..4c63297d 100644 --- a/src/packs/adversaries/adversary_Apprentice_Assassin_vNIbYQ4YSzNf0WPE.json +++ b/src/packs/adversaries/adversary_Apprentice_Assassin_vNIbYQ4YSzNf0WPE.json @@ -131,9 +131,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -184,7 +187,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -210,8 +213,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -247,95 +249,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "SrNyZgPvCXMpbCLG": { - "type": "attack", - "_id": "SrNyZgPvCXMpbCLG", + "vgguNWz8vG8aoLXR": { + "type": "effect", + "_id": "vgguNWz8vG8aoLXR", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "4" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" + "recovery": null }, + "effects": [], "target": { "type": "any", "amount": null }, - "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" - }, "name": "Spend Fear", + "img": "icons/magic/unholy/orb-hands-pink.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Arch_Necromancer_WPEOIGfclNJxWb87.json b/src/packs/adversaries/adversary_Arch_Necromancer_WPEOIGfclNJxWb87.json index 5da74eb3..dfae0598 100644 --- a/src/packs/adversaries/adversary_Arch_Necromancer_WPEOIGfclNJxWb87.json +++ b/src/packs/adversaries/adversary_Arch_Necromancer_WPEOIGfclNJxWb87.json @@ -143,9 +143,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -196,7 +199,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -222,8 +225,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -310,7 +312,7 @@ "name": "Beam Of Decay", "type": "feature", "system": { - "description": "

Mark 2 Stress to cause all targets within Far range to make a Strength Reaction Roll. Targets who fail take 2d20+12 magic damage and you gain a Fear. Targets who succeed take half damage. A target who marks 2 or more HP must also mark 2 Stress and becomes Vulnerable until they roll with Hope.

", + "description": "

Mark 2 Stress to cause all targets within Far range to make a Strength Reaction Roll. Targets who fail take 2d20+12 magic damage and you gain a Fear. Targets who succeed take half damage. A target who marks 2 or more HP must also mark 2 Stress and becomes Vulnerable until they roll with Hope.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "vaXLESD4sRkQ3Ahn": { @@ -362,8 +364,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -397,16 +398,7 @@ }, "name": "Roll Save", "img": "icons/magic/unholy/projectile-missile-green.webp", - "range": "far", - "areas": [ - { - "name": "Beam Of Decay", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "ME8AMAjgTAChHa3C": { "type": "healing", diff --git a/src/packs/adversaries/adversary_Archer_Squadron_0ts6CGd93lLqGZI5.json b/src/packs/adversaries/adversary_Archer_Squadron_0ts6CGd93lLqGZI5.json index 1e45b90a..67e10c53 100644 --- a/src/packs/adversaries/adversary_Archer_Squadron_0ts6CGd93lLqGZI5.json +++ b/src/packs/adversaries/adversary_Archer_Squadron_0ts6CGd93lLqGZI5.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -244,7 +246,7 @@ "name": "Focused Volley", "type": "feature", "system": { - "description": "

Spend a Fear to target a point within Far range. Make an attack with advantage against all targets within Close range of that point. Targets the @Lookup[@name] succeeds against take 1d10+4 physical damage.

", + "description": "

Spend a Fear to target a point within Far range. Make an attack with advantage against all targets within Close range of that point. Targets the @Lookup[@name] succeeds against take 1d10+4 physical damage.

@Template[type:circle|range:c]

", "resource": null, "actions": { "uG7Hl2DqaT69aNs1": { @@ -294,8 +296,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -324,16 +325,7 @@ }, "name": "Attack", "img": "icons/skills/ranged/arrows-flying-triple-brown.webp", - "range": "far", - "areas": [ - { - "name": "Focused Volley", - "type": "placed", - "shape": "circle", - "size": "close", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -359,7 +351,7 @@ "name": "Supressing Fire", "type": "feature", "system": { - "description": "

Mark a Stress to target a point within Far range. Until the next roll with Fear, a creature who moves within Close range of that point must make an Agility Reaction Roll. On a failure, they take 2d6+3 physical damage. On a success, they take half damage.

", + "description": "

Mark a Stress to target a point within Far range. Until the next roll with Fear, a creature who moves within Close range of that point must make an Agility Reaction Roll. On a failure, they take 2d6+3 physical damage. On a success, they take half damage.

@Template[type:circle|range:c]

", "resource": null, "actions": { "mH6mmJIMM1fwzePt": { @@ -402,8 +394,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -432,16 +423,7 @@ }, "name": "Agility Roll", "img": "icons/skills/ranged/arrows-flying-salvo-blue.webp", - "range": "", - "areas": [ - { - "name": "Supressing Fire", - "type": "placed", - "shape": "circle", - "size": "close", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Assassin_Poisoner_h5RuhzGL17dW5FBT.json b/src/packs/adversaries/adversary_Assassin_Poisoner_h5RuhzGL17dW5FBT.json index c1bce57b..4b3a872a 100644 --- a/src/packs/adversaries/adversary_Assassin_Poisoner_h5RuhzGL17dW5FBT.json +++ b/src/packs/adversaries/adversary_Assassin_Poisoner_h5RuhzGL17dW5FBT.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -397,7 +399,7 @@ "name": "Fumigation", "type": "feature", "system": { - "description": "

Drop a smoke bomb that fills the air within Close range with smoke, Dizzying all targets in this area. Dizzied targets have disadvantage on their next action roll, then clear the condition.

", + "description": "

Drop a smoke bomb that fills the air within Close range with smoke, Dizzying all targets in this area. Dizzied targets have disadvantage on their next action roll, then clear the condition.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "sp7RfJRQJsEUm09m": { @@ -425,16 +427,7 @@ }, "name": "Drop Bomb", "img": "icons/magic/air/fog-gas-smoke-green.webp", - "range": "close", - "areas": [ - { - "name": "Fumigation", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -457,15 +450,18 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [] + } }, + "changes": [], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, "description": "

Dizzied targets have disadvantage on their next action roll, then clear the condition.

", "tint": "#ffffff", @@ -475,9 +471,6 @@ "_stats": { "compendiumSource": null }, - "start": null, - "showIcon": 1, - "folder": null, "_key": "!actors.items.effects!h5RuhzGL17dW5FBT.lAmiK8wVxjyHwKlp.yP4ot8VqS56RnxnE" } ], diff --git a/src/packs/adversaries/adversary_Battle_Box_dgH3fW9FTYLaIDvS.json b/src/packs/adversaries/adversary_Battle_Box_dgH3fW9FTYLaIDvS.json index be47829b..74ed8dfd 100644 --- a/src/packs/adversaries/adversary_Battle_Box_dgH3fW9FTYLaIDvS.json +++ b/src/packs/adversaries/adversary_Battle_Box_dgH3fW9FTYLaIDvS.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -463,7 +465,7 @@ "name": "Fire Jets", "type": "feature", "system": { - "description": "

The @Lookup[@name] shoots into the air, spinning and releasing jets of flame. Make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d8 physical damage.

", + "description": "

The @Lookup[@name] shoots into the air, spinning and releasing jets of flame. Make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d8 physical damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "hRAKaOdzQXLYBNVV": { @@ -508,8 +510,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -538,16 +539,7 @@ }, "name": "Attack", "img": "icons/magic/fire/explosion-embers-orange.webp", - "range": "close", - "areas": [ - { - "name": "Fire Jets", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -573,7 +565,7 @@ "name": "Trample", "type": "feature", "system": { - "description": "

The @Lookup[@name] rockets around erratically. Make an attack against all PCs within Close range. Targets the @Lookup[@name] succeeds against take 1d6+5 physical damage and are Vulnerable until their next roll with Hope.

", + "description": "

The @Lookup[@name] rockets around erratically. Make an attack against all PCs within Close range. Targets the @Lookup[@name] succeeds against take 1d6+5 physical damage and are Vulnerable until their next roll with Hope.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "IOgPMu12Xnn33TfG": { @@ -618,8 +610,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -653,16 +644,7 @@ }, "name": "Attack", "img": "icons/skills/movement/arrow-upward-yellow.webp", - "range": "close", - "areas": [ - { - "name": "Trample", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -738,7 +720,7 @@ "name": "Shocking Gas", "type": "feature", "system": { - "description": "

The @Lookup[@name] sprays out a silver gas sparking with lightning. All targets within Close range must succeed on a Finesse Reaction Roll or mark 3 Stress.

", + "description": "

The @Lookup[@name] sprays out a silver gas sparking with lightning. All targets within Close range must succeed on a Finesse Reaction Roll or mark 3 Stress.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "ky4OMl558J5wCbDp": { @@ -782,8 +764,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -812,16 +793,7 @@ }, "name": "Roll Save", "img": "icons/magic/lightning/bolt-strike-embers-teal.webp", - "range": "close", - "areas": [ - { - "name": "Shocking Gas", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -847,7 +819,7 @@ "name": "Stunning Clap", "type": "feature", "system": { - "description": "

The @Lookup[@name] leaps and their sides clap, creating a small sonic boom. All targets within Very Close range must succeed on a Strength Reaction Roll or become Vulnerable until the cube is defeated.

", + "description": "

The @Lookup[@name] leaps and their sides clap, creating a small sonic boom. All targets within Very Close range must succeed on a Strength Reaction Roll or become Vulnerable until the cube is defeated.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "LQtopkrtSlCQ5MAr": { @@ -865,8 +837,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -900,16 +871,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/explosion-impact-shock-wave.webp", - "range": "veryClose", - "areas": [ - { - "name": "Stunning Clap", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -985,7 +947,7 @@ "name": "Psionic Whine", "type": "feature", "system": { - "description": "

The @Lookup[@name] releases a cluster of mechanical bees whose buzz rattles mortal minds. All targets within Close range must succeed on a Presence Reaction Roll or take 2d4+9 direct magic damage.

", + "description": "

The @Lookup[@name] releases a cluster of mechanical bees whose buzz rattles mortal minds. All targets within Close range must succeed on a Presence Reaction Roll or take 2d4+9 direct magic damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "3R3pGOUj4rHaUzPK": { @@ -1030,8 +992,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -1060,16 +1021,7 @@ }, "name": "Bees!", "img": "icons/creatures/invertebrates/wasp-swarm-tan.webp", - "range": "close", - "areas": [ - { - "name": "Psionic Whine", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -1196,7 +1148,7 @@ "name": "Death Quake", "type": "feature", "system": { - "description": "

When the @Lookup[@name] marks their last HP, the magic powering them ruptures in an explosion of force. All targets within Close range must succeed on an Instinct Reaction Roll or take 2d8+1 magic damage

", + "description": "

When the @Lookup[@name] marks their last HP, the magic powering them ruptures in an explosion of force. All targets within Close range must succeed on an Instinct Reaction Roll or take 2d8+1 magic damage

@Template[type:emanation|range:c]

", "resource": null, "actions": { "oCpv4zi9jtEpo0K1": { @@ -1241,8 +1193,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -1271,16 +1222,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/explosion-shock-wave-teal.webp", - "range": "close", - "areas": [ - { - "name": "Death Quake", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Cave_Ogre_8Zkqk1jU09nKL2fy.json b/src/packs/adversaries/adversary_Cave_Ogre_8Zkqk1jU09nKL2fy.json index a1bf6bc9..cb081441 100644 --- a/src/packs/adversaries/adversary_Cave_Ogre_8Zkqk1jU09nKL2fy.json +++ b/src/packs/adversaries/adversary_Cave_Ogre_8Zkqk1jU09nKL2fy.json @@ -139,9 +139,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -192,7 +195,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -218,8 +221,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -310,7 +312,7 @@ "_id": "zGvaBYJPOOnQVQEn", "img": "icons/magic/earth/projectile-stone-boulder-orange.webp", "system": { - "description": "

Mark a Stress to pick up heavy objects and throw them at all targets in front of the @Lookup[@name] within Far range. Make an attack against these targets. Targets the @Lookup[@name] succeeds against take 1d10+2 physical damage. If they succeed against more than one target, you gain a Fear.

", + "description": "

Mark a Stress to pick up heavy objects and throw them at all targets in front of the @Lookup[@name] within Far range. Make an attack against these targets. Targets the @Lookup[@name] succeeds against take 1d10+2 physical damage. If they succeed against more than one target, you gain a Fear.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "3p1qfHy5uHe4H2hB": { @@ -365,8 +367,7 @@ } }, "includeBase": false, - "direct": true, - "groupAttack": "" + "direct": true }, "target": { "type": "any", @@ -395,16 +396,7 @@ }, "name": "Throw", "img": "icons/magic/earth/projectile-stone-boulder-orange.webp", - "range": "far", - "areas": [ - { - "name": "Hail of Boulders", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "pmeromzI4eQOilbp": { "type": "healing", diff --git a/src/packs/adversaries/adversary_Chaos_Skull_jDmHqGvzg5wjgmxE.json b/src/packs/adversaries/adversary_Chaos_Skull_jDmHqGvzg5wjgmxE.json index 876519cf..a95db1b7 100644 --- a/src/packs/adversaries/adversary_Chaos_Skull_jDmHqGvzg5wjgmxE.json +++ b/src/packs/adversaries/adversary_Chaos_Skull_jDmHqGvzg5wjgmxE.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -357,7 +359,7 @@ "name": "Magic Burst", "type": "feature", "system": { - "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d6+4 magic damage.

", + "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d6+4 magic damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "iF0PD1t3yovKMTfy": { @@ -409,8 +411,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -439,16 +440,7 @@ }, "name": "Attack", "img": "icons/magic/lightning/bolt-strike-purple.webp", - "range": "close", - "areas": [ - { - "name": "Magic Burst", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Conscript_99TqczuQipBmaB8i.json b/src/packs/adversaries/adversary_Conscript_99TqczuQipBmaB8i.json index 38e7ceab..5cbc1f82 100644 --- a/src/packs/adversaries/adversary_Conscript_99TqczuQipBmaB8i.json +++ b/src/packs/adversaries/adversary_Conscript_99TqczuQipBmaB8i.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "FCeTuf71gCzRiO5N": { - "type": "attack", - "_id": "FCeTuf71gCzRiO5N", + "cbAvPSIhwBMBTI3D": { + "type": "effect", + "_id": "cbAvPSIhwBMBTI3D", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "6" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" + "recovery": null }, + "effects": [], "target": { "type": "any", "amount": null }, - "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" - }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Construct_uOP5oT9QzXPlnf3p.json b/src/packs/adversaries/adversary_Construct_uOP5oT9QzXPlnf3p.json index 3bd154ef..067248c9 100644 --- a/src/packs/adversaries/adversary_Construct_uOP5oT9QzXPlnf3p.json +++ b/src/packs/adversaries/adversary_Construct_uOP5oT9QzXPlnf3p.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -560,8 +562,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -590,16 +591,7 @@ }, "name": "Attack", "img": "icons/magic/sonic/explosion-shock-wave-teal.webp", - "range": "veryClose", - "areas": [ - { - "name": "Death Quake", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Cult_Adept_0NxCSugvKQ4W8OYZ.json b/src/packs/adversaries/adversary_Cult_Adept_0NxCSugvKQ4W8OYZ.json index 27553d32..cbb48681 100644 --- a/src/packs/adversaries/adversary_Cult_Adept_0NxCSugvKQ4W8OYZ.json +++ b/src/packs/adversaries/adversary_Cult_Adept_0NxCSugvKQ4W8OYZ.json @@ -143,9 +143,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -196,7 +199,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -222,8 +225,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -484,7 +486,7 @@ "name": "Shadow Shackles", "type": "feature", "system": { - "description": "

Spend a Fear and choose a point within Far range. All targets within Close range of that point are Restrained in smoky chains until they break free with a successful Strength or Instinct Roll. A target Restrained by this feature must spend a Hope to make an action roll.

", + "description": "

Spend a Fear and choose a point within Far range. All targets within Close range of that point are Restrained in smoky chains until they break free with a successful Strength or Instinct Roll. A target Restrained by this feature must spend a Hope to make an action roll.

@Template[type:circle|range:c]

", "resource": null, "actions": { "g4RDHrY0AEYXjH52": { @@ -519,16 +521,7 @@ }, "name": "Spend Fear", "img": "icons/magic/air/fog-gas-smoke-dense-pink.webp", - "range": "far", - "areas": [ - { - "name": "Shadow Shackles", - "type": "placed", - "shape": "circle", - "size": "close", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Cult_Initiate_zx99sOGTXicP4SSD.json b/src/packs/adversaries/adversary_Cult_Initiate_zx99sOGTXicP4SSD.json index db26605d..4f04a85a 100644 --- a/src/packs/adversaries/adversary_Cult_Initiate_zx99sOGTXicP4SSD.json +++ b/src/packs/adversaries/adversary_Cult_Initiate_zx99sOGTXicP4SSD.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,33 @@ "description": "

Spend a Fear to choose a target and spotlight all Cult @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "4M2MvVzEgIQEQHBS": { - "type": "attack", - "_id": "4M2MvVzEgIQEQHBS", + "EH1preaTWBD4rOvx": { + "type": "effect", + "_id": "EH1preaTWBD4rOvx", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "5" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": null, - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Deeproot_Defender_9x2xY9zwc3xzbXo5.json b/src/packs/adversaries/adversary_Deeproot_Defender_9x2xY9zwc3xzbXo5.json index 9ff0a161..aed2e08a 100644 --- a/src/packs/adversaries/adversary_Deeproot_Defender_9x2xY9zwc3xzbXo5.json +++ b/src/packs/adversaries/adversary_Deeproot_Defender_9x2xY9zwc3xzbXo5.json @@ -137,9 +137,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -190,7 +193,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -216,8 +219,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -226,7 +228,7 @@ "_id": "0DSCzAFXy0hV4afJ", "img": "icons/magic/earth/barrier-stone-brown-green.webp", "system": { - "description": "

Slam the ground, knocking all targets within Very Close range back to Far range. Each target knocked back this way must mark a Stress.

", + "description": "

Slam the ground, knocking all targets within Very Close range back to Far range. Each target knocked back this way must mark a Stress.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "55hCZsJQhJNcZ0lX": { @@ -270,8 +272,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -280,16 +281,7 @@ "effects": [], "name": "Stress Damage", "img": "icons/magic/earth/barrier-stone-brown-green.webp", - "range": "veryClose", - "areas": [ - { - "name": "Ground Slam", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Demon_of_Despair_kE4dfhqmIQpNd44e.json b/src/packs/adversaries/adversary_Demon_of_Despair_kE4dfhqmIQpNd44e.json index 6468c1aa..e2f58709 100644 --- a/src/packs/adversaries/adversary_Demon_of_Despair_kE4dfhqmIQpNd44e.json +++ b/src/packs/adversaries/adversary_Demon_of_Despair_kE4dfhqmIQpNd44e.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -294,7 +296,7 @@ "name": "Your Struggle is Pointless", "type": "feature", "system": { - "description": "

Spend a Fear to weigh down the spirits of all PCs within Far range. All targets affected replace their Hope Die with a d8 until they roll a success with Hope or their next rest.

", + "description": "

Spend a Fear to weigh down the spirits of all PCs within Far range. All targets affected replace their Hope Die with a d8 until they roll a success with Hope or their next rest.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "n0RYO05pROFU6ov3": { @@ -329,16 +331,7 @@ }, "name": "Spend Fear", "img": "icons/magic/death/skull-flames-white-blue.webp", - "range": "far", - "areas": [ - { - "name": "Your Struggle is Pointless", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -418,7 +411,7 @@ "name": "Your Friends Will Fail You", "type": "feature", "system": { - "description": "

When a PC fails with Fear, you can mark a Stress to cause all other PCs within Close range to lose a Hope.

", + "description": "

When a PC fails with Fear, you can mark a Stress to cause all other PCs within Close range to lose a Hope.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "urrp8SCFgqbmSTvm": { @@ -469,8 +462,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -479,16 +471,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/creatures/unholy/demon-fire-horned-mask.webp", - "range": "", - "areas": [ - { - "name": "Your Friends Will Fail You", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Demon_of_Hubris_2VN3BftageoTTIzu.json b/src/packs/adversaries/adversary_Demon_of_Hubris_2VN3BftageoTTIzu.json index 3a95c233..9f954437 100644 --- a/src/packs/adversaries/adversary_Demon_of_Hubris_2VN3BftageoTTIzu.json +++ b/src/packs/adversaries/adversary_Demon_of_Hubris_2VN3BftageoTTIzu.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range must lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range must lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "v3XbljQeHEyfuSXz": { @@ -276,8 +278,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -286,16 +287,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, @@ -541,7 +533,7 @@ "name": "You Pale in Comparison", "type": "feature", "system": { - "description": "

When a PC fails a roll within Close range of the @Lookup[@name], they must mark a Stress.

", + "description": "

When a PC fails a roll within Close range of the @Lookup[@name], they must mark a Stress.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "kuCPWb9cu3pZdAhh": { @@ -585,8 +577,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -595,16 +586,7 @@ "effects": [], "name": "Mark Stress", "img": "icons/magic/control/fear-fright-shadow-monster-red.webp", - "range": "close", - "areas": [ - { - "name": "You Pale in Comparison", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Demon_of_Jealousy_SxSOkM4bcVOFyjbo.json b/src/packs/adversaries/adversary_Demon_of_Jealousy_SxSOkM4bcVOFyjbo.json index 0c743ac2..c083b183 100644 --- a/src/packs/adversaries/adversary_Demon_of_Jealousy_SxSOkM4bcVOFyjbo.json +++ b/src/packs/adversaries/adversary_Demon_of_Jealousy_SxSOkM4bcVOFyjbo.json @@ -139,9 +139,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -192,7 +195,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -218,8 +221,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -277,7 +279,7 @@ "name": "Rivalry", "type": "feature", "system": { - "description": "

When a creature within Close range takes damage from a different adversary, you can mark a Stress to add a d4 to the damage roll.

", + "description": "

When a creature within Close range takes damage from a different adversary, you can mark a Stress to add a d4 to the damage roll.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "UU3H5aPQejOSoFZw": { @@ -307,16 +309,7 @@ }, "name": "Mark Stress", "img": "icons/magic/perception/eye-ringed-glow-angry-small-teal.webp", - "range": "", - "areas": [ - { - "name": "Rivalry", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, @@ -342,7 +335,7 @@ "name": "What's Yours Is Mine", "type": "feature", "system": { - "description": "

When a PC takes Severe damage within Very Close range of the @Lookup[@name], you can spend a Fear to cause the target to make a Finesse Reaction Roll. On a failure, the @Lookup[@name] seizes one item or consumable of their choice from the target’s inventory.

", + "description": "

When a PC takes Severe damage within Very Close range of the @Lookup[@name], you can spend a Fear to cause the target to make a Finesse Reaction Roll. On a failure, the @Lookup[@name] seizes one item or consumable of their choice from the target’s inventory.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "3cGZ2CofM9HUlELH": { @@ -360,8 +353,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -390,16 +382,7 @@ }, "name": "Roll Save", "img": "icons/magic/perception/hand-eye-black.webp", - "range": "veryClose", - "areas": [ - { - "name": "What's Yours Is Mine", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Demon_of_Wrath_5lphJAgzoqZI3VoG.json b/src/packs/adversaries/adversary_Demon_of_Wrath_5lphJAgzoqZI3VoG.json index 0bc6bf2d..201b17fd 100644 --- a/src/packs/adversaries/adversary_Demon_of_Wrath_5lphJAgzoqZI3VoG.json +++ b/src/packs/adversaries/adversary_Demon_of_Wrath_5lphJAgzoqZI3VoG.json @@ -139,9 +139,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -192,7 +195,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -218,8 +221,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -251,7 +253,7 @@ "name": "Battle Lust", "type": "feature", "system": { - "description": "

Spend a Fear to boil the blood of all PCs within Far range. They use a d20 as their Fear Die until the end of the scene.

", + "description": "

Spend a Fear to boil the blood of all PCs within Far range. They use a d20 as their Fear Die until the end of the scene.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "jKvzbQT0vp66DDOH": { @@ -292,16 +294,7 @@ "amount": null }, "name": "Spend Fear", - "range": "far", - "areas": [ - { - "name": "Battle Lust", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -381,7 +374,7 @@ "name": "Retalliation", "type": "feature", "system": { - "description": "

When the @Lookup[@name] takes damage from an attack within Close range, you can mark a Stress to make a standard attack against the attacker.

", + "description": "

When the @Lookup[@name] takes damage from an attack within Close range, you can mark a Stress to make a standard attack against the attacker.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "hxrdtBm4dYN7KGZm": { @@ -434,8 +427,7 @@ } }, "includeBase": false, - "direct": true, - "groupAttack": "" + "direct": true }, "target": { "type": "any", @@ -464,16 +456,7 @@ }, "name": "Attack", "img": "icons/skills/melee/blood-slash-foam-red.webp", - "range": "veryClose", - "areas": [ - { - "name": "Retalliation", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Demonic_Hound_Pack_NoRZ1PqB8N5wcIw0.json b/src/packs/adversaries/adversary_Demonic_Hound_Pack_NoRZ1PqB8N5wcIw0.json index b534562b..2043d960 100644 --- a/src/packs/adversaries/adversary_Demonic_Hound_Pack_NoRZ1PqB8N5wcIw0.json +++ b/src/packs/adversaries/adversary_Demonic_Hound_Pack_NoRZ1PqB8N5wcIw0.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -250,7 +252,7 @@ "name": "Dreadhowl", "type": "feature", "system": { - "description": "

Mark a Stress to make all targets within Very Close range lose a Hope. If a target is not able to lose a Hope, they must instead mark 2 Stress.

", + "description": "

Mark a Stress to make all targets within Very Close range lose a Hope. If a target is not able to lose a Hope, they must instead mark 2 Stress.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "XyLlX9RWSxciZ7oV": { @@ -294,8 +296,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -304,16 +305,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/creatures/unholy/demons-horned-glowing-pink.webp", - "range": "veryClose", - "areas": [ - { - "name": "Dreadhowl", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Dire_Bat_tBWHW00epmMnkawe.json b/src/packs/adversaries/adversary_Dire_Bat_tBWHW00epmMnkawe.json index c2064395..23d5550e 100644 --- a/src/packs/adversaries/adversary_Dire_Bat_tBWHW00epmMnkawe.json +++ b/src/packs/adversaries/adversary_Dire_Bat_tBWHW00epmMnkawe.json @@ -137,9 +137,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -190,7 +193,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -216,8 +219,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -293,7 +295,7 @@ "name": "Screech", "type": "feature", "system": { - "description": "

Mark a Stress to send a high-pitch screech out toward all targets in front of the @Lookup[@name] within Far range. Those targets must mark 1d4 Stress.

", + "description": "

Mark a Stress to send a high-pitch screech out toward all targets in front of the @Lookup[@name] within Far range. Those targets must mark 1d4 Stress.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "2ILfoiBoMyBCtBsL": { @@ -336,8 +338,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -346,16 +347,7 @@ "effects": [], "name": "Mark Stress", "img": "icons/magic/sonic/projectile-sound-rings-wave.webp", - "range": "far", - "areas": [ - { - "name": "Screech", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Dryad_wR7cFKrHvRzbzhBT.json b/src/packs/adversaries/adversary_Dryad_wR7cFKrHvRzbzhBT.json index 62df584a..c69ee84e 100644 --- a/src/packs/adversaries/adversary_Dryad_wR7cFKrHvRzbzhBT.json +++ b/src/packs/adversaries/adversary_Dryad_wR7cFKrHvRzbzhBT.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Bramble Patch", "type": "feature", "system": { - "description": "

Mark a Stress to target a point within Far range. Create a patch of thorns that covers an area within Close range of that point. All targets within that area take 2d6+2 physical damage when they act. A target must succeed on a Finesse Roll or deal more than 20 damage to the @Lookup[@name] with an attack to leave the area.

", + "description": "

Mark a Stress to target a point within Far range. Create a patch of thorns that covers an area within Close range of that point. All targets within that area take 2d6+2 physical damage when they act. A target must succeed on a Finesse Roll or deal more than 20 damage to the @Lookup[@name] with an attack to leave the area.

@Template[type:circle|range:c]

", "resource": null, "actions": { "iCJdIs57hfh5Cb0u": { @@ -250,8 +252,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -280,16 +281,7 @@ }, "name": "Mark Stress", "img": "icons/magic/nature/root-vines-grow-brown.webp", - "range": "", - "areas": [ - { - "name": "Bramble Patch", - "type": "placed", - "shape": "circle", - "size": "close", - "effects": [] - } - ] + "range": "" }, "cpZ5c9d3opSA4BN9": { "type": "damage", @@ -422,7 +414,7 @@ "name": "We Are All One", "type": "feature", "system": { - "description": "

When an ally dies within Close range, you can spend a Fear to clear 2 HP and 2 Stress as the fallen ally’s life force is returned to the forest.

", + "description": "

When an ally dies within Close range, you can spend a Fear to clear 2 HP and 2 Stress as the fallen ally’s life force is returned to the forest.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "SrhuW3mfOuqg1ys6": { @@ -498,8 +490,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "self", @@ -523,16 +514,7 @@ }, "name": "Spend Fear", "img": "icons/magic/unholy/orb-hands-pink.webp", - "range": "self", - "areas": [ - { - "name": "We Are All One", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "self" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Elemental_Spark_P7h54ZePFPHpYwvB.json b/src/packs/adversaries/adversary_Elemental_Spark_P7h54ZePFPHpYwvB.json index 5b8fa7b2..2c2633ea 100644 --- a/src/packs/adversaries/adversary_Elemental_Spark_P7h54ZePFPHpYwvB.json +++ b/src/packs/adversaries/adversary_Elemental_Spark_P7h54ZePFPHpYwvB.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "S3dYxRclyhYINRi8": { - "type": "attack", - "_id": "S3dYxRclyhYINRi8", + "vXHZVb0Y7Hqu3uso": { + "type": "effect", + "_id": "vXHZVb0Y7Hqu3uso", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "5" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/magic/unholy/orb-hands-pink.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Fallen_Shock_Troop_OsLG2BjaEdTZUJU9.json b/src/packs/adversaries/adversary_Fallen_Shock_Troop_OsLG2BjaEdTZUJU9.json index 484e161a..8c0d7b95 100644 --- a/src/packs/adversaries/adversary_Fallen_Shock_Troop_OsLG2BjaEdTZUJU9.json +++ b/src/packs/adversaries/adversary_Fallen_Shock_Troop_OsLG2BjaEdTZUJU9.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -318,95 +320,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "G0DVft7h55pBnwJA": { - "type": "attack", - "_id": "G0DVft7h55pBnwJA", + "QHNRSEQmqOcaoXq4": { + "type": "effect", + "_id": "QHNRSEQmqOcaoXq4", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "12" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/magic/unholy/orb-hands-pink.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Fallen_Sorcerer_PELRry1vqjBzSAlr.json b/src/packs/adversaries/adversary_Fallen_Sorcerer_PELRry1vqjBzSAlr.json index 975cf6aa..06db1453 100644 --- a/src/packs/adversaries/adversary_Fallen_Sorcerer_PELRry1vqjBzSAlr.json +++ b/src/packs/adversaries/adversary_Fallen_Sorcerer_PELRry1vqjBzSAlr.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Conflagration", "type": "feature", "system": { - "description": "

Spend a Fear to unleash an all-consuming firestorm and make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d10+6 direct magic damage.

", + "description": "

Spend a Fear to unleash an all-consuming firestorm and make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d10+6 direct magic damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "v7zZo52Dnj1e1i2G": { @@ -277,8 +279,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -307,16 +308,7 @@ }, "name": "Attack", "img": "icons/magic/fire/projectile-beams-salvo-red.webp", - "range": "close", - "areas": [ - { - "name": "Conflagration", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -473,14 +465,14 @@ "name": "Shackles of Guilt", "type": "feature", "system": { - "description": "

Countdown (Loop 2d6). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, all targets within Far range become Vulnerable and must mark a Stress as they relive their greatest regrets. A target can break free from their regret with a successful Presence or Strength Roll. When a PC fails to break free, they lose a Hope.

", + "description": "

Countdown (Loop 2d6). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, all targets within Far range become Vulnerable and must mark a Stress as they relive their greatest regrets. A target can break free from their regret with a successful Presence or Strength Roll. When a PC fails to break free, they lose a Hope.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "7b0FkpAnWz9a5EWx": { "type": "damage", "_id": "7b0FkpAnWz9a5EWx", "systemPath": "actions", - "description": "

When it triggers, all targets within Far range become Vulnerable and must mark a Stress as they relive their greatest regrets. A target can break free from their regret with a successful Presence or Strength Roll. When a PC fails to break free, they lose a Hope.

", + "description": "

When the countdown triggers, all targets within Far range become Vulnerable and must mark a Stress as they relive their greatest regrets. A target can break free from their regret with a successful Presence or Strength Roll. When a PC fails to break free, they lose a Hope.

@Template[type:emanation|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -517,8 +509,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -532,16 +523,7 @@ ], "name": "Mark Stress", "img": "icons/magic/unholy/strike-hand-glow-pink.webp", - "range": "", - "areas": [ - { - "name": "Shackles of Guilt", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" }, "11PtfoxbgOXxNlkG": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Fallen_Warlord__Realm_Breaker_hxZ0sgoFJubh5aj6.json b/src/packs/adversaries/adversary_Fallen_Warlord__Realm_Breaker_hxZ0sgoFJubh5aj6.json index 15663752..9fa49107 100644 --- a/src/packs/adversaries/adversary_Fallen_Warlord__Realm_Breaker_hxZ0sgoFJubh5aj6.json +++ b/src/packs/adversaries/adversary_Fallen_Warlord__Realm_Breaker_hxZ0sgoFJubh5aj6.json @@ -173,9 +173,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -226,7 +229,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -252,8 +255,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -390,7 +392,7 @@ "name": "Tormenting Lash", "type": "feature", "system": { - "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. When a target uses armor to reduce damage from this attack, they must mark 2 Armor Slots.

", + "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. When a target uses armor to reduce damage from this attack, they must mark 2 Armor Slots.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "zMVhUekP8pcyQGFR": { @@ -442,8 +444,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -472,16 +473,7 @@ }, "name": "Attack", "img": "icons/skills/melee/blood-slash-foam-red.webp", - "range": "veryClose", - "areas": [ - { - "name": "Tormenting Lash", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -507,14 +499,14 @@ "name": "All-Consuming Rage", "type": "feature", "system": { - "description": "

Countdown (Decreasing 8). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, create a torrent of incarnate rage that rends flesh from bone. All targets within Far range must make a Presence Reaction Roll. Targets who fail take 2d6+10 direct magic damage. Targets who succeed take half damage. For each HP marked from this damage, summon a @UUID[Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9]{Fallen Shock Troop} within Very Close range of the target who marked that HP. If the countdown ever decreases its maximum value to 0, the @Lookup[@name] marks their remaining HP and all targets within Far range must mark all remaining HP and make a death move.

", + "description": "

Countdown (Decreasing 8). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, create a torrent of incarnate rage that rends flesh from bone. All targets within Far range must make a Presence Reaction Roll. Targets who fail take 2d6+10 direct magic damage. Targets who succeed take half damage. For each HP marked from this damage, summon a @UUID[Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9]{Fallen Shock Troop} within Very Close range of the target who marked that HP. If the countdown ever decreases its maximum value to 0, the @Lookup[@name] marks their remaining HP and all targets within Far range must mark all remaining HP and make a death move.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "rgy5wXyXJWh6uWxC": { "type": "attack", "_id": "rgy5wXyXJWh6uWxC", "systemPath": "actions", - "description": "

When it triggers, create a torrent of incarnate rage that rends flesh from bone. All targets within Far range must make a Presence Reaction Roll. Targets who fail take 2d6+10 direct magic damage. Targets who succeed take half damage. For each HP marked from this damage, summon a @UUID[Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9]{Fallen Shock Troop} within Very Close range of the target who marked that HP. If the countdown ever decreases its maximum value to 0, the @Lookup[@name] marks their remaining HP and all targets within Far range must mark all remaining HP and make a death move.

", + "description": "

When it triggers, create a torrent of incarnate rage that rends flesh from bone. All targets within Far range must make a Presence Reaction Roll. Targets who fail take 2d6+10 direct magic damage. Targets who succeed take half damage. For each HP marked from this damage, summon a @UUID[Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9]{Fallen Shock Troop} within Very Close range of the target who marked that HP. If the countdown ever decreases its maximum value to 0, the @Lookup[@name] marks their remaining HP and all targets within Far range must mark all remaining HP and make a death move.

@Template[type:emanation|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -552,8 +544,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -582,16 +573,7 @@ }, "name": "Roll Save", "img": "icons/magic/control/fear-fright-monster-grin-red-orange.webp", - "range": "far", - "areas": [ - { - "name": "All-Consuming Rage", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "8e3BHmOFLvRwPbTW": { "type": "countdown", @@ -654,7 +636,7 @@ "name": "Doombringer", "type": "feature", "system": { - "description": "

When a target marks HP from an attack by the @Lookup[@name], all PCs within Far range of the target must lose a Hope.

", + "description": "

When a target marks HP from an attack by the @Lookup[@name], all PCs within Far range of the target must lose a Hope.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "WEBPJCbXfBeyHFJ4": { @@ -698,8 +680,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -708,16 +689,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "", - "areas": [ - { - "name": "Doombringer", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Fallen_Warlord__Undefeated_Champion_RXkZTwBRi4dJ3JE5.json b/src/packs/adversaries/adversary_Fallen_Warlord__Undefeated_Champion_RXkZTwBRi4dJ3JE5.json index 6cb1c0ce..5ad77ab0 100644 --- a/src/packs/adversaries/adversary_Fallen_Warlord__Undefeated_Champion_RXkZTwBRi4dJ3JE5.json +++ b/src/packs/adversaries/adversary_Fallen_Warlord__Undefeated_Champion_RXkZTwBRi4dJ3JE5.json @@ -174,9 +174,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -227,7 +230,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -253,8 +256,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -391,7 +393,7 @@ "name": "Shattering Strike", "type": "feature", "system": { - "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. PCs the @Lookup[@name] succeeds against lose a number of Hope equal to the HP they marked from this attack.

", + "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. PCs the @Lookup[@name] succeeds against lose a number of Hope equal to the HP they marked from this attack.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "t1GhGnEhNYyJ7p2U": { @@ -436,8 +438,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -466,16 +467,7 @@ }, "name": "Attack", "img": "icons/skills/melee/sword-stuck-glowing-pink.webp", - "range": "veryClose", - "areas": [ - { - "name": "Shattering Strike", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -504,42 +496,34 @@ "description": "

Spend a Fear to summon a number of @UUID[Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9]{Fallen Shock Troops} equal to twice the number of PCs. The Shock Troops appear at Far range.

", "resource": null, "actions": { - "SrU7qbh8LcOgfozT": { - "type": "summon", - "_id": "SrU7qbh8LcOgfozT", + "hGMzqw00JTlYfHYy": { + "type": "effect", + "_id": "hGMzqw00JTlYfHYy", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false + "recovery": null + }, + "effects": [], + "target": { + "type": "self", + "amount": null }, - "summon": [ - { - "actorUUID": "Compendium.daggerheart.adversaries.Actor.OsLG2BjaEdTZUJU9", - "count": "@partySize*2" - } - ], "name": "Spend Fear", - "range": "far" + "img": "icons/magic/death/undead-skeleton-worn-blue.webp", + "range": "" } }, "originItemType": null, @@ -581,25 +565,19 @@ "max": "", "recovery": null }, - "effects": [], + "effects": [ + { + "_id": "eZp1PSCHZzdb47oM", + "onSave": false + } + ], "target": { "type": "any", "amount": null }, "name": "Circle", "img": "icons/magic/unholy/barrier-fire-pink.webp", - "range": "", - "areas": [ - { - "name": "Circle of Defilement", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [ - "KlTKlZXjdXQ9v6qB" - ] - } - ] + "range": "" }, "4x13WyksHU0u0j20": { "type": "countdown", @@ -647,58 +625,42 @@ "img": "icons/magic/unholy/barrier-fire-pink.webp", "effects": [ { - "name": "Circle Of Defilement", - "disabled": false, + "name": "Circle of Defilement", "img": "icons/magic/unholy/barrier-fire-pink.webp", - "description": "

You are Vulnerable until you leave the circle.

", + "origin": "Compendium.daggerheart.adversaries.Actor.RXkZTwBRi4dJ3JE5.Item.55P7ZijSbQeVHCw4", "transfer": false, - "statuses": [ - "vulnerable" - ], + "_id": "eZp1PSCHZzdb47oM", + "type": "base", "system": { "rangeDependence": { "enabled": false, "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [], - "duration": { - "description": "", - "type": "" - }, - "stacking": null, - "targetDispositions": [ - 1, - 0 - ] - }, - "_id": "KlTKlZXjdXQ9v6qB", - "type": "base", - "start": { - "time": 0, - "combat": null, - "combatant": null, - "initiative": null, - "round": null, - "turn": null + } }, + "changes": [], + "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, - "origin": null, + "description": "

Vulnerable until you leave the circle. The circle can be removed by dealing Severe damage to the Undefeated Champion.

", "tint": "#ffffff", - "showIcon": 1, - "folder": null, + "statuses": [ + "vulnerable" + ], "sort": 0, "flags": {}, "_stats": { "compendiumSource": null }, - "_key": "!actors.items.effects!RXkZTwBRi4dJ3JE5.55P7ZijSbQeVHCw4.KlTKlZXjdXQ9v6qB" + "_key": "!actors.items.effects!RXkZTwBRi4dJ3JE5.55P7ZijSbQeVHCw4.eZp1PSCHZzdb47oM" } ], "folder": null, @@ -813,7 +775,7 @@ "name": "Doombringer", "type": "feature", "system": { - "description": "

When a target marks HP from an attack by the @Lookup[@name], all PCs within Far range of the target lose a Hope.

", + "description": "

When a target marks HP from an attack by the @Lookup[@name], all PCs within Far range of the target lose a Hope.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "liwKSCTmQqZasAf6": { @@ -857,8 +819,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -867,16 +828,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "far", - "areas": [ - { - "name": "Doombringer", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Giant_Brawler_YnObCleGjPT7yqEc.json b/src/packs/adversaries/adversary_Giant_Brawler_YnObCleGjPT7yqEc.json index acb9c219..8948c8b6 100644 --- a/src/packs/adversaries/adversary_Giant_Brawler_YnObCleGjPT7yqEc.json +++ b/src/packs/adversaries/adversary_Giant_Brawler_YnObCleGjPT7yqEc.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Battering Ram", "type": "feature", "system": { - "description": "

Mark a Stress to have the @Lookup[@name] charge at an inanimate object within Close range they could feasibly smash (such as a wall, cart, or market stand) and destroy it. All targets within Very Close range of the object must succeed on an Agility Reaction Roll or take 2d4+3 physical damage from the shrapnel.

", + "description": "

Mark a Stress to have the @Lookup[@name] charge at an inanimate object within Close range they could feasibly smash (such as a wall, cart, or market stand) and destroy it. All targets within Very Close range of the object must succeed on an Agility Reaction Roll or take 2d4+3 physical damage from the shrapnel.

@Template[type:circle|range:vc]

", "resource": null, "actions": { "zns57MqnZ6M1d4r0": { @@ -306,16 +308,7 @@ }, "name": "Roll Save", "img": "icons/skills/melee/shield-damaged-broken-orange.webp", - "range": "close", - "areas": [ - { - "name": "Battering Ram", - "type": "placed", - "shape": "circle", - "size": "veryClose", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Giant_Rat_4PfLnaCrOcMdb4dK.json b/src/packs/adversaries/adversary_Giant_Rat_4PfLnaCrOcMdb4dK.json index 746806d9..822ee035 100644 --- a/src/packs/adversaries/adversary_Giant_Rat_4PfLnaCrOcMdb4dK.json +++ b/src/packs/adversaries/adversary_Giant_Rat_4PfLnaCrOcMdb4dK.json @@ -131,9 +131,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -184,7 +187,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -210,8 +213,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -270,38 +272,8 @@ "recovery": null }, "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "1" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "groupAttack": "close" + "parts": {}, + "includeBase": false }, "target": { "type": "any", @@ -328,7 +300,7 @@ "difficulty": null, "damageMod": "none" }, - "name": "Spend Fear", + "name": "Attack", "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } diff --git a/src/packs/adversaries/adversary_Giant_Recruit_5s8wSvpyC5rxY5aD.json b/src/packs/adversaries/adversary_Giant_Recruit_5s8wSvpyC5rxY5aD.json index 6611496f..376ebace 100644 --- a/src/packs/adversaries/adversary_Giant_Recruit_5s8wSvpyC5rxY5aD.json +++ b/src/packs/adversaries/adversary_Giant_Recruit_5s8wSvpyC5rxY5aD.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,35 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "wez1xgy9vScux9wi": { - "type": "attack", - "_id": "wez1xgy9vScux9wi", + "DjbPQowW1OdBD9Zn": { + "type": "effect", + "_id": "DjbPQowW1OdBD9Zn", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { - "consumeOnSuccess": false, "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null + "keyIsID": false, + "step": null, + "consumeOnSuccess": false } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "5" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Glass_Snake_8KWVLWXFhlY2kYx0.json b/src/packs/adversaries/adversary_Glass_Snake_8KWVLWXFhlY2kYx0.json index f290875d..5876f55c 100644 --- a/src/packs/adversaries/adversary_Glass_Snake_8KWVLWXFhlY2kYx0.json +++ b/src/packs/adversaries/adversary_Glass_Snake_8KWVLWXFhlY2kYx0.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -350,8 +352,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -380,16 +381,7 @@ }, "name": "Attack", "img": "icons/skills/melee/blood-slash-foam-red.webp", - "range": "veryClose", - "areas": [ - { - "name": "Spinning Serpent", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -416,7 +408,7 @@ "_id": "LR5XHauNtWcl18CY", "img": "icons/magic/acid/projectile-needles-salvo-green.webp", "system": { - "description": "

Spend a Fear to introduce a d6 Spitter Die. When the @Lookup[@name] is in the spotlight, roll this die. On a result of 5 or higher, all targets in front of the @Lookup[@name] within Far range must succeed on an Agility Reaction Roll or take 1d4 physical damage. The @Lookup[@name] can take the spotlight a second time this GM turn.

", + "description": "

Spend a Fear to introduce a d6 Spitter Die. When the @Lookup[@name] is in the spotlight, roll this die. On a result of 5 or higher, all targets in front of the @Lookup[@name] within Far range must succeed on an Agility Reaction Roll or take 1d4 physical damage. The @Lookup[@name] can take the spotlight a second time this GM turn.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "yx5fjMLLwSnvSbqs": { @@ -457,7 +449,7 @@ "type": "attack", "_id": "Ds6KlQKZCOhh5OMT", "systemPath": "actions", - "description": "

All targets in front of the @Lookup[@name] within Far range must succeed on an Agility Reaction Roll or take 1d4 physical damage.

", + "description": "

All targets in front of the @Lookup[@name] within Far range must succeed on an Agility Reaction Roll or take 1d4 physical damage.

@Template[type:inFront|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -495,8 +487,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -525,16 +516,7 @@ }, "name": "Spit Attack", "img": "icons/magic/acid/projectile-needles-salvo-green.webp", - "range": "far", - "areas": [ - { - "name": "Spitter", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "xccwknU2xHUwQSdn": { "type": "attack", @@ -602,15 +584,18 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [] + } }, + "changes": [], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, "description": "

You have a d6 Spitter Die. When the Snake is in the spotlight, roll this die. On a result of 5 or higher, all targets in front of the Snake within Far range must succeed on an Agility Reaction Roll or take 1d4 physical damage. The Snake can take the spotlight a second time this GM turn.

", "tint": "#ffffff", @@ -620,9 +605,6 @@ "_stats": { "compendiumSource": null }, - "start": null, - "showIcon": 1, - "folder": null, "_key": "!actors.items.effects!8KWVLWXFhlY2kYx0.LR5XHauNtWcl18CY.Mchd23xNQ4nSWw9X" } ], diff --git a/src/packs/adversaries/adversary_Greater_Earth_Elemental_dsfB3YhoL5SudvS2.json b/src/packs/adversaries/adversary_Greater_Earth_Elemental_dsfB3YhoL5SudvS2.json index e59d2683..077373b2 100644 --- a/src/packs/adversaries/adversary_Greater_Earth_Elemental_dsfB3YhoL5SudvS2.json +++ b/src/packs/adversaries/adversary_Greater_Earth_Elemental_dsfB3YhoL5SudvS2.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -396,7 +398,7 @@ "name": "Rockslide", "type": "feature", "system": { - "description": "

Mark a Stress to create a rockslide that buries the land in front of @Lookup[@name] within Close range with rockfall. All targets in this area must make an Agility Reaction Roll (19). Targets who fail take 2d12+5 physical damage and become Vulnerable until their next roll with Hope. Targets who succeed take half damage.

", + "description": "

Mark a Stress to create a rockslide that buries the land in front of @Lookup[@name] within Close range with rockfall. All targets in this area must make an Agility Reaction Roll (19). Targets who fail take 2d12+5 physical damage and become Vulnerable until their next roll with Hope. Targets who succeed take half damage.

@Template[type:inFront|range:c]

", "resource": null, "actions": { "eLGIC3kVjLo8FEvy": { @@ -448,8 +450,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -483,16 +484,7 @@ }, "name": "Roll Save", "img": "icons/magic/earth/barrier-stone-brown-green.webp", - "range": "", - "areas": [ - { - "name": "Rockslide", - "type": "placed", - "shape": "inFront", - "size": "close", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Greater_Water_Elemental_xIICT6tEdnA7dKDV.json b/src/packs/adversaries/adversary_Greater_Water_Elemental_xIICT6tEdnA7dKDV.json index db73a536..b44bb9cc 100644 --- a/src/packs/adversaries/adversary_Greater_Water_Elemental_xIICT6tEdnA7dKDV.json +++ b/src/packs/adversaries/adversary_Greater_Water_Elemental_xIICT6tEdnA7dKDV.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -375,7 +377,7 @@ "name": "Drowning Embrace", "type": "feature", "system": { - "description": "

Spend a Fear to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against become Restrained and Vulnerable as they begin drowning. A target can break free, ending both conditions, with a successful Strength or Instinct Roll.

", + "description": "

Spend a Fear to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against become Restrained and Vulnerable as they begin drowning. A target can break free, ending both conditions, with a successful Strength or Instinct Roll.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "ooYbiLrYjoWXIfe9": { @@ -400,8 +402,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -435,16 +436,7 @@ }, "name": "Attack", "img": "icons/magic/water/vortex-water-whirlpool-blue.webp", - "range": "veryClose", - "areas": [ - { - "name": "Drowning Embrace", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Hallowed_Soldier_VENwg7xEFcYObjmT.json b/src/packs/adversaries/adversary_Hallowed_Soldier_VENwg7xEFcYObjmT.json index 3e1ab854..6a131c86 100644 --- a/src/packs/adversaries/adversary_Hallowed_Soldier_VENwg7xEFcYObjmT.json +++ b/src/packs/adversaries/adversary_Hallowed_Soldier_VENwg7xEFcYObjmT.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -295,95 +297,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "irZGPKPpGLA6sP2y": { - "type": "attack", - "_id": "irZGPKPpGLA6sP2y", + "eo7J0v1B5zPHul1M": { + "type": "effect", + "_id": "eo7J0v1B5zPHul1M", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "10" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Head_Guard_mK3A5FTx6k8iPU3F.json b/src/packs/adversaries/adversary_Head_Guard_mK3A5FTx6k8iPU3F.json index 9a6cc509..f0c050a9 100644 --- a/src/packs/adversaries/adversary_Head_Guard_mK3A5FTx6k8iPU3F.json +++ b/src/packs/adversaries/adversary_Head_Guard_mK3A5FTx6k8iPU3F.json @@ -143,9 +143,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -196,7 +199,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -222,8 +225,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -232,7 +234,7 @@ "_id": "SsgN2qSYpQLR43Cz", "img": "icons/skills/movement/arrows-up-trio-red.webp", "system": { - "description": "

Spend 2 Fear to spotlight the @Lookup[@name] and up to 2d4 allies within Far range.

", + "description": "

Spend 2 Fear to spotlight the @Lookup[@name] and up to 2d4 allies within Far range.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "lI0lnRb3xrUjqIYX": { @@ -257,8 +259,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -287,16 +288,7 @@ }, "name": "Rally", "img": "icons/skills/movement/arrows-up-trio-red.webp", - "range": "", - "areas": [ - { - "name": "Rally Guards", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, @@ -323,7 +315,7 @@ "_id": "YeJ7eJVCKsRxG8mk", "img": "icons/skills/ranged/target-bullseye-arrow-blue.webp", "system": { - "description": "

Countdown (5). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. It ticks down when a PC makes an attack roll. When it triggers, all Archer Guards within Far range make a standard attack with advantage against the nearest target within their range. If any attacks succeed on the same target, combine their damage.

", + "description": "

Countdown (5). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. It ticks down when a PC makes an attack roll. When it triggers, all Archer Guards within Far range make a standard attack with advantage against the nearest target within their range. If any attacks succeed on the same target, combine their damage.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "xyhaCmPGiVMsTViH": { @@ -361,16 +353,7 @@ ], "name": "Start Countdown", "img": "icons/skills/ranged/target-bullseye-arrow-blue.webp", - "range": "", - "areas": [ - { - "name": "On My Signal", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Head_Vampire_i2UNbRvgyoSs07M6.json b/src/packs/adversaries/adversary_Head_Vampire_i2UNbRvgyoSs07M6.json index b17c85bc..322e4658 100644 --- a/src/packs/adversaries/adversary_Head_Vampire_i2UNbRvgyoSs07M6.json +++ b/src/packs/adversaries/adversary_Head_Vampire_i2UNbRvgyoSs07M6.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "Rf2ZL3EjCzudonRb": { @@ -269,8 +271,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -279,16 +280,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "far", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -533,7 +525,7 @@ "name": "Lifesuck", "type": "feature", "system": { - "description": "

When the @Lookup[@name] is spotlighted, roll a d8. On a result of 6 or higher, all targets within Very Close range must mark a HP.

", + "description": "

When the @Lookup[@name] is spotlighted, roll a d8. On a result of 6 or higher, all targets within Very Close range must mark a HP.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "DA8qT2omBcG4oryX": { @@ -577,8 +569,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -607,16 +598,7 @@ }, "name": "Roll d8", "img": "icons/magic/unholy/strike-beam-blood-small-red-purple.webp", - "range": "veryClose", - "areas": [ - { - "name": "Lifesuck", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Hydra_MI126iMOOobQ1Obn.json b/src/packs/adversaries/adversary_Hydra_MI126iMOOobQ1Obn.json index 9c53487a..7e71af98 100644 --- a/src/packs/adversaries/adversary_Hydra_MI126iMOOobQ1Obn.json +++ b/src/packs/adversaries/adversary_Hydra_MI126iMOOobQ1Obn.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -375,7 +377,7 @@ "name": "Terrifying Chorus", "type": "feature", "system": { - "description": "

All PCs within Far range lose 2 Hope.

", + "description": "

All PCs within Far range lose 2 Hope.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "nJxpFR4Ul0e2RrL4": { @@ -419,8 +421,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -429,16 +430,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-white.webp", - "range": "far", - "areas": [ - { - "name": "Terrifying Chorus", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Jagged_Knife_Lackey_C0OMQqV7pN6t7ouR.json b/src/packs/adversaries/adversary_Jagged_Knife_Lackey_C0OMQqV7pN6t7ouR.json index 076318c6..cfcdea8b 100644 --- a/src/packs/adversaries/adversary_Jagged_Knife_Lackey_C0OMQqV7pN6t7ouR.json +++ b/src/packs/adversaries/adversary_Jagged_Knife_Lackey_C0OMQqV7pN6t7ouR.json @@ -131,9 +131,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -184,7 +187,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -210,8 +213,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -249,95 +251,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name] within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "ferZO3BuiP9zU46m": { - "type": "attack", - "_id": "ferZO3BuiP9zU46m", + "aoQDb2m32NDxE6ZP": { + "type": "effect", + "_id": "aoQDb2m32NDxE6ZP", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { - "consumeOnSuccess": false, "scalable": false, "key": "fear", "value": 1, - "itemId": null, "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "2" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" + "recovery": null }, + "effects": [], "target": { "type": "any", "amount": null }, - "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" - }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Jagged_Knife_Lieutenant_aTljstqteGoLpCBq.json b/src/packs/adversaries/adversary_Jagged_Knife_Lieutenant_aTljstqteGoLpCBq.json index 771c6692..8820f30c 100644 --- a/src/packs/adversaries/adversary_Jagged_Knife_Lieutenant_aTljstqteGoLpCBq.json +++ b/src/packs/adversaries/adversary_Jagged_Knife_Lieutenant_aTljstqteGoLpCBq.json @@ -137,9 +137,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -190,7 +193,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -216,8 +219,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -256,16 +258,7 @@ }, "name": "Mark Stress", "img": "icons/skills/movement/arrows-up-trio-red.webp", - "range": "close", - "areas": [ - { - "name": "Tactician", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Juvenile_Flickerfly_MYXmTx2FHcIjdfYZ.json b/src/packs/adversaries/adversary_Juvenile_Flickerfly_MYXmTx2FHcIjdfYZ.json index 24683a37..562b42b8 100644 --- a/src/packs/adversaries/adversary_Juvenile_Flickerfly_MYXmTx2FHcIjdfYZ.json +++ b/src/packs/adversaries/adversary_Juvenile_Flickerfly_MYXmTx2FHcIjdfYZ.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -398,7 +400,7 @@ "name": "Mind Dance", "type": "feature", "system": { - "description": "

Mark a Stress to create a magically dazzling display that grapples the minds of nearby foes. All targets within Close range must make an Instinct Reaction Roll. For each target who failed, you gain a Fear and the @Lookup[@name] learns one of the target’s fears.

", + "description": "

Mark a Stress to create a magically dazzling display that grapples the minds of nearby foes. All targets within Close range must make an Instinct Reaction Roll. For each target who failed, you gain a Fear and the @Lookup[@name] learns one of the target’s fears.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "0wL3ieMrXEb2gcxe": { @@ -416,8 +418,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -446,16 +447,7 @@ }, "name": "Roll Save", "img": "icons/magic/light/explosion-glow-spiral-yellow.webp", - "range": "close", - "areas": [ - { - "name": "Mind Dance", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -481,7 +473,7 @@ "name": "Hallucinatory Breath", "type": "feature", "system": { - "description": "

Countdown (Loop 1d6). When the @Lookup[@name] takes damage for the first time, activate the countdown. When it triggers, the @Lookup[@name] breathes hallucinatory gas on all targets in front of them up to Far range. Targets must succeed on an Instinct Reaction Roll or be tormented by fearful hallucinations. Targets whose fears are known to the @Lookup[@name] have disadvantage on this roll. Targets who fail must mark a Stress and lose a Hope.

", + "description": "

Countdown (Loop 1d6). When the @Lookup[@name] takes damage for the first time, activate the countdown. When it triggers, the @Lookup[@name] breathes hallucinatory gas on all targets in front of them up to Far range. Targets must succeed on an Instinct Reaction Roll or be tormented by fearful hallucinations. Targets whose fears are known to the @Lookup[@name] have disadvantage on this roll. Targets who fail must mark a Stress and lose a Hope.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "USEkCakSzYcZbBwY": { @@ -550,8 +542,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -580,16 +571,7 @@ }, "name": "Roll Save", "img": "icons/magic/air/fog-gas-smoke-purple.webp", - "range": "far", - "areas": [ - { - "name": "Hallucinatory Breath", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "n8ZuLjwTf2FJ7V6n": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Kraken_4nqv3ZwJGjnmic8j.json b/src/packs/adversaries/adversary_Kraken_4nqv3ZwJGjnmic8j.json index 4bcdc15d..4494e0e8 100644 --- a/src/packs/adversaries/adversary_Kraken_4nqv3ZwJGjnmic8j.json +++ b/src/packs/adversaries/adversary_Kraken_4nqv3ZwJGjnmic8j.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -437,7 +439,7 @@ "name": "Boiling Blast", "type": "feature", "system": { - "description": "

Spend a Fear to spew a line of boiling water at any number of targets in a line up to Far range. All targets must succeed on an Agility Reaction Roll or take 4d6+9 physical damage. If a target marks an Armor Slot to reduce the damage, they must also mark a Stress.

", + "description": "

Spend a Fear to spew a line of boiling water at any number of targets in a line up to Far range. All targets must succeed on an Agility Reaction Roll or take 4d6+9 physical damage. If a target marks an Armor Slot to reduce the damage, they must also mark a Stress.

@Template[type:ray|range:f]

", "resource": null, "actions": { "pHZUiZRSj4FuG0uK": { @@ -482,8 +484,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -512,16 +513,7 @@ }, "name": "Attack", "img": "icons/magic/water/projectile-icecicle-glowing.webp", - "range": "", - "areas": [ - { - "name": "Boiling Blast", - "type": "placed", - "shape": "line", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Masked_Thief_niBpVU7yeo5ccskE.json b/src/packs/adversaries/adversary_Masked_Thief_niBpVU7yeo5ccskE.json index 77d48be3..25740e52 100644 --- a/src/packs/adversaries/adversary_Masked_Thief_niBpVU7yeo5ccskE.json +++ b/src/packs/adversaries/adversary_Masked_Thief_niBpVU7yeo5ccskE.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -323,7 +325,7 @@ "name": "Escape Plan", "type": "feature", "system": { - "description": "

Mark a Stress to reveal a snare trap set anywhere on the battlefield by the @Lookup[@name]. All targets within Very Close range of the trap must succeed on an Agility Reaction Roll (13) or be pulled off their feet and suspended upside down. A target is Restrained and Vulnerable until they break free, ending both conditions, with a successful Finesse or Strength Roll (13).

", + "description": "

Mark a Stress to reveal a snare trap set anywhere on the battlefield by the @Lookup[@name]. All targets within Very Close range of the trap must succeed on an Agility Reaction Roll (13) or be pulled off their feet and suspended upside down. A target is Restrained and Vulnerable until they break free, ending both conditions, with a successful Finesse or Strength Roll (13).

@Template[type:rect|range:c]

", "resource": null, "actions": { "sq0q1l2Go4GduR3B": { @@ -375,16 +377,7 @@ }, "name": "Roll Save", "img": "icons/environment/traps/trap-jaw-tan.webp", - "range": "", - "areas": [ - { - "name": "Escape Plan", - "type": "placed", - "shape": "circle", - "size": "veryClose", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Minor_Chaos_Elemental_sRn4bqerfARvhgSV.json b/src/packs/adversaries/adversary_Minor_Chaos_Elemental_sRn4bqerfARvhgSV.json index 9ddfb4f3..21564421 100644 --- a/src/packs/adversaries/adversary_Minor_Chaos_Elemental_sRn4bqerfARvhgSV.json +++ b/src/packs/adversaries/adversary_Minor_Chaos_Elemental_sRn4bqerfARvhgSV.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -291,7 +293,7 @@ "_id": "oAxhAawgcK7DAdpa", "img": "icons/magic/sonic/explosion-shock-sound-wave.webp", "system": { - "description": "

Mark a HP to force all targets within Close range to mark a Stress and become Vulnerable until their next rest or they clear a HP.

", + "description": "

Mark a HP to force all targets within Close range to mark a Stress and become Vulnerable until their next rest or they clear a HP.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "g4CVwjDeJgTJ2oCw": { @@ -342,8 +344,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -357,16 +358,7 @@ ], "name": "Mark HP", "img": "icons/magic/sonic/explosion-shock-sound-wave.webp", - "range": "close", - "areas": [ - { - "name": "Sickening Flux", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -442,7 +434,7 @@ "_id": "updQuIK8sybf4YmW", "img": "icons/magic/light/explosion-glow-spiral-teal.webp", "system": { - "description": "

Spend a Fear to transform the area within Very Close range into a different biome. All targets within this area take 2d6+3 direct magic damage.

", + "description": "

Spend a Fear to transform the area within Very Close range into a different biome. All targets within this area take 2d6+3 direct magic damage.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "QzuQIAtSrgz9Zd5V": { @@ -494,8 +486,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -504,16 +495,7 @@ "effects": [], "name": "Spend Fear", "img": "icons/magic/light/explosion-glow-spiral-teal.webp", - "range": "veryClose", - "areas": [ - { - "name": "Remake Reality", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Minor_Demon_3tqCjDwJAQ7JKqMb.json b/src/packs/adversaries/adversary_Minor_Demon_3tqCjDwJAQ7JKqMb.json index 626b1597..8f5f51f3 100644 --- a/src/packs/adversaries/adversary_Minor_Demon_3tqCjDwJAQ7JKqMb.json +++ b/src/packs/adversaries/adversary_Minor_Demon_3tqCjDwJAQ7JKqMb.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -280,7 +282,7 @@ "_id": "kD9kO92V7t3IqZu8", "img": "icons/magic/unholy/strike-hand-glow-pink.webp", "system": { - "description": "

When a PC rolls a failure with Fear while within Close range of the @Lookup[@name], they lose a Hope.

", + "description": "

When a PC rolls a failure with Fear while within Close range of the @Lookup[@name], they lose a Hope.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "XQ7QebA0iGvMti4A": { @@ -324,8 +326,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -334,16 +335,7 @@ "effects": [], "name": "Hope Damage", "img": "icons/magic/unholy/strike-hand-glow-pink.webp", - "range": "", - "areas": [ - { - "name": "All Must fall", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, @@ -369,7 +361,7 @@ "_id": "lA7vcvS7oGT9NTSy", "img": "icons/magic/fire/projectile-beams-salvo-red.webp", "system": { - "description": "

Spend a Fear to rain down hellfire within Far range. All targets within the area must make an Agility Reaction Roll. Targets who fail take 1d20+3 magic damage. Targets who succeed take half damage.

", + "description": "

Spend a Fear to rain down hellfire within Far range. All targets within the area must make an Agility Reaction Roll. Targets who fail take 1d20+3 magic damage. Targets who succeed take half damage.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "nOzLQ0NJzeB3vKiV": { @@ -421,8 +413,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -451,16 +442,7 @@ }, "name": "Spend Fear", "img": "icons/magic/fire/projectile-beams-salvo-red.webp", - "range": "far", - "areas": [ - { - "name": "Hellfire", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Minor_Fire_Elemental_DscWkNVoHak6P4hh.json b/src/packs/adversaries/adversary_Minor_Fire_Elemental_DscWkNVoHak6P4hh.json index 859c207c..0cc9703c 100644 --- a/src/packs/adversaries/adversary_Minor_Fire_Elemental_DscWkNVoHak6P4hh.json +++ b/src/packs/adversaries/adversary_Minor_Fire_Elemental_DscWkNVoHak6P4hh.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -271,7 +273,7 @@ "_id": "7AXE86WNd68OySkD", "img": "icons/magic/fire/explosion-flame-lightning-strike.webp", "system": { - "description": "

Mark a Stress to choose a point within Far range. The ground within Very Close range of that point immediately bursts into flames. All creatures within this area must make an Agility Reaction Roll. Targets who fail take 2d8 magic damage from the flames. Targets who succeed take half damage.

", + "description": "

Mark a Stress to choose a point within Far range. The ground within Very Close range of that point immediately bursts into flames. All creatures within this area must make an Agility Reaction Roll. Targets who fail take 2d8 magic damage from the flames. Targets who succeed take half damage.

@Template[type:circle|range:vc]

", "resource": null, "actions": { "x1VCkfcSYiPyg8fk": { @@ -352,16 +354,7 @@ }, "name": "Attack", "img": "icons/magic/fire/explosion-flame-lightning-strike.webp", - "range": "far", - "areas": [ - { - "name": "Scorched Earth", - "type": "placed", - "shape": "circle", - "size": "veryClose", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -388,14 +381,14 @@ "_id": "ESnu3I89BmUdBZEk", "img": "icons/magic/fire/explosion-fireball-large-red-orange.webp", "system": { - "description": "

Spend a Fear to erupt in a fi ery explosion. Make an attack against all targets within Close range. Targets the Elemental succeeds against take 1d8 magic damage and are knocked back to Far range.

", + "description": "

Spend a Fear to erupt in a fi ery explosion. Make an attack against all targets within Close range. Targets the Elemental succeeds against take 1d8 magic damage and are knocked back to Far range.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "JQgqyW8H7fugR7F0": { "type": "attack", "_id": "JQgqyW8H7fugR7F0", "systemPath": "actions", - "description": "", + "description": "

Spend a Fear to erupt in a fi ery explosion. Make an attack against all targets within Close range. Targets the Elemental succeeds against take 1d8 magic damage and are knocked back to Far range.

@Template[type:emanation|range:c]

", "chatDisplay": true, "actionType": "action", "cost": [ @@ -440,8 +433,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -470,16 +462,7 @@ }, "name": "Attack", "img": "icons/magic/fire/explosion-fireball-large-red-orange.webp", - "range": "close", - "areas": [ - { - "name": "Explosion", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -509,11 +492,9 @@ "description": "

Three times per scene, when the @Lookup[@name] moves onto objects that are highly flammable, consume them to clear a HP or a Stress.

", "resource": { "type": "simple", - "value": 3, + "value": 0, "max": "3", - "icon": "fa-solid fa-fire", - "progression": "decreasing", - "recovery": "scene" + "icon": "fa-solid fa-fire" }, "actions": { "CTWSVVisdgJgF7pd": { @@ -523,16 +504,7 @@ "description": "", "chatDisplay": true, "actionType": "action", - "cost": [ - { - "scalable": false, - "key": "resource", - "value": 1, - "itemId": "3u6wvKPJAS2v5nWV", - "step": null, - "consumeOnSuccess": false - } - ], + "cost": [], "uses": { "value": null, "max": "", @@ -566,8 +538,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "self", @@ -600,16 +571,7 @@ "description": "", "chatDisplay": true, "actionType": "action", - "cost": [ - { - "scalable": false, - "key": "resource", - "value": 1, - "itemId": "3u6wvKPJAS2v5nWV", - "step": null, - "consumeOnSuccess": false - } - ], + "cost": [], "uses": { "value": null, "max": "", @@ -643,8 +605,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "self", diff --git a/src/packs/adversaries/adversary_Minor_Treant_G62k4oSkhkoXEs2D.json b/src/packs/adversaries/adversary_Minor_Treant_G62k4oSkhkoXEs2D.json index 163556e9..b2217e66 100644 --- a/src/packs/adversaries/adversary_Minor_Treant_G62k4oSkhkoXEs2D.json +++ b/src/packs/adversaries/adversary_Minor_Treant_G62k4oSkhkoXEs2D.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -243,95 +245,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "xFlhxnQWmVvDqQ55": { - "type": "attack", - "_id": "xFlhxnQWmVvDqQ55", + "xTMNAHcoErKuR6TZ": { + "type": "effect", + "_id": "xTMNAHcoErKuR6TZ", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "4" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Mortal_Hunter_mVV7a7KQAORoPMgZ.json b/src/packs/adversaries/adversary_Mortal_Hunter_mVV7a7KQAORoPMgZ.json index 33677263..2eaa9619 100644 --- a/src/packs/adversaries/adversary_Mortal_Hunter_mVV7a7KQAORoPMgZ.json +++ b/src/packs/adversaries/adversary_Mortal_Hunter_mVV7a7KQAORoPMgZ.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "9T1g3FH38cnCRG8k": { @@ -269,8 +271,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -279,16 +280,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "far", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -582,7 +574,7 @@ "name": "Rampage", "type": "feature", "system": { - "description": "

Countdown (Loop 1d6). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, move the @Lookup[@name] in a straight line to a point within Far range and make an attack against all targets in their path. Targets the @Lookup[@name] succeeds against take 2d8+2 physical damage.

", + "description": "

Countdown (Loop 1d6). When the @Lookup[@name] is in the spotlight for the first time, activate the countdown. When it triggers, move the @Lookup[@name] in a straight line to a point within Far range and make an attack against all targets in their path. Targets the @Lookup[@name] succeeds against take 2d8+2 physical damage.

@Template[type:ray|range:f]

", "resource": null, "actions": { "VjiFxuzfAaq5N1jy": { @@ -627,8 +619,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -657,16 +648,7 @@ }, "name": "Attack", "img": "icons/magic/movement/trail-streak-zigzag-yellow.webp", - "range": "far", - "areas": [ - { - "name": "Rampage", - "type": "placed", - "shape": "line", - "size": "far", - "effects": [] - } - ] + "range": "far" }, "BhA3vxCuMs4UbbQU": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Oracle_of_Doom_befIqd5IYKg6eUz2.json b/src/packs/adversaries/adversary_Oracle_of_Doom_befIqd5IYKg6eUz2.json index a9b865ae..343cfdc1 100644 --- a/src/packs/adversaries/adversary_Oracle_of_Doom_befIqd5IYKg6eUz2.json +++ b/src/packs/adversaries/adversary_Oracle_of_Doom_befIqd5IYKg6eUz2.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,15 +220,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "VjdSO1lAdTIAlofM": { @@ -269,8 +271,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -279,16 +280,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "far", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Outer_Realms_Abomination_A0SeeDzwjvqOsyof.json b/src/packs/adversaries/adversary_Outer_Realms_Abomination_A0SeeDzwjvqOsyof.json index 3e5bacf3..0f73354e 100644 --- a/src/packs/adversaries/adversary_Outer_Realms_Abomination_A0SeeDzwjvqOsyof.json +++ b/src/packs/adversaries/adversary_Outer_Realms_Abomination_A0SeeDzwjvqOsyof.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -365,7 +367,7 @@ "name": "Reality Quake", "type": "feature", "system": { - "description": "

Spend a Fear to rattle the edges of reality within Far range of the @Lookup[@name]. All targets within that area must succeed on a Knowledge Reaction Roll or become Unstuck from reality until the end of the scene. When an Unstuck target spends Hope or marks Armor Slots, HP, or Stress, they must double the amount spent or marked.

", + "description": "

Spend a Fear to rattle the edges of reality within Far range of the @Lookup[@name]. All targets within that area must succeed on a Knowledge Reaction Roll or become Unstuck from reality until the end of the scene. When an Unstuck target spends Hope or marks Armor Slots, HP, or Stress, they must double the amount spent or marked.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "7apNSLz8m7sxyLhU": { @@ -383,8 +385,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -418,16 +419,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/explosion-shock-sound-wave.webp", - "range": "", - "areas": [ - { - "name": "Reality Quake", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Outer_Realms_Corrupter_ms6nuOl3NFkhPj1k.json b/src/packs/adversaries/adversary_Outer_Realms_Corrupter_ms6nuOl3NFkhPj1k.json index 9edf3f04..6c78dced 100644 --- a/src/packs/adversaries/adversary_Outer_Realms_Corrupter_ms6nuOl3NFkhPj1k.json +++ b/src/packs/adversaries/adversary_Outer_Realms_Corrupter_ms6nuOl3NFkhPj1k.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -297,7 +299,7 @@ "name": "Disgorge Realiy Flotsam", "type": "feature", "system": { - "description": "

Mark a Stress to spew partially digested portions of consumed realities at all targets within Close range. Targets must succeed on a Knowledge Reaction Roll or mark 2 Stress.

", + "description": "

Mark a Stress to spew partially digested portions of consumed realities at all targets within Close range. Targets must succeed on a Knowledge Reaction Roll or mark 2 Stress.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "6vX6VHpXX7OiGSWH": { @@ -341,8 +343,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -371,16 +372,7 @@ }, "name": "Roll Save", "img": "icons/magic/unholy/barrier-shield-glowing-pink.webp", - "range": "close", - "areas": [ - { - "name": "Disgorge Realiy Flotsam", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Outer_Realms_Thrall_moJhHgKqTKPS2WYS.json b/src/packs/adversaries/adversary_Outer_Realms_Thrall_moJhHgKqTKPS2WYS.json index 0bb3a44c..5a7a605a 100644 --- a/src/packs/adversaries/adversary_Outer_Realms_Thrall_moJhHgKqTKPS2WYS.json +++ b/src/packs/adversaries/adversary_Outer_Realms_Thrall_moJhHgKqTKPS2WYS.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "6VKv71tPUIGGIfkZ": { - "type": "attack", - "_id": "6VKv71tPUIGGIfkZ", + "tvQetauskZoHDR5y": { + "type": "effect", + "_id": "tvQetauskZoHDR5y", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { - "consumeOnSuccess": false, "scalable": false, "key": "fear", "value": 1, - "itemId": null, "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "11" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Patchwork_Zombie_Hulk_EQTOAOUrkIvS2z88.json b/src/packs/adversaries/adversary_Patchwork_Zombie_Hulk_EQTOAOUrkIvS2z88.json index 8e82dcf7..999f89b9 100644 --- a/src/packs/adversaries/adversary_Patchwork_Zombie_Hulk_EQTOAOUrkIvS2z88.json +++ b/src/packs/adversaries/adversary_Patchwork_Zombie_Hulk_EQTOAOUrkIvS2z88.json @@ -143,9 +143,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -196,7 +199,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -222,8 +225,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -315,46 +317,9 @@ "_id": "0fn7rVLwBnyCyvTA", "img": "icons/skills/melee/strike-slashes-orange.webp", "system": { - "description": "

When the @Lookup[@name] makes a standard attack, they can attack all targets within Very Close range.

", + "description": "

When the @Lookup[@name] makes a standard attack, they can attack all targets within Very Close range.

@Template[type:emanation|range:vc]

", "resource": null, - "actions": { - "ngl1xlJT4IOh3bkJ": { - "type": "effect", - "_id": "ngl1xlJT4IOh3bkJ", - "systemPath": "actions", - "baseAction": false, - "description": "", - "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, - "actionType": "action", - "triggers": [], - "areas": [ - { - "name": "Flailing Limbs", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ], - "cost": [], - "uses": { - "value": null, - "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "effects": [], - "target": { - "type": "any", - "amount": null - }, - "name": "", - "range": "" - } - }, + "actions": {}, "originItemType": null, "subType": null, "originId": null @@ -498,7 +463,7 @@ "_id": "uTtQwNg46NAjgzuD", "img": "icons/magic/death/skeleton-skull-soul-blue.webp", "system": { - "description": "

Mark a Stress to cause all PCs within Far range to make a Presence Reaction Roll (13). Targets who fail lose a Hope and you gain a Fear for each. Targets who succeed must mark a Stress.

", + "description": "

Mark a Stress to cause all PCs within Far range to make a Presence Reaction Roll (13). Targets who fail lose a Hope and you gain a Fear for each. Targets who succeed must mark a Stress.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "2NYC0D7wkBNrUAKl": { @@ -549,8 +514,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -579,16 +543,7 @@ }, "name": "Mark Stress", "img": "icons/magic/death/skeleton-skull-soul-blue.webp", - "range": "far", - "areas": [ - { - "name": "Tormented Screams", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Perfected_Zombie_CP6iRfHdyFWniTHY.json b/src/packs/adversaries/adversary_Perfected_Zombie_CP6iRfHdyFWniTHY.json index 06a18345..a6ce78d5 100644 --- a/src/packs/adversaries/adversary_Perfected_Zombie_CP6iRfHdyFWniTHY.json +++ b/src/packs/adversaries/adversary_Perfected_Zombie_CP6iRfHdyFWniTHY.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,15 +214,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "dquYnt5qiHZfnyD9": { @@ -263,8 +265,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -273,16 +274,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "far", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -332,7 +324,7 @@ "name": "Perfect Strike", "type": "feature", "system": { - "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against are Vulnerable until their next rest.

", + "description": "

Mark a Stress to make a standard attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against are Vulnerable until their next rest.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "un9btM1mN53JHIgV": { @@ -384,8 +376,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -419,16 +410,7 @@ }, "name": "Attack", "img": "icons/skills/melee/strike-axe-energy-pink.webp", - "range": "veryClose", - "areas": [ - { - "name": "Perfect Strike", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Rotted_Zombie_gP3fWTLzSFnpA8EJ.json b/src/packs/adversaries/adversary_Rotted_Zombie_gP3fWTLzSFnpA8EJ.json index f1c7f470..6755d27f 100644 --- a/src/packs/adversaries/adversary_Rotted_Zombie_gP3fWTLzSFnpA8EJ.json +++ b/src/packs/adversaries/adversary_Rotted_Zombie_gP3fWTLzSFnpA8EJ.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -243,95 +245,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "8wRrAWHU0xHW4zuE": { - "type": "attack", - "_id": "8wRrAWHU0xHW4zuE", + "DJBNtd3hWjwsjPwq": { + "type": "effect", + "_id": "DJBNtd3hWjwsjPwq", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "2" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Sellsword_bgreCaQ6ap2DVpCr.json b/src/packs/adversaries/adversary_Sellsword_bgreCaQ6ap2DVpCr.json index 46bed122..ed6d7775 100644 --- a/src/packs/adversaries/adversary_Sellsword_bgreCaQ6ap2DVpCr.json +++ b/src/packs/adversaries/adversary_Sellsword_bgreCaQ6ap2DVpCr.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -243,95 +245,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "K3pF2DBnR9zJ90W8": { - "type": "attack", - "_id": "K3pF2DBnR9zJ90W8", + "ghgFZskDiizJDjcn": { + "type": "effect", + "_id": "ghgFZskDiizJDjcn", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { - "consumeOnSuccess": false, "scalable": false, "key": "fear", "value": 1, - "itemId": null, "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "3" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Shark_YmVAkdNsyuXWTtYp.json b/src/packs/adversaries/adversary_Shark_YmVAkdNsyuXWTtYp.json index 0a6f27b0..f9bad7ea 100644 --- a/src/packs/adversaries/adversary_Shark_YmVAkdNsyuXWTtYp.json +++ b/src/packs/adversaries/adversary_Shark_YmVAkdNsyuXWTtYp.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,15 +214,14 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { "name": "Terrifying", "type": "feature", "system": { - "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

", + "description": "

When the @Lookup[@name] makes a successful attack, all PCs within Far range lose a Hope and you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "NoEb6qR3ktIu9kRJ": { @@ -263,8 +265,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -273,16 +274,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/death/skull-energy-light-purple.webp", - "range": "", - "areas": [ - { - "name": "Terrifying", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Siren_BK4jwyXSRx7IOQiO.json b/src/packs/adversaries/adversary_Siren_BK4jwyXSRx7IOQiO.json index 39f6a5b9..38f77982 100644 --- a/src/packs/adversaries/adversary_Siren_BK4jwyXSRx7IOQiO.json +++ b/src/packs/adversaries/adversary_Siren_BK4jwyXSRx7IOQiO.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -324,7 +326,7 @@ "name": "Enchanting Song", "type": "feature", "system": { - "description": "

Spend a Fear to sing a song that affects all targets within Close range. Targets must succeed on an Instinct Reaction Roll or become Entranced until they mark 2 Stress. Other @Lookup[@name]s within Close range of the target can mark a Stress to each add a +1 bonus to the Difficulty of the reaction roll. While Entranced, a target can’t act and is Vulnerable.

", + "description": "

Spend a Fear to sing a song that affects all targets within Close range. Targets must succeed on an Instinct Reaction Roll or become Entranced until they mark 2 Stress. Other @Lookup[@name]s within Close range of the target can mark a Stress to each add a +1 bonus to the Difficulty of the reaction roll. While Entranced, a target can’t act and is Vulnerable.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "FY8K8Nsg0TKAWok8": { @@ -349,8 +351,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -384,16 +385,7 @@ }, "name": "Roll Save", "img": "icons/magic/control/hypnosis-mesmerism-eye.webp", - "range": "close", - "areas": [ - { - "name": "Enchanting Song", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Skeleton_Dredge_6l1a3Fazq8BoKIcc.json b/src/packs/adversaries/adversary_Skeleton_Dredge_6l1a3Fazq8BoKIcc.json index 1a82abb8..e4cbab5e 100644 --- a/src/packs/adversaries/adversary_Skeleton_Dredge_6l1a3Fazq8BoKIcc.json +++ b/src/packs/adversaries/adversary_Skeleton_Dredge_6l1a3Fazq8BoKIcc.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -243,95 +245,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "6rdwJKwsSCO4R0Ty": { - "type": "attack", - "_id": "6rdwJKwsSCO4R0Ty", + "Sz55uB8xkoNytLwJ": { + "type": "effect", + "_id": "Sz55uB8xkoNytLwJ", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "1" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Skeleton_Knight_Q9LaVTyXF9NF12C7.json b/src/packs/adversaries/adversary_Skeleton_Knight_Q9LaVTyXF9NF12C7.json index e6982135..8b2042f3 100644 --- a/src/packs/adversaries/adversary_Skeleton_Knight_Q9LaVTyXF9NF12C7.json +++ b/src/packs/adversaries/adversary_Skeleton_Knight_Q9LaVTyXF9NF12C7.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -300,7 +302,7 @@ "_id": "WdVLwy9RNkVlZnCL", "img": "icons/skills/melee/strike-sword-steel-yellow.webp", "system": { - "description": "

Mark a Stress to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 1d8+2 physical damage and must mark a Stress.

", + "description": "

Mark a Stress to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 1d8+2 physical damage and must mark a Stress.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "vMv4monku9LOSxUZ": { @@ -377,8 +379,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -407,16 +408,7 @@ }, "name": "Attack", "img": "icons/skills/melee/strike-sword-steel-yellow.webp", - "range": "veryClose", - "areas": [ - { - "name": "Cut to the Bone", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Spellblade_ldbWEL7uZs84vyrR.json b/src/packs/adversaries/adversary_Spellblade_ldbWEL7uZs84vyrR.json index 5d72dfc7..90c7d68f 100644 --- a/src/packs/adversaries/adversary_Spellblade_ldbWEL7uZs84vyrR.json +++ b/src/packs/adversaries/adversary_Spellblade_ldbWEL7uZs84vyrR.json @@ -139,9 +139,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -192,7 +195,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -218,8 +221,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -254,7 +256,7 @@ "_id": "a76dNCrcoZOH1RRT", "img": "icons/magic/sonic/projectile-shock-wave-blue.webp", "system": { - "description": "

Mark a Stress and target a group within Far range. All targets must succeed on an Agility Reaction Roll or take 1d8+2 magic damage. You gain a Fear for each target who marked HP from this attack.

", + "description": "

Mark a Stress and target a group within Far range. All targets must succeed on an Agility Reaction Roll or take 1d8+2 magic damage. You gain a Fear for each target who marked HP from this attack.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "K4VnxigKTiu7hhZx": { @@ -306,8 +308,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -336,16 +337,7 @@ }, "name": "Attack", "img": "icons/magic/sonic/projectile-shock-wave-blue.webp", - "range": "far", - "areas": [ - { - "name": "Supressing Blast", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, @@ -402,16 +394,7 @@ }, "name": "Spend Fear", "img": "icons/skills/movement/arrows-up-trio-red.webp", - "range": "", - "areas": [ - { - "name": "Move as a Unit", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Stag_Knight_KGVwnLq85ywP9xvB.json b/src/packs/adversaries/adversary_Stag_Knight_KGVwnLq85ywP9xvB.json index 14e81a8c..e7738a46 100644 --- a/src/packs/adversaries/adversary_Stag_Knight_KGVwnLq85ywP9xvB.json +++ b/src/packs/adversaries/adversary_Stag_Knight_KGVwnLq85ywP9xvB.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -304,7 +306,7 @@ "name": "Blade of the Forest", "type": "feature", "system": { - "description": "

Spend a Fear to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take physical damage equal to [[/r 3d4]] + the target’s Major threshold.

", + "description": "

Spend a Fear to make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take physical damage equal to [[/r 3d4]] + the target’s Major threshold.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "xPSVwVVOC5gc2KTi": { @@ -329,8 +331,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -359,16 +360,7 @@ }, "name": "Attack", "img": "icons/skills/melee/strike-blade-hooked-green-purple.webp", - "range": "veryClose", - "areas": [ - { - "name": "Blade of the Forest", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Stonewraith_3aAS2Qm3R6cgaYfE.json b/src/packs/adversaries/adversary_Stonewraith_3aAS2Qm3R6cgaYfE.json index 52869085..c50c426d 100644 --- a/src/packs/adversaries/adversary_Stonewraith_3aAS2Qm3R6cgaYfE.json +++ b/src/packs/adversaries/adversary_Stonewraith_3aAS2Qm3R6cgaYfE.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -409,7 +411,7 @@ "name": "Avalanche Roar", "type": "feature", "system": { - "description": "

Spend a Fear to roar while within a cave and cause a cave-in. All targets within Close range must succeed on an Agility Reaction Roll (14) or take 2d10 physical damage. The rubble can be cleared with a Progress Countdown (8).

", + "description": "

Spend a Fear to roar while within a cave and cause a cave-in. All targets within Close range must succeed on an Agility Reaction Roll (14) or take 2d10 physical damage. The rubble can be cleared with a Progress Countdown (8).

@Template[type:emanation|range:c]

", "resource": null, "actions": { "4UGEEuK9XY8leCBV": { @@ -461,8 +463,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -491,16 +492,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/projectile-sound-rings-wave.webp", - "range": "close", - "areas": [ - { - "name": "Avalanche Roar", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" }, "UurIzyyMRAJc2DUX": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Tangle_Bramble_XcAGOSmtCFLT1unN.json b/src/packs/adversaries/adversary_Tangle_Bramble_XcAGOSmtCFLT1unN.json index d635b2ca..c36502de 100644 --- a/src/packs/adversaries/adversary_Tangle_Bramble_XcAGOSmtCFLT1unN.json +++ b/src/packs/adversaries/adversary_Tangle_Bramble_XcAGOSmtCFLT1unN.json @@ -164,9 +164,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -217,7 +220,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -243,8 +246,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -282,95 +284,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "V58Ry90tvIjvfDTZ": { - "type": "attack", - "_id": "V58Ry90tvIjvfDTZ", + "ZC5pKIb9N82vgMWu": { + "type": "effect", + "_id": "ZC5pKIb9N82vgMWu", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { - "consumeOnSuccess": false, "scalable": false, "key": "fear", "value": 1, - "itemId": null, "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "2" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/creatures/abilities/tail-strike-bone-orange.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Treant_Sapling_o63nS0k3wHu6EgKP.json b/src/packs/adversaries/adversary_Treant_Sapling_o63nS0k3wHu6EgKP.json index c03a1b52..c6c11d36 100644 --- a/src/packs/adversaries/adversary_Treant_Sapling_o63nS0k3wHu6EgKP.json +++ b/src/packs/adversaries/adversary_Treant_Sapling_o63nS0k3wHu6EgKP.json @@ -125,9 +125,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -178,7 +181,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -204,8 +207,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -240,95 +242,33 @@ "description": "

Spend a Fear to choose a target and spotlight all @Lookup[@name]s within Close range of them. Those Minions move into Melee range of the target and make one shared attack roll. On a success, they deal @Lookup[@system.attack.damageFormula] physical damage each. Combine this damage.

", "resource": null, "actions": { - "Itubbr63irPJcbXG": { - "type": "attack", - "_id": "Itubbr63irPJcbXG", + "euP8VA4wvfsCpwN1": { + "type": "effect", + "_id": "euP8VA4wvfsCpwN1", "systemPath": "actions", - "baseAction": false, "description": "", "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, "actionType": "action", - "triggers": [], "cost": [ { "scalable": false, "key": "fear", "value": 1, - "itemId": null, - "step": null, - "consumeOnSuccess": false + "step": null } ], "uses": { "value": null, "max": "", - "recovery": null, - "consumeOnSuccess": false - }, - "damage": { - "parts": { - "hitPoints": { - "applyTo": "hitPoints", - "resultBased": false, - "value": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": true, - "formula": "8" - } - }, - "valueAlt": { - "multiplier": "flat", - "flatMultiplier": 1, - "dice": "d6", - "bonus": null, - "custom": { - "enabled": false, - "formula": "" - } - }, - "base": false, - "type": [ - "physical" - ] - } - }, - "includeBase": false, - "direct": false, - "groupAttack": "close" - }, - "target": { - "type": "any", - "amount": null + "recovery": null }, "effects": [], - "roll": { - "type": "attack", - "trait": null, - "difficulty": null, - "bonus": null, - "advState": "neutral", - "diceRolling": { - "multiplier": "prof", - "flatMultiplier": 1, - "dice": "d6", - "compare": null, - "treshold": null - }, - "useDefault": false - }, - "save": { - "trait": null, - "difficulty": null, - "damageMod": "none" + "target": { + "type": "self", + "amount": null }, "name": "Spend Fear", + "img": "icons/magic/unholy/orb-hands-pink.webp", "range": "" } }, diff --git a/src/packs/adversaries/adversary_Vault_Guardian_Sentinel_FVgYb28fhxlVcGwA.json b/src/packs/adversaries/adversary_Vault_Guardian_Sentinel_FVgYb28fhxlVcGwA.json index ba3f5c33..d4fa0340 100644 --- a/src/packs/adversaries/adversary_Vault_Guardian_Sentinel_FVgYb28fhxlVcGwA.json +++ b/src/packs/adversaries/adversary_Vault_Guardian_Sentinel_FVgYb28fhxlVcGwA.json @@ -349,7 +349,7 @@ "name": "Mana Bolt", "type": "feature", "system": { - "description": "

Spend a Fear to lob explosive magic at a point within Far range. All targets within Very Close range of that point must make an Agility Reaction Roll. Targets who fail take 2d8+20 magic damage and are knocked back to Close range. Targets who succeed take half damage and aren’t knocked back.

", + "description": "

Spend a Fear to lob explosive magic at a point within Far range. All targets within Very Close range of that point must make an Agility Reaction Roll. Targets who fail take 2d8+20 magic damage and are knocked back to Close range. Targets who succeed take half damage and aren’t knocked back.

@Template[type:circle|range:vc]

", "resource": null, "actions": { "mI9i9iwrM48NjzeE": { @@ -430,16 +430,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/projectile-shock-wave-blue.webp", - "range": "far", - "areas": [ - { - "name": "Mana Bolt", - "type": "placed", - "shape": "circle", - "size": "veryClose", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Vault_Guardian_Turret_c5hGdvY5UnSjlHws.json b/src/packs/adversaries/adversary_Vault_Guardian_Turret_c5hGdvY5UnSjlHws.json index 018d5b58..d723df80 100644 --- a/src/packs/adversaries/adversary_Vault_Guardian_Turret_c5hGdvY5UnSjlHws.json +++ b/src/packs/adversaries/adversary_Vault_Guardian_Turret_c5hGdvY5UnSjlHws.json @@ -132,9 +132,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -185,7 +188,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -211,8 +214,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -410,7 +412,7 @@ "name": "Detonation", "type": "feature", "system": { - "description": "

When the @Lookup[@name] is destroyed, they explode. All targets within Close range must make an Agility Reaction Roll. Targets who fail take 3d20 physical damage. Targets who succeed take half damage.

", + "description": "

When the @Lookup[@name] is destroyed, they explode. All targets within Close range must make an Agility Reaction Roll. Targets who fail take 3d20 physical damage. Targets who succeed take half damage.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "i1PZ9ddYdOOs2xSb": { @@ -455,8 +457,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -485,16 +486,7 @@ }, "name": "Roll Save", "img": "icons/magic/sonic/explosion-shock-wave-teal.webp", - "range": "close", - "areas": [ - { - "name": "Detonation", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Volcanic_Dragon__Ashen_Tyrant_pMuXGCSOQaxpi5tb.json b/src/packs/adversaries/adversary_Volcanic_Dragon__Ashen_Tyrant_pMuXGCSOQaxpi5tb.json index e360f0c8..f6a8bc84 100644 --- a/src/packs/adversaries/adversary_Volcanic_Dragon__Ashen_Tyrant_pMuXGCSOQaxpi5tb.json +++ b/src/packs/adversaries/adversary_Volcanic_Dragon__Ashen_Tyrant_pMuXGCSOQaxpi5tb.json @@ -163,9 +163,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -216,7 +219,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -242,8 +245,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -476,8 +478,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -486,16 +487,7 @@ "effects": [], "name": "Lose Hope", "img": "icons/magic/fire/flame-burning-skull-orange.webp", - "range": "close", - "areas": [ - { - "name": "Ashes to Ashes", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -520,7 +512,7 @@ "name": "Desperate Rampage", "type": "feature", "system": { - "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d20+2 physical damage, are knocked back to Close range of where they were, and must mark a Stress.

", + "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 2d20+2 physical damage, are knocked back to Close range of where they were, and must mark a Stress.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "3glUQAcsLBcCumnS": { @@ -590,8 +582,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -620,16 +611,7 @@ }, "name": "Attack", "img": "icons/creatures/abilities/tail-swipe-green.webp", - "range": "close", - "areas": [ - { - "name": "Desperate Rampage", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -655,7 +637,7 @@ "name": "Ashen Cloud", "type": "feature", "system": { - "description": "

Spend a Fear to smash the ground and kick up ash within Far range. While within the ash cloud, a target has disadvantage on action rolls. The ash cloud clears the next time an adversary is spotlighted.

", + "description": "

Spend a Fear to smash the ground and kick up ash within Far range. While within the ash cloud, a target has disadvantage on action rolls. The ash cloud clears the next time an adversary is spotlighted.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "UrD4A68IBJgyfvvt": { @@ -685,16 +667,7 @@ }, "name": "Spend Fear", "img": "icons/magic/air/fog-gas-smoke-brown.webp", - "range": "", - "areas": [ - { - "name": "Ashen Cloud", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" } }, "originItemType": null, @@ -720,14 +693,14 @@ "name": "Apocalyptic Thrasing", "type": "feature", "system": { - "description": "

Countdown (1d12). Spend a Fear to activate. It ticks down when a PC rolls with Fear. When it triggers, the @Lookup[@name] thrashes about, causing environmental damage (such as an earthquake, avalanche, or collapsing walls). All targets within Far range must make a Strength Reaction Roll. Targets who fail take 2d10+10 physical damage and are Restrained by the rubble until they break free with a successful Strength Roll. Targets who succeed take half damage. If the @Lookup[@name] is defeated while this countdown is active, trigger the countdown immediately as the destruction caused by their death throes.

", + "description": "

Countdown (1d12). Spend a Fear to activate. It ticks down when a PC rolls with Fear. When it triggers, the @Lookup[@name] thrashes about, causing environmental damage (such as an earthquake, avalanche, or collapsing walls). All targets within Far range must make a Strength Reaction Roll. Targets who fail take 2d10+10 physical damage and are Restrained by the rubble until they break free with a successful Strength Roll. Targets who succeed take half damage. If the @Lookup[@name] is defeated while this countdown is active, trigger the countdown immediately as the destruction caused by their death throes.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "OznXxmwiPwzuFPQZ": { "type": "attack", "_id": "OznXxmwiPwzuFPQZ", "systemPath": "actions", - "description": "

When the countdown triggers, the @Lookup[@name] thrashes about, causing environmental damage (such as an earthquake, avalanche, or collapsing walls). All targets within Far range must make a Strength Reaction Roll. Targets who fail take 2d10+10 physical damage and are Restrained by the rubble until they break free with a successful Strength Roll. Targets who succeed take half damage. If the @Lookup[@name] is defeated while this countdown is active, trigger the countdown immediately as the destruction caused by their death throes.

", + "description": "

When the countdown triggers, the @Lookup[@name] thrashes about, causing environmental damage (such as an earthquake, avalanche, or collapsing walls). All targets within Far range must make a Strength Reaction Roll. Targets who fail take 2d10+10 physical damage and are Restrained by the rubble until they break free with a successful Strength Roll. Targets who succeed take half damage. If the @Lookup[@name] is defeated while this countdown is active, trigger the countdown immediately as the destruction caused by their death throes.

@Template[type:emanation|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -765,8 +738,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -800,16 +772,7 @@ }, "name": "Roll Save", "img": "icons/creatures/abilities/mouth-teeth-fire-orange.webp", - "range": "", - "areas": [ - { - "name": "Apocalyptic Thrasing", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "" }, "rZ7IwBnDzw7VmBT6": { "type": "countdown", diff --git a/src/packs/adversaries/adversary_Volcanic_Dragon__Molten_Scourge_eArAPuB38CNR0ZIM.json b/src/packs/adversaries/adversary_Volcanic_Dragon__Molten_Scourge_eArAPuB38CNR0ZIM.json index d4babd71..25c8b637 100644 --- a/src/packs/adversaries/adversary_Volcanic_Dragon__Molten_Scourge_eArAPuB38CNR0ZIM.json +++ b/src/packs/adversaries/adversary_Volcanic_Dragon__Molten_Scourge_eArAPuB38CNR0ZIM.json @@ -163,9 +163,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -216,7 +219,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -242,8 +245,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -440,7 +442,7 @@ "name": "Eruption", "type": "feature", "system": { - "description": "

Spend a Fear to erupt lava from beneath the @Lookup[@name]’s scales, filling the area within Very Close range with molten lava. All targets in that area must succeed on an Agility Reaction Roll or take 4d6+6 physical damage and be knocked back to Close range. This area remains lava. When a creature other than the @Lookup[@name] enters that area or acts while inside of it, they must mark 6 HP.

", + "description": "

Spend a Fear to erupt lava from beneath the @Lookup[@name]’s scales, filling the area within Very Close range with molten lava. All targets in that area must succeed on an Agility Reaction Roll or take 4d6+6 physical damage and be knocked back to Close range. This area remains lava. When a creature other than the @Lookup[@name] enters that area or acts while inside of it, they must mark 6 HP.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "OpwKa8tQQoaEIZiS": { @@ -485,8 +487,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -515,16 +516,7 @@ }, "name": "Roll Save", "img": "icons/magic/fire/blast-jet-stream-embers-red.webp", - "range": "veryClose", - "areas": [ - { - "name": "Eruption", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "veryClose" } }, "originItemType": null, @@ -550,7 +542,7 @@ "name": "Volcanic Breath", "type": "feature", "system": { - "description": "

When the @Lookup[@name] takes Major damage, roll a d10. On a result of 8 or higher, the @Lookup[@name] breathes a flow of lava in front of them within Far range. All targets in that area must make an Agility Reaction Roll. Targets who fail take 2d10+4 physical damage, mark 1d4 Stress, and are Vulnerable until they clear a Stress. Targets who succeed take half damage and must mark a Stress.

", + "description": "

When the @Lookup[@name] takes Major damage, roll a d10. On a result of 8 or higher, the @Lookup[@name] breathes a flow of lava in front of them within Far range. All targets in that area must make an Agility Reaction Roll. Targets who fail take 2d10+4 physical damage, mark 1d4 Stress, and are Vulnerable until they clear a Stress. Targets who succeed take half damage and must mark a Stress.

@Template[type:inFront|range:f]

", "resource": null, "actions": { "OhrssSQhmciZt1Rm": { @@ -610,7 +602,7 @@ "type": "attack", "_id": "LBNvfABGWcrygpQM", "systemPath": "actions", - "description": "

The @Lookup[@name]Β breathes a flow of lava in front of them within Far range. All targets in that area must make an Agility Reaction Roll. Targets who fail take 2d10+4 physical damage, mark 1d4 Stress, and are Vulnerable until they clear a Stress. Targets who succeed take half damage and must mark a Stress.

", + "description": "

The @Lookup[@name] breathes a flow of lava in front of them within Far range. All targets in that area must make an Agility Reaction Roll. Targets who fail take 2d10+4 physical damage, mark 1d4 Stress, and are Vulnerable until they clear a Stress. Targets who succeed take half damage and must mark a Stress.

@Template[type:inFront|range:f]

", "chatDisplay": true, "actionType": "action", "cost": [], @@ -672,8 +664,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -707,16 +698,7 @@ }, "name": "Roll Save", "img": "icons/magic/fire/blast-jet-stream-embers-orange.webp", - "range": "far", - "areas": [ - { - "name": "Volcanic Breath", - "type": "placed", - "shape": "inFront", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Volcanic_Dragon__Obsidian_Predator_ladm7wykhZczYzrQ.json b/src/packs/adversaries/adversary_Volcanic_Dragon__Obsidian_Predator_ladm7wykhZczYzrQ.json index 82daed6a..227efccc 100644 --- a/src/packs/adversaries/adversary_Volcanic_Dragon__Obsidian_Predator_ladm7wykhZczYzrQ.json +++ b/src/packs/adversaries/adversary_Volcanic_Dragon__Obsidian_Predator_ladm7wykhZczYzrQ.json @@ -163,9 +163,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -216,7 +219,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -242,8 +245,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -446,7 +448,7 @@ "name": "Avalanche Tail", "type": "feature", "system": { - "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 4d6+4 physical damage and are knocked.

", + "description": "

Mark a Stress to make an attack against all targets within Close range. Targets the @Lookup[@name] succeeds against take 4d6+4 physical damage and are knocked.

@Template[type:emanation|range:c]

", "resource": null, "actions": { "23y0BoufIgNq62j9": { @@ -489,8 +491,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -524,16 +525,7 @@ }, "name": "Attack", "img": "icons/creatures/abilities/tail-swipe-green.webp", - "range": "close", - "areas": [ - { - "name": "Avalanche Tail", - "type": "placed", - "shape": "emanation", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -556,15 +548,18 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [] + } }, + "changes": [], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, "description": "

Vulnerable until your next roll with Hope.

", "tint": "#ffffff", @@ -576,9 +571,6 @@ "_stats": { "compendiumSource": null }, - "start": null, - "showIcon": 1, - "folder": null, "_key": "!actors.items.effects!ladm7wykhZczYzrQ.8bMOItTuL7PfAYcJ.qtIaAZDW8QsjILgb" } ], @@ -598,7 +590,7 @@ "name": "Dive-Bomb", "type": "feature", "system": { - "description": "

If the @Lookup[@name] is flying, mark a Stress to choose a point within Far range. Move to that point and make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 2d10+6 physical damage and must mark a Stress and lose a Hope.

", + "description": "

If the @Lookup[@name] is flying, mark a Stress to choose a point within Far range. Move to that point and make an attack against all targets within Very Close range. Targets the @Lookup[@name] succeeds against take 2d10+6 physical damage and must mark a Stress and lose a Hope.

@Template[type:emanation|range:vc]

", "resource": null, "actions": { "OpAT9nxlbgvnhdBg": { @@ -693,8 +685,7 @@ "type": [] } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -723,16 +714,7 @@ }, "name": "Attack", "img": "icons/creatures/reptiles/dragon-winged-blue.webp", - "range": "far", - "areas": [ - { - "name": "Dive-Bomb", - "type": "placed", - "shape": "emanation", - "size": "veryClose", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_War_Wizard_noDdT0tsN6FXSmC8.json b/src/packs/adversaries/adversary_War_Wizard_noDdT0tsN6FXSmC8.json index 0ba663ab..55be8e1a 100644 --- a/src/packs/adversaries/adversary_War_Wizard_noDdT0tsN6FXSmC8.json +++ b/src/packs/adversaries/adversary_War_Wizard_noDdT0tsN6FXSmC8.json @@ -143,9 +143,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -196,7 +199,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -222,8 +225,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -341,7 +343,7 @@ "name": "Eruption", "type": "feature", "system": { - "description": "

Spend a Fear and choose a point within Far range. A Very Close area around that point erupts into impassable terrain. All targets within that area must make an Agility Reaction Roll (14). Targets who fail take 2d10 physical damage and are thrown out of the area. Targets who succeed take half damage and aren’t moved.

", + "description": "

Spend a Fear and choose a point within Far range. A Very Close area around that point erupts into impassable terrain. All targets within that area must make an Agility Reaction Roll (14). Targets who fail take 2d10 physical damage and are thrown out of the area. Targets who succeed take half damage and aren’t moved.

@Template[type:circle|range:vc]

", "resource": null, "actions": { "vnMq4NuQO6GYxWhM": { @@ -422,16 +424,7 @@ }, "name": "Roll Save", "img": "icons/magic/earth/barrier-stone-explosion-red.webp", - "range": "far", - "areas": [ - { - "name": "Eruption", - "type": "placed", - "shape": "circle", - "size": "veryClose", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/adversaries/adversary_Young_Ice_Dragon_UGPiPLJsPvMTSKEF.json b/src/packs/adversaries/adversary_Young_Ice_Dragon_UGPiPLJsPvMTSKEF.json index 6c55ba15..09e76fa8 100644 --- a/src/packs/adversaries/adversary_Young_Ice_Dragon_UGPiPLJsPvMTSKEF.json +++ b/src/packs/adversaries/adversary_Young_Ice_Dragon_UGPiPLJsPvMTSKEF.json @@ -138,9 +138,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/dragon-head.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -191,7 +194,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -217,8 +220,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -386,7 +388,7 @@ "name": "Blizzard Breath", "type": "feature", "system": { - "description": "

Spend 2 Fear to release an icy whorl in front of the @Lookup[@name] within Close range. All targets in this area must make an Agility Reaction Roll. Targets who fail take 4d6+5 magic damage and are Restrained by ice until they break free with a successful Strength Roll. Targets who succeed must mark 2 Stress or take half damage.

", + "description": "

Spend 2 Fear to release an icy whorl in front of the @Lookup[@name] within Close range. All targets in this area must make an Agility Reaction Roll. Targets who fail take 4d6+5 magic damage and are Restrained by ice until they break free with a successful Strength Roll. Targets who succeed must mark 2 Stress or take half damage.

@Template[type:inFront|range:c]

", "resource": null, "actions": { "CBecTlgyUBFxgoi5": { @@ -438,8 +440,7 @@ } } }, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -473,16 +474,7 @@ }, "name": "Roll Save", "img": "icons/magic/water/projectiles-ice-faceted-shard-salvo-blue.webp", - "range": "close", - "areas": [ - { - "name": "Blizzard Breath", - "type": "placed", - "shape": "inFront", - "size": "close", - "effects": [] - } - ] + "range": "close" } }, "originItemType": null, @@ -505,15 +497,18 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [] + } }, + "changes": [], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, "description": "

Restrained by ice until you break free with a successful Strength Roll.

", "tint": "#ffffff", @@ -525,9 +520,6 @@ "_stats": { "compendiumSource": null }, - "start": null, - "showIcon": 1, - "folder": null, "_key": "!actors.items.effects!UGPiPLJsPvMTSKEF.QV2ytK4b1VWF71OS.g9bUvmw3jet6T99e" } ], @@ -547,7 +539,7 @@ "name": "Avalanche", "type": "feature", "system": { - "description": "

Spend a Fear to have the @Lookup[@name] unleash a huge downfall of snow and ice, covering all other creatures within Far range. All targets within this area must succeed on an Instinct Reaction Roll or be buried in snow and rocks, becoming Vulnerable until they dig themselves out from the debris. For each PC that fails the reaction roll, you gain a Fear.

", + "description": "

Spend a Fear to have the @Lookup[@name] unleash a huge downfall of snow and ice, covering all other creatures within Far range. All targets within this area must succeed on an Instinct Reaction Roll or be buried in snow and rocks, becoming Vulnerable until they dig themselves out from the debris. For each PC that fails the reaction roll, you gain a Fear.

@Template[type:emanation|range:f]

", "resource": null, "actions": { "G9LjoXShkCcgx8EC": { @@ -572,8 +564,7 @@ }, "damage": { "parts": {}, - "includeBase": false, - "groupAttack": "" + "includeBase": false }, "target": { "type": "any", @@ -607,16 +598,7 @@ }, "name": "Attack", "img": "icons/magic/water/barrier-ice-wall-snow.webp", - "range": "far", - "areas": [ - { - "name": "Avalanche", - "type": "placed", - "shape": "emanation", - "size": "far", - "effects": [] - } - ] + "range": "far" } }, "originItemType": null, diff --git a/src/packs/ancestries/feature_Retract_UFR67BUOhNGLFyg9.json b/src/packs/ancestries/feature_Retract_UFR67BUOhNGLFyg9.json index eb9696b2..b17cd7da 100644 --- a/src/packs/ancestries/feature_Retract_UFR67BUOhNGLFyg9.json +++ b/src/packs/ancestries/feature_Retract_UFR67BUOhNGLFyg9.json @@ -68,33 +68,31 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [ - { - "key": "system.resistance.physical.resistance", - "type": "override", - "value": 1, - "priority": null, - "phase": "initial" - }, - { - "key": "system.disadvantageSources", - "type": "add", - "value": "Action rolls", - "priority": null, - "phase": "initial" - } - ], - "duration": { - "type": "" } }, + "changes": [ + { + "key": "system.resistance.physical.resistance", + "mode": 5, + "value": "1", + "priority": null + }, + { + "key": "system.disadvantageSources", + "mode": 2, + "value": "Retract", + "priority": null + } + ], "disabled": true, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, "description": "

While in your shell, you have resistance to physical damage, you have disadvantage on action rolls, and you can’t move.

", "tint": "#ffffff", @@ -104,16 +102,6 @@ "_stats": { "compendiumSource": null }, - "start": { - "time": 0, - "combat": null, - "combatant": null, - "initiative": null, - "round": null, - "turn": null - }, - "showIcon": 1, - "folder": null, "_key": "!items.effects!UFR67BUOhNGLFyg9.3V4FPoyjJUnFP9WS" } ], diff --git a/src/packs/communities/feature_Low_Light_Living_aMla3xQuCHEwORGD.json b/src/packs/communities/feature_Low_Light_Living_aMla3xQuCHEwORGD.json index c95d9132..f1ed3ace 100644 --- a/src/packs/communities/feature_Low_Light_Living_aMla3xQuCHEwORGD.json +++ b/src/packs/communities/feature_Low_Light_Living_aMla3xQuCHEwORGD.json @@ -29,28 +29,39 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [ - { - "key": "system.advantageSources", - "type": "add", - "value": "Rolls to hide, investigate, or perceive details in low light", - "priority": null, - "phase": "initial" - } - ], - "duration": { - "type": "" } }, + "changes": [ + { + "key": "system.advantageSources", + "mode": 2, + "value": "In an area with low light or heavy shadow: hide, investigate, or perceive", + "priority": null + }, + { + "key": "system.advantageSources", + "mode": 2, + "value": "", + "priority": null + }, + { + "key": "", + "mode": 2, + "value": "", + "priority": null + } + ], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, - "description": "

When you’re in an area with low light or heavy shadow, you have advantage on rolls to hide, investigate, or perceive details within that area.

", + "description": "", "origin": null, "tint": "#ffffff", "transfer": true, @@ -60,16 +71,6 @@ "_stats": { "compendiumSource": null }, - "start": { - "time": 0, - "combat": null, - "combatant": null, - "initiative": null, - "round": null, - "turn": null - }, - "showIcon": 1, - "folder": null, "_key": "!items.effects!aMla3xQuCHEwORGD.pCp32u7UwqxCI4WW" } ], diff --git a/src/packs/domains/domainCard_Bare_Bones_l5D9kq901JDESaXw.json b/src/packs/domains/domainCard_Bare_Bones_l5D9kq901JDESaXw.json index 7956d6eb..098f5f4c 100644 --- a/src/packs/domains/domainCard_Bare_Bones_l5D9kq901JDESaXw.json +++ b/src/packs/domains/domainCard_Bare_Bones_l5D9kq901JDESaXw.json @@ -4,7 +4,7 @@ "type": "domainCard", "folder": "QpOL7jPbMBzH96qR", "system": { - "description": "

When you choose not to equip armor, you have a base Armor Score of 3 + your Strength and use the following as your base damage thresholds:

", + "description": "

When you choose not to equip armor, you have a base Armor Score of 3 + your Strength and use the following as your base damage thresholds:

Equip the below armor to use Bare Bones.

@UUID[Compendium.daggerheart.armors.Item.ITAjcigTcUw5pMCN]{Bare Bones}

", "domain": "valor", "recallCost": 0, "level": 1, @@ -28,33 +28,22 @@ { "type": "armor", "phase": "initial", + "priority": 20, "value": { - "current": 0, "max": "3 + @system.traits.strength.value", "interaction": "inactive", "damageThresholds": { - "major": "9 + (@tier - 1) * 2", + "major": "9 + (@tier - 1) * 5 + max(0, (@tier -2) * 2 )", "severe": "19 + (@tier - 1) * 5 + max(0, (@tier -2) * 2 )" } - }, - "priority": 20 + } } - ], - "duration": { - "type": "" - } + ] }, "_id": "FCsgz7Tdsw6QUzBs", "img": "icons/magic/control/buff-strength-muscle-damage-orange.webp", "disabled": false, - "start": { - "time": 0, - "combat": null, - "combatant": null, - "initiative": null, - "round": null, - "turn": null - }, + "start": null, "duration": { "value": null, "units": "seconds", diff --git a/src/packs/domains/domainCard_Battle_Cry_Ef1JsUG50LIoKx2F.json b/src/packs/domains/domainCard_Battle_Cry_Ef1JsUG50LIoKx2F.json index 1fde286d..c9ae6071 100644 --- a/src/packs/domains/domainCard_Battle_Cry_Ef1JsUG50LIoKx2F.json +++ b/src/packs/domains/domainCard_Battle_Cry_Ef1JsUG50LIoKx2F.json @@ -132,29 +132,27 @@ "type": "withinRange", "target": "hostile", "range": "melee" - }, - "changes": [ - { - "key": "system.advantageSources", - "type": "add", - "value": "On Attacks", - "priority": null, - "phase": "initial" - } - ], - "duration": { - "type": "temporary", - "description": "

Until you or an ally rolls a failure with Fear.

" } }, + "changes": [ + { + "key": "system.advantageSources", + "mode": 2, + "value": "1", + "priority": null + } + ], "disabled": false, "duration": { - "value": null, - "units": "seconds", - "expiry": null, - "expired": false + "startTime": null, + "combat": null, + "seconds": null, + "rounds": null, + "turns": null, + "startRound": null, + "startTurn": null }, - "description": "

You gain advantage on attack rolls until you or an ally rolls a failure with Fear.

", + "description": "", "tint": "#ffffff", "statuses": [], "sort": 0, @@ -162,16 +160,6 @@ "_stats": { "compendiumSource": null }, - "start": { - "time": 0, - "combat": null, - "combatant": null, - "initiative": null, - "round": null, - "turn": null - }, - "showIcon": 1, - "folder": null, "_key": "!items.effects!Ef1JsUG50LIoKx2F.s7ma4TNgAvt0ZgEW" } ], diff --git a/src/packs/environments/environment_Abandoned_Grove_pGEdzdLkqYtBhxnG.json b/src/packs/environments/environment_Abandoned_Grove_pGEdzdLkqYtBhxnG.json index 0cab16a2..75fc932f 100644 --- a/src/packs/environments/environment_Abandoned_Grove_pGEdzdLkqYtBhxnG.json +++ b/src/packs/environments/environment_Abandoned_Grove_pGEdzdLkqYtBhxnG.json @@ -52,9 +52,12 @@ "src": "systems/daggerheart/assets/icons/documents/actors/forest.svg", "anchorX": 0.5, "anchorY": 0.5, + "offsetX": 0, + "offsetY": 0, "fit": "contain", "scaleX": 1, "scaleY": 1, + "rotation": 0, "tint": "#ffffff", "alphaThreshold": 0.75 }, @@ -105,7 +108,7 @@ "saturation": 0, "contrast": 0 }, - "detectionModes": {}, + "detectionModes": [], "occludable": { "radius": 0 }, @@ -131,8 +134,7 @@ "flags": {}, "randomImg": false, "appendNumber": false, - "prependAdjective": false, - "depth": 1 + "prependAdjective": false }, "items": [ { @@ -321,42 +323,7 @@ "system": { "description": "

A @UUID[Compendium.daggerheart.adversaries.Actor.8yUj2Mzvnifhxegm]{Young Dryad}, two @UUID[Compendium.daggerheart.adversaries.Actor.VtFBt9XBE0WrGGxP]{Sylvan Soldiers}, and a number of @UUID[Compendium.daggerheart.adversaries.Actor.G62k4oSkhkoXEs2D]{Minor Treants} equal to the number of PCs appear to confront the party for their intrusion.

What are the grove guardians concealing? What threat to the forest could the PCs confront to appease the Dryad?

", "resource": null, - "actions": { - "TPm6rpKA4mbili82": { - "type": "summon", - "_id": "TPm6rpKA4mbili82", - "systemPath": "actions", - "baseAction": false, - "description": "", - "chatDisplay": true, - "originItem": { - "type": "itemCollection" - }, - "actionType": "action", - "triggers": [], - "cost": [], - "uses": { - "value": null, - "max": null, - "recovery": null, - "consumeOnSuccess": false - }, - "summon": [ - { - "actorUUID": "Compendium.daggerheart.adversaries.Actor.8yUj2Mzvnifhxegm", - "count": "1" - }, - { - "actorUUID": "Compendium.daggerheart.adversaries.Actor.VtFBt9XBE0WrGGxP", - "count": "2" - }, - { - "actorUUID": "Compendium.daggerheart.adversaries.Actor.G62k4oSkhkoXEs2D", - "count": "@partySize" - } - ] - } - }, + "actions": {}, "originItemType": null, "originId": null, "featureForm": "action" diff --git a/styles/less/dialog/character-creation/selections-container.less b/styles/less/dialog/character-creation/selections-container.less index 2bbac484..f9569fca 100644 --- a/styles/less/dialog/character-creation/selections-container.less +++ b/styles/less/dialog/character-creation/selections-container.less @@ -175,11 +175,6 @@ opacity: 0.2; } - &.no-horizontal-padding { - padding-left: 0; - padding-right: 0; - } - legend { margin-left: auto; margin-right: auto; @@ -255,11 +250,6 @@ height: 65px; background: url(../assets/svg/trait-shield.svg) no-repeat; background-size: 100%; - padding-top: 3px; - display: flex; - flex-direction: column; - align-items: center; - row-gap: 3px; div { filter: drop-shadow(0 0 3px black); @@ -288,15 +278,6 @@ flex-direction: column; gap: 5px; - &.separated { - border-bottom: 2px solid; - padding-bottom: 8px; - } - - .form-group { - padding: 0 0.75rem; - } - .experience-inner-container { position: relative; display: flex; diff --git a/styles/less/dialog/damage-selection/sheet.less b/styles/less/dialog/damage-selection/sheet.less index 9f8cfc8a..0f765748 100644 --- a/styles/less/dialog/damage-selection/sheet.less +++ b/styles/less/dialog/damage-selection/sheet.less @@ -21,7 +21,7 @@ gap: 4px; .critical-chip { flex: 0; - + display: flex; align-items: center; border-radius: 5px; @@ -41,26 +41,6 @@ } } - .group-attack-container { - margin: 0; - - .group-attack-inner-container { - display: flex; - align-items: center; - gap: 16px; - - > * { - flex: 1; - } - - .group-attack-tools { - display: flex; - align-items: center; - gap: 4px; - } - } - } - .damage-section-controls { display: flex; align-items: center; diff --git a/styles/less/dialog/group-roll-dialog/initialization.less b/styles/less/dialog/group-roll-dialog/initialization.less deleted file mode 100644 index b2e7e021..00000000 --- a/styles/less/dialog/group-roll-dialog/initialization.less +++ /dev/null @@ -1,79 +0,0 @@ -.theme-light .daggerheart.dialog.dh-style.views.group-roll-dialog { - .initialization-container .members-container .member-container { - .member-name { - background-image: url('../assets/parchments/dh-parchment-light.png'); - } - } -} - -.daggerheart.dialog.dh-style.views.group-roll-dialog { - .initialization-container { - h2 { - text-align: center; - } - - .members-container { - display: grid; - grid-template-columns: 1fr 1fr 1fr 1fr; - gap: 8px; - - .member-container { - position: relative; - display: flex; - justify-content: center; - - &.inactive { - opacity: 0.4; - } - - .member-name { - position: absolute; - padding: 0 2px; - border: 1px solid; - border-radius: 6px; - margin-top: 4px; - color: light-dark(@dark, @beige); - background-image: url('../assets/parchments/dh-parchment-dark.png'); - text-align: center; - } - - img { - border-radius: 6px; - border: 1px solid light-dark(@dark-blue, @golden); - } - } - } - - .main-roll { - margin-top: 8px; - display: grid; - grid-template-columns: 1fr 1fr; - gap: 8px; - - &.inactive { - opacity: 0.4; - } - } - - footer { - margin-top: 8px; - display: flex; - gap: 8px; - - button { - flex: 1; - } - - .finish-tools { - flex: none; - display: flex; - align-items: center; - gap: 4px; - - &.inactive { - opacity: 0.4; - } - } - } - } -} diff --git a/styles/less/dialog/group-roll-dialog/leader.less b/styles/less/dialog/group-roll-dialog/leader.less deleted file mode 100644 index b3fa3a3b..00000000 --- a/styles/less/dialog/group-roll-dialog/leader.less +++ /dev/null @@ -1,35 +0,0 @@ -.daggerheart.dialog.dh-style.views.group-roll-dialog { - .main-character-outer-container { - &.inactive { - opacity: 0.3; - pointer-events: none; - } - - .main-character-container { - .character-info { - display: flex; - align-items: center; - justify-content: space-between; - width: 100%; - height: 64px; - - img { - height: 64px; - border-radius: 6px; - border: 1px solid light-dark(@dark-blue, @golden); - } - - .character-data { - padding-left: 0.75rem; - flex: 1; - height: 100%; - display: flex; - flex-direction: column; - justify-content: space-between; - text-align: left; - font-size: var(--font-size-18); - } - } - } - } -} diff --git a/styles/less/dialog/group-roll-dialog/sheet.less b/styles/less/dialog/group-roll-dialog/sheet.less deleted file mode 100644 index 70afc1fe..00000000 --- a/styles/less/dialog/group-roll-dialog/sheet.less +++ /dev/null @@ -1,265 +0,0 @@ -.daggerheart.dialog.dh-style.views.group-roll-dialog { - .team-container { - display: grid; - grid-template-columns: 1fr 1fr; - gap: 16px; - margin-bottom: 16px; - - .team-member-container { - display: flex; - flex-direction: column; - justify-content: space-between; - gap: 8px; - flex: 1; - - &.inactive { - opacity: 0.3; - pointer-events: none; - } - - .data-container { - display: flex; - flex-direction: column; - gap: 8px; - width: 100%; - } - - .member-info { - display: flex; - align-items: start; - width: 100%; - - img { - height: 64px; - border-radius: 6px; - border: 1px solid light-dark(@dark-blue, @golden); - } - - .member-data { - padding-left: 0.75rem; - flex: 1; - height: 100%; - display: flex; - flex-direction: column; - justify-content: space-between; - text-align: left; - font-size: var(--font-size-18); - } - } - } - } - - .roll-container { - display: flex; - flex-direction: column; - } - - .roll-title { - font-size: var(--font-size-20); - font-weight: bold; - color: light-dark(@dark-blue, @golden); - text-align: center; - display: flex; - align-items: center; - gap: 8px; - - &.hope, - &.fear, - &.critical { - color: var(--text-color); - } - - &.hope { - --text-color: @golden; - } - - &.fear { - --text-color: @chat-blue; - } - - &.critical { - --text-color: @chat-purple; - } - - &::before, - &::after { - color: var(--text-color); - content: ''; - flex: 1; - height: 2px; - } - - &::before { - background: linear-gradient(90deg, rgba(0, 0, 0, 0) 0%, light-dark(@dark-blue, @golden) 100%); - } - - &::after { - background: linear-gradient(90deg, light-dark(@dark-blue, @golden) 0%, rgba(0, 0, 0, 0) 100%); - } - } - - .roll-tools { - display: flex; - gap: 4px; - align-items: center; - - img { - height: 16px; - } - - a { - display: flex; - font-size: 16px; - - &:hover { - text-shadow: none; - filter: drop-shadow(0 0 8px var(--golden)); - } - } - } - - .roll-data { - display: flex; - flex-direction: column; - align-items: center; - gap: 4px; - - &.hope { - --text-color: @golden; - --bg-color: @golden-40; - } - - &.fear { - --text-color: @chat-blue; - --bg-color: @chat-blue-40; - } - - &.critical { - --text-color: @chat-purple; - --bg-color: @chat-purple-40; - } - - .duality-label { - color: var(--text-color); - font-size: var(--font-size-20); - font-weight: bold; - text-align: center; - - .unused-damage { - text-decoration: line-through; - } - } - - .roll-dice-container { - display: flex; - align-items: center; - justify-content: center; - flex-wrap: wrap; - gap: 8px; - - .roll-dice { - position: relative; - display: flex; - align-items: center; - justify-content: center; - - .dice-label { - position: absolute; - color: white; - font-size: 1rem; - paint-order: stroke fill; - -webkit-text-stroke: 2px black; - } - - img { - height: 32px; - } - } - - .roll-operator { - font-size: var(--font-size-24); - } - - .roll-value { - font-size: 18px; - } - } - - .roll-total { - background: var(--bg-color); - color: var(--text-color); - border-radius: 4px; - padding: 3px; - } - } - - .roll-success-container { - display: flex; - align-items: center; - justify-content: space-around; - - .roll-success-tools { - display: flex; - align-items: center; - gap: 4px; - color: light-dark(@dark-blue, @golden); - - i { - font-size: 24px; - } - } - - .roll-success-modifier { - display: flex; - align-items: center; - justify-content: right; - gap: 2px; - font-size: var(--font-size-20); - padding: 0px 4px; - - &.success { - background: @green-10; - color: @green; - } - - &.failure { - background: @red-10; - color: @red; - } - } - } - - .section-title { - font-size: var(--font-size-18); - font-weight: bold; - } - - .group-roll-results { - display: flex; - flex-direction: column; - align-items: center; - gap: 4px; - font-size: var(--font-size-20); - - .group-roll-container { - display: flex; - align-items: center; - gap: 2px; - } - } - - .finish-container { - margin-top: 16px; - gap: 16px; - display: grid; - grid-template-columns: 1fr 1fr 1fr; - - .finish-button { - grid-column: span 2; - } - } - - .hint { - text-align: center; - } -} diff --git a/styles/less/dialog/index.less b/styles/less/dialog/index.less index 947142ff..73738eaa 100644 --- a/styles/less/dialog/index.less +++ b/styles/less/dialog/index.less @@ -36,10 +36,6 @@ @import './tag-team-dialog/initialization.less'; @import './tag-team-dialog/sheet.less'; -@import './group-roll-dialog/initialization.less'; -@import './group-roll-dialog/leader.less'; -@import './group-roll-dialog/sheet.less'; - @import './image-select/sheet.less'; @import './item-transfer/sheet.less'; diff --git a/styles/less/dialog/tag-team-dialog/initialization.less b/styles/less/dialog/tag-team-dialog/initialization.less index 8557d231..30676f82 100644 --- a/styles/less/dialog/tag-team-dialog/initialization.less +++ b/styles/less/dialog/tag-team-dialog/initialization.less @@ -1,11 +1,3 @@ -.theme-light .daggerheart.dialog.dh-style.views.tag-team-dialog { - .initialization-container .members-container .member-container { - .member-name { - background-image: url('../assets/parchments/dh-parchment-light.png'); - } - } -} - .daggerheart.dialog.dh-style.views.tag-team-dialog { .initialization-container { h2 { @@ -28,18 +20,6 @@ .member-name { position: absolute; - padding: 0 2px; - border: 1px solid; - border-radius: 6px; - margin-top: 4px; - color: light-dark(@dark, @beige); - background-image: url('../assets/parchments/dh-parchment-dark.png'); - text-align: center; - } - - img { - border-radius: 6px; - border: 1px solid light-dark(@dark-blue, @golden); } } } diff --git a/styles/less/global/elements.less b/styles/less/global/elements.less index c5bca1da..793c8164 100755 --- a/styles/less/global/elements.less +++ b/styles/less/global/elements.less @@ -419,19 +419,11 @@ width: fit-content; display: flex; align-items: center; - .form-fields { height: 32px; align-content: center; } } - - &.select { - width: fit-content; - display: flex; - align-items: center; - gap: 4px; - } } .scalable-input { diff --git a/styles/less/global/inventory-item.less b/styles/less/global/inventory-item.less index a2b9ebd8..4bd4d0bb 100644 --- a/styles/less/global/inventory-item.less +++ b/styles/less/global/inventory-item.less @@ -24,15 +24,6 @@ width: 100%; list-style-type: none; - &.bordered { - border: 1px solid; - border-radius: 6px; - - .inventory-item-header .img-portait img.item-img { - border-radius: 6px 0 0 6px; - } - } - &:not(.single-img) { .img-portait:has(.roll-img):hover { .roll-img { diff --git a/styles/less/global/prose-mirror.less b/styles/less/global/prose-mirror.less index 8a663e28..3523dc89 100644 --- a/styles/less/global/prose-mirror.less +++ b/styles/less/global/prose-mirror.less @@ -25,7 +25,7 @@ } h4 { font-size: var(--font-size-16); - color: light-dark(@dark, @beige); + color: @beige; font-weight: 600; } diff --git a/styles/less/sheets-settings/character-settings/sheet.less b/styles/less/sheets-settings/character-settings/sheet.less index eab29436..f7f16df4 100644 --- a/styles/less/sheets-settings/character-settings/sheet.less +++ b/styles/less/sheets-settings/character-settings/sheet.less @@ -27,11 +27,10 @@ height: 65px; background: url(../assets/svg/trait-shield.svg) no-repeat; background-size: 100%; - padding-top: 3px; + padding-top: 4px; display: flex; flex-direction: column; align-items: center; - row-gap: 3px; span { font-size: var(--font-size-10); diff --git a/styles/less/sheets/actions/actions.less b/styles/less/sheets/actions/actions.less index 485f8e91..5a18d622 100644 --- a/styles/less/sheets/actions/actions.less +++ b/styles/less/sheets/actions/actions.less @@ -147,10 +147,4 @@ padding-bottom: 7px; } } - - .sub-section-header { - display: flex; - align-items: center; - gap: 4px; - } } diff --git a/styles/less/sheets/actors/actor-sheet-shared.less b/styles/less/sheets/actors/actor-sheet-shared.less index bd82ef83..23db088a 100644 --- a/styles/less/sheets/actors/actor-sheet-shared.less +++ b/styles/less/sheets/actors/actor-sheet-shared.less @@ -37,59 +37,6 @@ color: light-dark(@chat-blue-bg, @beige-50); } - .tab.inventory { - .search-section { - display: flex; - gap: 10px; - align-items: center; - } - .search-bar { - position: relative; - color: light-dark(@dark-blue-50, @beige-50); - width: 100%; - padding-top: 5px; - - input { - border-radius: 50px; - background: light-dark(@dark-blue-10, @golden-10); - border: none; - outline: 2px solid transparent; - transition: all 0.3s ease; - padding: 0 20px; - - &:hover { - outline: 2px solid light-dark(@dark, @golden); - } - - &::-webkit-search-cancel-button { - -webkit-appearance: none; - display: none; - } - } - - .icon { - align-content: center; - height: 32px; - position: absolute; - right: 20px; - font-size: 16px; - z-index: 1; - color: light-dark(@dark-blue-50, @beige-50); - } - } - - .gold-section { - display: grid; - grid-template-columns: 1fr 1fr 1fr 1fr; - gap: 10px; - padding: 10px 10px 0; - - .input { - color: light-dark(@dark, @beige); - } - } - } - &.limited { &.character, &.adversary, diff --git a/styles/less/sheets/actors/character/inventory.less b/styles/less/sheets/actors/character/inventory.less index 12f63753..b555aa3d 100644 --- a/styles/less/sheets/actors/character/inventory.less +++ b/styles/less/sheets/actors/character/inventory.less @@ -3,6 +3,47 @@ .application.sheet.daggerheart.actor.dh-style.character { .tab.inventory { + .search-section { + display: flex; + gap: 10px; + align-items: center; + + .search-bar { + position: relative; + color: light-dark(@dark-blue-50, @beige-50); + width: 100%; + padding-top: 5px; + + input { + border-radius: 50px; + background: light-dark(@dark-blue-10, @golden-10); + border: none; + outline: 2px solid transparent; + transition: all 0.3s ease; + padding: 0 20px; + + &:hover { + outline: 2px solid light-dark(@dark, @golden); + } + + &::-webkit-search-cancel-button { + -webkit-appearance: none; + display: none; + } + } + + .icon { + align-content: center; + height: 32px; + position: absolute; + right: 20px; + font-size: var(--font-size-16); + z-index: 1; + color: light-dark(@dark-blue-50, @beige-50); + } + } + } + .items-section { display: flex; flex-direction: column; @@ -14,5 +55,16 @@ scrollbar-width: thin; scrollbar-color: light-dark(@dark-blue, @golden) transparent; } + + .currency-section { + display: grid; + grid-template-columns: 1fr 1fr 1fr 1fr; + gap: 10px; + padding: 10px 10px 0; + + .input { + color: light-dark(@dark, @beige); + } + } } } diff --git a/styles/less/sheets/actors/character/sheet.less b/styles/less/sheets/actors/character/sheet.less index 68792c99..ee6580fd 100644 --- a/styles/less/sheets/actors/character/sheet.less +++ b/styles/less/sheets/actors/character/sheet.less @@ -11,6 +11,21 @@ padding-bottom: 0; overflow-x: auto; + &.viewMode { + button:not(.btn-toggle-view), + input:not(.search), + .controls, + .character-sidebar-sheet, + .img-portait, + .name-row, + .hope-section, + .downtime-section, + .character-traits, + .card-list { + pointer-events: none; + } + } + .character-sidebar-sheet { grid-row: 1 / span 2; grid-column: 1; diff --git a/styles/less/sheets/actors/character/sidebar.less b/styles/less/sheets/actors/character/sidebar.less index b159a8e8..e7027163 100644 --- a/styles/less/sheets/actors/character/sidebar.less +++ b/styles/less/sheets/actors/character/sidebar.less @@ -316,9 +316,9 @@ border-radius: 3px; background: light-dark(@dark-blue, @golden); clip-path: none; + cursor: pointer; display: flex; align-items: center; - justify-content: center; gap: 4px; border: 1px solid transparent; transition: all 0.3s ease; diff --git a/styles/less/sheets/actors/party/inventory.less b/styles/less/sheets/actors/party/inventory.less index ac59e1de..2dcc97d8 100644 --- a/styles/less/sheets/actors/party/inventory.less +++ b/styles/less/sheets/actors/party/inventory.less @@ -3,6 +3,51 @@ .application.sheet.daggerheart.actor.dh-style.party { .tab.inventory { + .search-section { + display: flex; + gap: 10px; + align-items: center; + + .search-bar { + position: relative; + color: light-dark(@dark-blue-50, @beige-50); + width: 100%; + padding-top: 5px; + + input { + border-radius: 50px; + background: light-dark(@dark-blue-10, @golden-10); + border: none; + outline: 2px solid transparent; + transition: all 0.3s ease; + padding: 0 20px; + + &:hover { + outline: 2px solid light-dark(@dark, @golden); + } + + &:placeholder { + color: light-dark(@dark-blue-50, @beige-50); + } + + &::-webkit-search-cancel-button { + -webkit-appearance: none; + display: none; + } + } + + .icon { + align-content: center; + height: 32px; + position: absolute; + right: 20px; + font-size: 16px; + z-index: 1; + color: light-dark(@dark-blue-50, @beige-50); + } + } + } + .items-section { display: flex; flex-direction: column; @@ -14,5 +59,16 @@ scrollbar-width: thin; scrollbar-color: light-dark(@dark-blue, @golden) transparent; } + + .currency-section { + display: grid; + grid-template-columns: 1fr 1fr 1fr 1fr; + gap: 10px; + padding: 10px 10px 0; + + .input { + color: light-dark(@dark, @beige); + } + } } } diff --git a/styles/less/sheets/actors/party/party-members.less b/styles/less/sheets/actors/party/party-members.less index 2e2f4cf8..a433ae34 100644 --- a/styles/less/sheets/actors/party/party-members.less +++ b/styles/less/sheets/actors/party/party-members.less @@ -1,294 +1,28 @@ @import '../../../utils/colors.less'; @import '../../../utils/fonts.less'; -@import '../../../utils/mixin.less'; -body.game:is(.performance-low, .noblur) { - .application.sheet.daggerheart.actor.dh-style.party .tab.resources .actors-list .actor-resources { - background: light-dark(@dark-blue, @dark-golden); +.application.sheet.daggerheart.actor.dh-style.party { + .tab.partyMembers { + max-height: 400px; + overflow: auto; - .actor-name { - background: light-dark(@dark-blue, @dark-golden); + .actors-list { + display: flex; + flex-direction: column; + gap: 10px; + align-items: center; + width: 100%; + } + .actors-dragger { + display: flex; + align-items: center; + justify-content: center; + box-sizing: border-box; + width: 100%; + height: 40px; + border: 1px dashed light-dark(@dark-blue-50, @beige-50); + border-radius: 3px; + color: light-dark(@dark-blue-50, @beige-50); } } } - -.application.sheet.daggerheart.actor.dh-style.party .tab.partyMembers { - overflow: auto; - - .actors-list { - display: flex; - flex-direction: column; - gap: 8px; - align-items: stretch; - width: 100%; - - .actor-resources { - display: grid; - grid-template: - "img header" min-content - "img body" 1fr - / 7.5rem 1fr; - gap: 6px; - column-gap: 12px; - padding: 6px; - background-color: light-dark(@dark-blue-10, @golden-10); - - .actor-img-frame { - grid-area: img; - width: 7.375rem; - height: 7.375rem; - position: relative; - - .actor-img { - object-fit: cover; - object-position: top center; - border-radius: 6px; - width: 100%; - height: 100%; - } - - .equipped-weapons { - position: absolute; - top: -2px; - left: -3px; - display: flex; - flex-direction: column; - gap: 1px; - img { - border-radius: 50%; - width: 24px; - height: 24px; - border: 1px solid light-dark(@dark-blue, @golden); - object-fit: cover; - } - } - - .evasion { - position: absolute; - top: 1px; - right: 1px; - width: 1.75rem; - height: 1.75rem; - background: url('../assets/svg/trait-shield.svg') no-repeat; - background-size: 100%; - color: var(--color-light-1); - font-size: var(--font-size-14); - font-weight: 700; - display: flex; - align-items: center; - justify-content: center; - } - - .threshold-section { - position: absolute; - left: 0; - right: 0; - bottom: -2px; - margin: auto; - - display: flex; - gap: 4px; - background-color: light-dark(var(--color-light-1), @dark-blue); - color: light-dark(@dark-blue, @golden); - padding: 4px 6px; - border: 1px solid light-dark(@dark-blue, @golden); - border-radius: 3px; - align-items: baseline; - width: fit-content; - - h4 { - font-weight: bold; - text-transform: uppercase; - white-space: nowrap; - - &.threshold-label { - font-size: var(--font-size-10); - color: light-dark(@dark-blue, @golden); - } - - &.threshold-value { - font-size: var(--font-size-11); - color: light-dark(@dark, @beige); - } - } - } - } - - header { - grid-area: header; - display: grid; - grid-template: - "name hope" min-content - "subtitle subtitle" min-content - / 1fr min-content; - - .actor-name { - width: 100%; - z-index: 1; - font-size: var(--font-size-20); - color: light-dark(@dark-blue, @golden); - font-weight: bold; - } - - .delete-icon { - font-size: 0.75em; - } - - .subtitle { - grid-area: subtitle; - font-size: var(--font-size-14); - } - - .hope-section { - display: flex; - background-color: light-dark(transparent, @dark-blue); - color: light-dark(@dark-blue, @golden); - padding: 3px 6px; - border: 1px solid light-dark(@dark-blue, @golden); - border-radius: 3px; - align-items: center; - width: fit-content; - margin-left: auto; - - h4 { - font-size: var(--font-size-12); - font-weight: bold; - text-transform: uppercase; - color: light-dark(@dark-blue, @golden); - margin-right: 3px; - } - - .hope-value { - display: flex; - cursor: pointer; - font-size: var(--font-size-12); - margin-left: 1px; - } - } - } - - .body { - grid-area: body; - display: flex; - align-items: start; - justify-content: space-between; - } - - .resources { - display: flex; - flex-direction: column; - gap: 4px; - - .slot-section { - display: flex; - flex-direction: row; - align-items: stretch; - - .slot-label { - display: flex; - align-items: center; - color: light-dark(@beige, @dark-blue); - background: light-dark(@dark-blue, @golden); - padding: 0 4px; - width: fit-content; - font-weight: bold; - border-radius: 6px 0px 0px 6px; - font-size: var(--font-size-12); - white-space: nowrap; - - .label { - padding-right: 2px; - } - - .value { - font-variant-numeric: tabular-nums; - .current { - display: inline-block; - text-align: end; - width: 2ch; - } - .max { - display: inline-block; - text-align: start; - width: 2ch; - } - } - } - - .slot-bar { - display: flex; - align-items: center; - flex-wrap: wrap; - gap: 4px; - - background-color: light-dark(@dark-blue-10, @dark-blue); - color: light-dark(@dark-blue, @golden); - padding: 2px 5px; - border: 1px solid light-dark(@dark-blue, @golden); - border-radius: 0 6px 6px 0; - width: fit-content; - min-height: 22px; - - .armor-slot { - cursor: pointer; - transition: all 0.3s ease; - font-size: var(--font-size-12); - - .fa-shield-halved { - color: light-dark(@dark-blue-40, @golden-40); - } - } - - .slot { - width: 16px; - height: 10px; - border: 1px solid light-dark(@dark-blue, @golden); - background: light-dark(@dark-blue-10, @golden-10); - border-radius: 3px; - transition: all 0.3s ease; - cursor: pointer; - - &.filled { - background: light-dark(@dark-blue, @golden); - } - } - } - } - } - - .traits { - background-color: light-dark(@dark-blue-10, @dark-blue); - border: 1px solid light-dark(@dark-blue, @golden); - border-radius: 6px; - display: grid; - grid-template-columns: 1fr 1fr; - font-size: var(--font-size-12); - padding: 3px 4px; - gap: 3px 7px; - .trait { - display: flex; - justify-content: space-between; - gap: 3px; - .label { - color: light-dark(@dark-blue, @golden); - } - .value { - font-weight: 600; - } - } - } - } - } - - .actors-dragger { - display: flex; - align-items: center; - justify-content: center; - box-sizing: border-box; - width: 100%; - height: 40px; - border: 1px dashed light-dark(@dark-blue-50, @beige-50); - border-radius: 3px; - color: light-dark(@dark-blue-50, @beige-50); - } -} diff --git a/styles/less/sheets/actors/party/resources.less b/styles/less/sheets/actors/party/resources.less new file mode 100644 index 00000000..68628295 --- /dev/null +++ b/styles/less/sheets/actors/party/resources.less @@ -0,0 +1,216 @@ +@import '../../../utils/colors.less'; +@import '../../../utils/fonts.less'; +@import '../../../utils/mixin.less'; + +body.game:is(.performance-low, .noblur) { + .application.sheet.daggerheart.actor.dh-style.party .tab.resources .actors-list .actor-resources { + background: light-dark(@dark-blue, @dark-golden); + + .actor-name { + background: light-dark(@dark-blue, @dark-golden); + } + } +} + +.application.sheet.daggerheart.actor.dh-style.party { + .tab.resources { + overflow: auto; + + .actors-list { + display: flex; + flex-direction: row; + flex-wrap: wrap; + gap: 10px; + align-items: center; + width: 100%; + justify-content: center; + + .actor-resources { + display: flex; + flex-direction: column; + position: relative; + background: light-dark(@dark-blue-40, @dark-golden-40); + border-radius: 6px; + border: 1px solid light-dark(@dark-blue, @golden); + width: 230px; + height: -webkit-fill-available; + + .actor-name { + position: absolute; + top: 0px; + background: light-dark(@dark-blue-90, @dark-golden-80); + backdrop-filter: blur(6.5px); + border-radius: 6px 6px 0px 0px; + text-align: center; + width: 100%; + z-index: 1; + font-size: var(--font-size-20); + color: light-dark(@beige, @golden); + font-weight: bold; + padding: 5px 0; + } + + .actor-img { + height: 150px; + object-fit: cover; + object-position: top center; + border-radius: 6px 6px 0px 0px; + mask-image: linear-gradient(180deg, black 88%, transparent 100%); + } + + .resources { + display: flex; + flex-direction: column; + gap: 10px; + align-items: center; + margin: 10px; + + .slot-section { + display: flex; + flex-direction: column; + align-items: center; + + .slot-bar { + display: flex; + flex-wrap: wrap; + gap: 5px; + width: 239px; + + background-color: light-dark(@dark-blue-10, @dark-blue); + color: light-dark(@dark-blue, @golden); + padding: 5px; + border: 1px solid light-dark(@dark-blue, @golden); + border-radius: 6px; + width: fit-content; + + .armor-slot { + cursor: pointer; + transition: all 0.3s ease; + font-size: var(--font-size-12); + + .fa-shield-halved { + color: light-dark(@dark-blue-40, @golden-40); + } + } + + .slot { + width: 20px; + height: 10px; + border: 1px solid light-dark(@dark-blue, @golden); + background: light-dark(@dark-blue-10, @golden-10); + border-radius: 3px; + transition: all 0.3s ease; + cursor: pointer; + + &.filled { + background: light-dark(@dark-blue, @golden); + } + } + } + .slot-label { + display: flex; + align-items: center; + color: light-dark(@beige, @dark-blue); + background: light-dark(@dark-blue, @golden); + padding: 0 5px; + width: fit-content; + font-weight: bold; + border-radius: 0px 0px 5px 5px; + font-size: var(--font-size-12); + + .label { + padding-right: 5px; + } + + .value { + padding-left: 6px; + border-left: 1px solid light-dark(@beige, @dark-golden); + } + } + } + + .hope-section { + position: relative; + display: flex; + gap: 10px; + background-color: light-dark(transparent, @dark-blue); + color: light-dark(@dark-blue, @golden); + padding: 5px 10px; + border: 1px solid light-dark(@dark-blue, @golden); + border-radius: 3px; + align-items: center; + width: fit-content; + + h4 { + font-size: var(--font-size-12); + font-weight: bold; + text-transform: uppercase; + color: light-dark(@dark-blue, @golden); + } + + .hope-value { + display: flex; + cursor: pointer; + font-size: var(--font-size-12); + } + } + + .stat-section { + position: relative; + display: flex; + gap: 10px; + background-color: light-dark(transparent, @dark-blue); + color: light-dark(@dark-blue, @golden); + padding: 5px 10px; + border: 1px solid light-dark(@dark-blue, @golden); + border-radius: 3px; + align-items: center; + width: fit-content; + + h4 { + font-size: var(--font-size-12); + font-weight: bold; + text-transform: uppercase; + color: light-dark(@dark-blue, @golden); + } + } + + .threshold-section { + display: flex; + align-self: center; + gap: 10px; + background-color: light-dark(transparent, @dark-blue); + color: light-dark(@dark-blue, @golden); + padding: 5px 10px; + border: 1px solid light-dark(@dark-blue, @golden); + border-radius: 3px; + align-items: center; + width: fit-content; + + h4 { + font-size: var(--font-size-12); + font-weight: bold; + text-transform: uppercase; + color: light-dark(@dark-blue, @golden); + + &.threshold-value { + color: light-dark(@dark, @beige); + } + } + } + } + } + } + .actors-dragger { + display: flex; + align-items: center; + justify-content: center; + box-sizing: border-box; + width: 100%; + height: 40px; + border: 1px dashed light-dark(@dark-blue-50, @beige-50); + border-radius: 3px; + color: light-dark(@dark-blue-50, @beige-50); + } + } +} diff --git a/styles/less/sheets/index.less b/styles/less/sheets/index.less index 7d595614..e5ffbf3e 100644 --- a/styles/less/sheets/index.less +++ b/styles/less/sheets/index.less @@ -31,6 +31,7 @@ @import './actors/party/party-members.less'; @import './actors/party/sheet.less'; @import './actors/party/inventory.less'; +@import './actors/party/resources.less'; @import './items/beastform.less'; @import './items/class.less'; diff --git a/styles/less/ui/chat/chat.less b/styles/less/ui/chat/chat.less index 4d627e39..db6dceb9 100644 --- a/styles/less/ui/chat/chat.less +++ b/styles/less/ui/chat/chat.less @@ -624,14 +624,9 @@ display: flex; gap: 5px; margin-top: 8px; - button { height: 32px; flex: 1; - - &.end-button { - flex: 0; - } } } @@ -703,11 +698,6 @@ } } - .action-roll-buttons { - width: 100%; - padding: 0 8px; - } - .description { padding: 8px; diff --git a/styles/less/ui/combat-sidebar/encounter-controls.less b/styles/less/ui/combat-sidebar/encounter-controls.less index 66f265e0..16a8e11a 100644 --- a/styles/less/ui/combat-sidebar/encounter-controls.less +++ b/styles/less/ui/combat-sidebar/encounter-controls.less @@ -10,7 +10,6 @@ .encounter-battlepoints { display: flex; cursor: help; - color: light-dark(@dark, @beige); } .inner-controls { diff --git a/styles/less/ui/settings/appearance-settings/diceSoNice.less b/styles/less/ui/settings/appearance-settings/diceSoNice.less index a4846596..079bebc5 100644 --- a/styles/less/ui/settings/appearance-settings/diceSoNice.less +++ b/styles/less/ui/settings/appearance-settings/diceSoNice.less @@ -68,29 +68,5 @@ text-align: center; white-space: nowrap; } - - color-picker { - gap: 4px; - background: inherit; - } - } - - .animation-container { - display: flex; - align-items: center; - justify-content: space-between; - - .animation-inner-container { - display: flex; - align-items: center; - justify-content: right; - gap: 8px; - - .animation-control { - display: flex; - align-items: center; - gap: 2px; - } - } } } diff --git a/system.json b/system.json index babdde26..28d849b3 100644 --- a/system.json +++ b/system.json @@ -2,15 +2,12 @@ "id": "daggerheart", "title": "Daggerheart", "description": "An unofficial implementation of the Daggerheart system", - "version": "2.1.2", + "version": "2.0.3", "compatibility": { "minimum": "14.359", - "verified": "14.360", + "verified": "14.359", "maximum": "14" }, - "url": "https://github.com/Foundryborne/daggerheart", - "manifest": "https://raw.githubusercontent.com/Foundryborne/daggerheart/v14/system.json", - "download": "https://github.com/Foundryborne/daggerheart/releases/download/2.1.2/system.zip", "authors": [ { "name": "WBHarry" @@ -293,10 +290,14 @@ "damageRoll": {}, "abilityUse": {}, "tagTeam": {}, + "groupRoll": {}, "systemMessage": {} } }, "background": "systems/daggerheart/assets/logos/FoundrybornBackgroundLogo.png", "primaryTokenAttribute": "resources.hitPoints", - "secondaryTokenAttribute": "resources.stress" + "secondaryTokenAttribute": "resources.stress", + "url": "https://github.com/Foundryborne/daggerheart", + "manifest": "https://raw.githubusercontent.com/Foundryborne/daggerheart/main/system.json", + "download": "https://github.com/Foundryborne/daggerheart/releases/download/2.0.3/system.zip" } diff --git a/templates/actionTypes/areas.hbs b/templates/actionTypes/areas.hbs deleted file mode 100644 index 2e010c72..00000000 --- a/templates/actionTypes/areas.hbs +++ /dev/null @@ -1,46 +0,0 @@ -
- - {{localize "DAGGERHEART.ACTIONS.Config.area.sectionTitle"}} - - - - {{#each source as |area index|}} - {{#unless @first}}{{/unless}} -
- {{formField ../fields.name value=area.name name=(concat "areas." index ".name") localize=true}} - -
-
- {{formField ../fields.type value=area.type name=(concat "areas." index ".type") localize=true}} - {{formField ../fields.shape value=area.shape name=(concat "areas." index ".shape") localize=true}} - {{formField ../fields.size value=area.size name=(concat "areas." index ".size") localize=true}} -
- -
- {{localize "DAGGERHEART.GENERAL.Effect.plural"}} - -
-
- {{#each area.effects as |effectId index|}} - - -
-
- {{#with (@root.getEffectDetails effectId) as | details |}} -
- -
-
-
{{name}}
-
- {{/with}} -
- -
-
-
- {{/each}} -
- {{/each}} - -
\ No newline at end of file diff --git a/templates/actionTypes/damage.hbs b/templates/actionTypes/damage.hbs index 454d0413..9e7c2884 100644 --- a/templates/actionTypes/damage.hbs +++ b/templates/actionTypes/damage.hbs @@ -8,20 +8,17 @@ {{/if}} {{#unless (eq path 'system.attack.')}}{{/unless}} -
+
{{#if @root.hasBaseDamage}} {{formField @root.fields.damage.fields.includeBase value=@root.source.damage.includeBase name="damage.includeBase" classes="checkbox" localize=true }} {{/if}} {{#unless (eq @root.source.type 'healing')}} - {{formField baseFields.direct value=source.direct name=(concat path "damage.direct") localize=true classes="checkbox"}} + {{formField directField value=source.direct name=(concat path "damage.direct") localize=true classes="checkbox"}} {{/unless}} - {{#if (and @root.isNPC (not (eq path 'system.attack.')))}} - {{formField baseFields.groupAttack value=source.groupAttack name=(concat path "damage.groupAttack") localize=true classes="select"}} - {{/if}}
{{!-- Handlebars uses Symbol.Iterator to produce index|key. This isn't compatible with our parts object, so we instead use applyTo, which is the same value --}} - {{#each source.parts as |dmg key|}} + {{#each source.parts as |dmg|}}
@@ -31,44 +28,40 @@ {{/unless}} - {{#unless (and @root.source.damage.includeBase (eq key 'hitPoints'))}} - {{#if (and (not @root.isNPC) @root.hasRoll (not dmg.base))}} - {{formField ../fields.resultBased value=dmg.resultBased name=(concat "damage.parts." dmg.applyTo ".resultBased") localize=true classes="checkbox"}} - {{/if}} - {{#if (and (not @root.isNPC) @root.hasRoll (not dmg.base) dmg.resultBased)}} -
-
- {{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.hope")}} - {{> formula fields=../fields.value.fields type=../fields.type dmg=dmg source=dmg.value target="value" key=dmg.applyTo path=../path}} -
-
- {{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.fear")}} - {{> formula fields=../fields.valueAlt.fields type=../fields.type dmg=dmg source=dmg.valueAlt target="valueAlt" key=dmg.applyTo path=../path}} -
-
- {{else}} - {{> formula fields=../fields.value.fields type=../fields.type dmg=dmg source=dmg.value target="value" key=dmg.applyTo path=../path}} - {{/if}} - - {{#if (and (eq dmg.applyTo 'hitPoints') (ne @root.source.type 'healing'))}} - {{formField ../fields.type value=dmg.type name=(concat ../path "damage.parts." dmg.applyTo ".type") localize=true}} - {{/if}} - - {{#if ../horde}} + {{#if (and (not @root.isNPC) @root.hasRoll (not dmg.base))}} + {{formField ../fields.resultBased value=dmg.resultBased name=(concat "damage.parts." dmg.applyTo ".resultBased") localize=true classes="checkbox"}} + {{/if}} + {{#if (and (not @root.isNPC) @root.hasRoll (not dmg.base) dmg.resultBased)}} +
- {{localize "DAGGERHEART.ACTORS.Adversary.hordeDamage"}} -
- - {{formField ../fields.valueAlt.fields.flatMultiplier value=dmg.valueAlt.flatMultiplier name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.flatMultiplier") label="DAGGERHEART.ACTIONS.Settings.multiplier" classes="inline-child" localize=true }} - {{formField ../fields.valueAlt.fields.dice value=dmg.valueAlt.dice name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.dice") classes="inline-child" localize=true}} - {{formField ../fields.valueAlt.fields.bonus value=dmg.valueAlt.bonus name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.bonus") localize=true classes="inline-child"}} -
+ {{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.hope")}} + {{> formula fields=../fields.value.fields type=../fields.type dmg=dmg source=dmg.value target="value" key=dmg.applyTo path=../path}}
- {{/if}} - +
+ {{localize "DAGGERHEART.GENERAL.withThing" thing=(localize "DAGGERHEART.GENERAL.fear")}} + {{> formula fields=../fields.valueAlt.fields type=../fields.type dmg=dmg source=dmg.valueAlt target="valueAlt" key=dmg.applyTo path=../path}} +
+
{{else}} - {{localize "DAGGERHEART.ACTIONS.Config.itemDamageIsUsed"}} - {{/unless}} + {{> formula fields=../fields.value.fields type=../fields.type dmg=dmg source=dmg.value target="value" key=dmg.applyTo path=../path}} + {{/if}} + + {{#if (and (eq dmg.applyTo 'hitPoints') (ne @root.source.type 'healing'))}} + {{formField ../fields.type value=dmg.type name=(concat ../path "damage.parts." dmg.applyTo ".type") localize=true}} + {{/if}} + + {{#if ../horde}} +
+ {{localize "DAGGERHEART.ACTORS.Adversary.hordeDamage"}} +
+ + {{formField ../fields.valueAlt.fields.flatMultiplier value=dmg.valueAlt.flatMultiplier name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.flatMultiplier") label="DAGGERHEART.ACTIONS.Settings.multiplier" classes="inline-child" localize=true }} + {{formField ../fields.valueAlt.fields.dice value=dmg.valueAlt.dice name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.dice") classes="inline-child" localize=true}} + {{formField ../fields.valueAlt.fields.bonus value=dmg.valueAlt.bonus name=(concat ../path "damage.parts." dmg.applyTo ".valueAlt.bonus") localize=true classes="inline-child"}} +
+
+ {{/if}} +
{{/each}} diff --git a/templates/actionTypes/range-target.hbs b/templates/actionTypes/range-target.hbs index ec595df4..114c76a6 100644 --- a/templates/actionTypes/range-target.hbs +++ b/templates/actionTypes/range-target.hbs @@ -1,14 +1,12 @@
{{localize "DAGGERHEART.GENERAL.range"}}{{#if fields.target}} & {{localize "DAGGERHEART.GENERAL.Target.single"}}{{/if}} + {{formField fields.range value=source.range label=(localize "DAGGERHEART.GENERAL.range") name=(concat path "range") localize=true}} {{#if fields.target}} -
- {{formField fields.range value=source.range label=(localize "DAGGERHEART.GENERAL.range") name=(concat path "range") localize=true}} - {{#if (and source.target.type (not (eq source.target.type 'self')))}} - {{ formField fields.target.amount value=source.target.amount label=(localize "DAGGERHEART.GENERAL.amount") name=(concat path "target.amount") localize=true}} - {{/if}} - {{ formField fields.target.type value=source.target.type label=(localize "DAGGERHEART.GENERAL.Target.single") name=(concat path "target.type") localize=true }} -
- {{else}} - {{formField fields.range value=source.range label=(localize "DAGGERHEART.GENERAL.range") name=(concat path "range") localize=true}} +
+ {{#if (and source.target.type (not (eq source.target.type 'self')))}} + {{ formField fields.target.amount value=source.target.amount label=(localize "DAGGERHEART.GENERAL.amount") name=(concat path "target.amount") localize=true}} + {{/if}} + {{ formField fields.target.type value=source.target.type label=(localize "DAGGERHEART.GENERAL.Target.single") name=(concat path "target.type") localize=true }} +
{{/if}}
\ No newline at end of file diff --git a/templates/actionTypes/roll.hbs b/templates/actionTypes/roll.hbs index 41f88ba2..9784fc08 100644 --- a/templates/actionTypes/roll.hbs +++ b/templates/actionTypes/roll.hbs @@ -1,7 +1,7 @@
- {{localize "DAGGERHEART.GENERAL.roll"}} - {{#if @root.hasBaseDamage}}{{formInput fields.useDefault name="roll.useDefault" value=source.useDefault dataset=(object tooltip=(localize "DAGGERHEART.ACTIONS.Config.useDefaultItemValues") tooltipDirection="UP")}}{{/if}} + Roll + {{#if @root.hasBaseDamage}}{{formInput fields.useDefault name="roll.useDefault" value=source.useDefault dataset=(object tooltip="Use default Item values" tooltipDirection="UP")}}{{/if}} {{formField fields.type label="DAGGERHEART.GENERAL.type" name="roll.type" value=source.type localize=true choices=@root.getRollTypeOptions localize=true}} diff --git a/templates/characterCreation/footer.hbs b/templates/characterCreation/footer.hbs index 51eef110..95b86cfb 100644 --- a/templates/characterCreation/footer.hbs +++ b/templates/characterCreation/footer.hbs @@ -1,8 +1,8 @@ \ No newline at end of file diff --git a/templates/characterCreation/tabs/experience.hbs b/templates/characterCreation/tabs/experience.hbs index 66363084..3eb92834 100644 --- a/templates/characterCreation/tabs/experience.hbs +++ b/templates/characterCreation/tabs/experience.hbs @@ -4,25 +4,17 @@ data-group='{{tabs.experience.group}}' >
-
+
{{localize "DAGGERHEART.APPLICATIONS.CharacterCreation.initialExperiences"}} {{experience.nrSelected}}/{{experience.nrTotal}}
{{#each experience.values as |experience id|}} -
-
- -
- - {{numberFormat this.value sign=true}} -
+
+
+ + {{numberFormat this.value sign=true}}
-
- -
- -
-
+
{{/each}}
diff --git a/templates/dialogs/characterReset.hbs b/templates/dialogs/characterReset.hbs index 0bd54f7c..298826e5 100644 --- a/templates/dialogs/characterReset.hbs +++ b/templates/dialogs/characterReset.hbs @@ -28,6 +28,6 @@
- +
\ No newline at end of file diff --git a/templates/dialogs/compendiumBrowserSettingsDialog/footer.hbs b/templates/dialogs/compendiumBrowserSettingsDialog/footer.hbs index d9bb378e..9dc61cbe 100644 --- a/templates/dialogs/compendiumBrowserSettingsDialog/footer.hbs +++ b/templates/dialogs/compendiumBrowserSettingsDialog/footer.hbs @@ -1,3 +1,3 @@ \ No newline at end of file diff --git a/templates/dialogs/deathMove.hbs b/templates/dialogs/deathMove.hbs index 97900022..341659df 100644 --- a/templates/dialogs/deathMove.hbs +++ b/templates/dialogs/deathMove.hbs @@ -17,7 +17,7 @@ \ No newline at end of file diff --git a/templates/ui/chat/action.hbs b/templates/ui/chat/action.hbs index 51840363..2854795c 100644 --- a/templates/ui/chat/action.hbs +++ b/templates/ui/chat/action.hbs @@ -26,9 +26,4 @@ {{/if}} - {{#if action.areas.length}} -
- -
- {{/if}} \ No newline at end of file diff --git a/templates/ui/chat/parts/button-part.hbs b/templates/ui/chat/parts/button-part.hbs index 6bc5f372..21317939 100644 --- a/templates/ui/chat/parts/button-part.hbs +++ b/templates/ui/chat/parts/button-part.hbs @@ -1,5 +1,4 @@
- {{#if areas.length}}{{/if}} {{#if hasDamage}} {{#unless (empty damage)}} diff --git a/templates/ui/chat/parts/damage-part.hbs b/templates/ui/chat/parts/damage-part.hbs index 45b09b72..02519a86 100644 --- a/templates/ui/chat/parts/damage-part.hbs +++ b/templates/ui/chat/parts/damage-part.hbs @@ -33,32 +33,31 @@
{{total}}
{{/if}}
- {{#if dice.length}} - {{#each dice}} - {{#each results}} - {{#unless discarded}} -
-
- {{#if hasRerolls}}{{/if}} - {{result}} -
+ {{#each dice}} + {{#each results}} + {{#unless discarded}} +
+
+ {{#if hasRerolls}}{{/if}} + {{result}}
- {{/unless}} - {{/each}} +
+ {{/unless}} {{/each}} - {{#if modifierTotal}} -
-
{{modifierTotal}}
-
- {{/if}} - {{else}} + {{/each}} + {{#if modifierTotal}} +
+
{{modifierTotal}}
+
+ {{/if}} + {{#unless dice.length}}
{{total}}
- {{/if}} + {{/unless}}
{{/each}} diff --git a/templates/ui/chat/parts/target-part.hbs b/templates/ui/chat/parts/target-part.hbs index 88d337ac..9a545926 100644 --- a/templates/ui/chat/parts/target-part.hbs +++ b/templates/ui/chat/parts/target-part.hbs @@ -24,7 +24,7 @@
{{/if}} - {{#if (and hasSave currentTargets.length)}}
{{localize "DAGGERHEART.UI.Chat.saveRoll.reactionRollAllTargets"}}
{{/if}} + {{#if (and hasSave currentTargets.length)}}
Reaction Roll All Targets
{{/if}} {{#each currentTargets}}
diff --git a/templates/ui/itemBrowser/itemBrowser.hbs b/templates/ui/itemBrowser/itemBrowser.hbs index d4946c1f..137693fc 100644 --- a/templates/ui/itemBrowser/itemBrowser.hbs +++ b/templates/ui/itemBrowser/itemBrowser.hbs @@ -1,14 +1,14 @@
{{#if menu.path.length }}
@@ -17,7 +17,7 @@
- +
diff --git a/templates/ui/sidebar/actor-document-partial.hbs b/templates/ui/sidebar/actor-document-partial.hbs index 2a9f47fa..ec261f85 100644 --- a/templates/ui/sidebar/actor-document-partial.hbs +++ b/templates/ui/sidebar/actor-document-partial.hbs @@ -14,10 +14,6 @@ {{else}} {{localize "DAGGERHEART.UI.Sidebar.actorDirectory.companionNoPartner"}} {{/if}} - {{else if (eq type "party")}} - {{#if system.active}} - {{localize "DAGGERHEART.UI.Sidebar.actorDirectory.partyIsActive"}} - {{/if}} {{/if}} diff --git a/templates/ui/tooltip/action.hbs b/templates/ui/tooltip/action.hbs index 959188f3..29d44dde 100644 --- a/templates/ui/tooltip/action.hbs +++ b/templates/ui/tooltip/action.hbs @@ -16,7 +16,7 @@ {{#if (gt item.cost.length 0)}} {{#each item.cost as | cost |}}
- {{localize "DAGGERHEART.GENERAL.type"}} {{#with (lookup @root.config.GENERAL.abilityCosts cost.type) as | type |}}{{localize type.label}}{{/with}} + {{localize "Type"}} {{#with (lookup @root.config.GENERAL.abilityCosts cost.type) as | type |}}{{localize type.label}}{{/with}}
{{localize "DAGGERHEART.GENERAL.value"}} {{cost.value}} diff --git a/templates/ui/tooltip/adversary.hbs b/templates/ui/tooltip/adversary.hbs index f96fe2a0..bba7e696 100644 --- a/templates/ui/tooltip/adversary.hbs +++ b/templates/ui/tooltip/adversary.hbs @@ -11,7 +11,7 @@ {{/with}}
- + {{#with (lookup adversaryTypes item.system.type) as | type |}}
{{localize type.label}}
{{/with}} diff --git a/templates/ui/tooltip/battlepoints.hbs b/templates/ui/tooltip/battlepoints.hbs index f2f42f53..d793fe8c 100644 --- a/templates/ui/tooltip/battlepoints.hbs +++ b/templates/ui/tooltip/battlepoints.hbs @@ -1,15 +1,15 @@
-

{{localize "DAGGERHEART.GENERAL.Adversary.plural"}} ({{currentBP}}/{{maxBP}})

+

{{localize "Adversaries"}} ({{currentBP}}/{{maxBP}})

{{#each categories as |category key|}} {{#each category as |grouping index|}}
{{#if grouping.nr}} - + {{else}} - + {{/if}}
{{/each}} @@ -17,7 +17,7 @@
-

{{localize "DAGGERHEART.GENERAL.Modifier.plural"}}

+

{{localize "Modifiers"}}

{{#each toggles as |toggle|}}
@@ -26,7 +26,7 @@ {{else}} {{/if}} - +
{{/each}}
diff --git a/templates/ui/tooltip/weapon.hbs b/templates/ui/tooltip/weapon.hbs index 4adb9c46..a672c883 100644 --- a/templates/ui/tooltip/weapon.hbs +++ b/templates/ui/tooltip/weapon.hbs @@ -3,7 +3,7 @@

{{item.name}}

- {{#if item.system.secondary}}{{localize "DAGGERHEART.ITEMS.Weapon.secondaryWeapon.full"}}{{else}}{{localize "DAGGERHEART.ITEMS.Weapon.primaryWeapon.full"}}{{/if}} + {{#if item.system.secondary}}{{localize "DAGGERHEART.ITEMS.Weapon.secondaryWeapon"}}{{else}}{{localize "DAGGERHEART.ITEMS.Weapon.primaryWeapon"}}{{/if}}
{{#with (lookup config.GENERAL.burden item.system.burden) as | burden |}} diff --git a/tools/pullYMLtoLDB.mjs b/tools/pullYMLtoLDB.mjs index 52b7db94..2326d94a 100644 --- a/tools/pullYMLtoLDB.mjs +++ b/tools/pullYMLtoLDB.mjs @@ -1,12 +1,12 @@ import { compilePack } from '@foundryvtt/foundryvtt-cli'; import readline from 'node:readline/promises'; import { promises as fs } from 'fs'; -import systemJSON from '../system.json' with { type: 'json' }; +import systemJSON from "../system.json" with { type: "json" }; const MODULE_ID = process.cwd(); const answer = await (async () => { - if (process.argv.includes('--build')) return 'overwrite'; + if (process.argv.includes("--build")) return "overwrite"; const rl = readline.createInterface({ input: process.stdin, @@ -42,8 +42,8 @@ async function pullToLDB() { function transformEntry(entry) { const stats = { coreVersion: systemJSON.compatibility.minimum, - systemId: 'daggerheart', - systemVersion: systemJSON.version + systemId: "daggerheart", + systemVersion: systemJSON.version, }; entry._stats = { ...stats }; diff --git a/tools/pushLDBtoYML.mjs b/tools/pushLDBtoYML.mjs index 99f84fd7..a113caec 100644 --- a/tools/pushLDBtoYML.mjs +++ b/tools/pushLDBtoYML.mjs @@ -23,7 +23,7 @@ for (const pack of packs) { await extractPack(`${MODULE_ID}/${pack}`, `${MODULE_ID}/src/${pack}`, { yaml, transformName, - transformEntry + transformEntry, }); } /** @@ -45,12 +45,12 @@ function transformEntry(entry) { delete entry._stats; for (const effect of entry.effects ?? []) { - effect._stats = prune(effect._stats); + effect._stats = prune(effect._stats) } for (const item of entry.items ?? []) { item._stats = prune(item._stats); for (const effect of item.effects ?? []) { - effect._stats = prune(effect._stats); + effect._stats = prune(effect._stats) } } }