Repository navigation
What's Changed
This is a big refactor of the codebase. There's no new user-facing features added, but background fixes (quite a few) are noted below
Breaking Changes
- Min system compatibility bumped to 4.3.0 and Foundry v13 to help cleanup
- Combat Tracking Groups support formally dropped, notable the dropped
createSavedMobsFromCTGgroupsfunction
Non-Breaking Changes
- Loading a saved mob fires the
matMobUpdatehook (typeload) like the other mob events; the oldmobUpdatehook still fires but is deprecated
Fix List
- dnd5e 5.1+ / 6.0: spell preparation read from
system.method. 0.19.0 readpreparation.mode, which 6.0 removed, so leveled spells broke attack detection - Foundry 13+: attacking with a loaded saved mob rolled nothing. 0.19.0's attack code read the mob's actors from a property only the old V1 dialog set
- dnd5e 6.0: damage cards list only the target their attacks hit. 0.19.0 wrote targets to
flags.dnd5e.targets, which 6.0 ignores - Exported macros work when a weapon was renamed or added on an unlinked token; missing weapons are skipped with a warning
- Exporting a macro whose name contains quotes no longer breaks the name field or overwrite prompt
- Saved mobs containing a deleted actor no longer crash the dialog
- Targeting a token whose actor has been deleted no longer throws when Multilevel Tokens isn't installed
- Mobs with more hits than attacking tokens (e.g. multiattack) no longer throw in Automated Animations or midi-qol On Use macros. 0.19.0's token loop read one past the end of the list
- Automated Animations no longer gets an undefined target in mob-rules mode when nothing is targeted
- Weapons with several attack activities use the first one that deals damage
- Dice So Nice is restored after every mob attack. With the module's Dice So Nice setting off, an attack with no hits (or one that errored) left every later 3D roll in the world hidden, and a second weapon's damage showed 3D dice
- midi-qol On Use macros receive the attack's advantage/disadvantage; an On Use macro that throws is reported instead of aborting the rest of the attack
MobAttacks.saveMob()keeps the open dialog's checkbox and attack count edits- Selected tokens whose actor was deleted are ignored instead of breaking the dialog and macros
- Exported macros roll a weapon found under a different item id (e.g. a same-named item on another token) instead of throwing
- Mob dialog: exporting with no weapon checked warns instead of throwing; the exported macro uses the loaded mob's token count; Previous/Next and deleting a mob only load your own saved mobs; raising a monster count adds the token's actor; the save-mob overwrite prompt escapes the name
- Turning off the module's Dice So Nice setting now hides a mob attack's 3D damage dice for players' attacks too, without hiding other rolls made during the attack
- Multilevel Tokens clones are recognized again (they have had their own actor since Foundry 11): a clone and its source count as one target, attacks use the source's AC, and damage cards name the source token, which takes the damage
- Deselecting every token with the dialog open no longer reselects the saved mob. The dialog now falls back to your first saved mob only when it opens with nothing selected; later re-renders (deselecting tokens, deleting the loaded mob through
MobAttacks.deleteSavedMob()) show the actual selection. This completes the move to the V2 dialog in 0.19.0, whose fallback re-selected the mob on every render - A world where 3D dice stayed hidden after an interrupted mob attack (or a 0.19.0 attack that hit nothing) shows them again once the GM loads it
- Foundry 14: individual attack rolls' 3D dice are shown to other players again for public rolls (Foundry 14 moved the roll mode to the message mode setting)
- With "show individual damage rolls" on, a weapon's versatile entry rolls its two-handed damage instead of the one-handed die
- midi-qol On Use world macros receive their data as
args[0], as midi-qol passes it (macros written for midi-qol failed onargs)
Full Changelog: 0.19.0...0.20.0