Open Jagusti opened 1 year ago
Add Toolkit option to check and offer offer to toggle visibility of newly installed modules on load
This might need a cunning / laborious hack, as there's no record of newly installed modules.
If instead I can intercept a save operation on the Module Management form app, ...
(maybe in or around ModuleManagement._updateObject
or SettingsConfig.reloadConfirm
)
... then I can retrieve the checked list of modules using
ModuleManagement.prototype.getData().modules.filter(m => m.active)
... and compare it with the actually active list of modules using
game.modules.filter(m => m.active)
If there's a meaningful difference, I can set a temporary world flag which I check on reload to prompt the GM about toggling compendium visibility. Once confirmed (either way), I can delete the flag.
There may be some benefit to using the hasPacks
property to determine a meaningful difference, as I only really care about those modules with compendia.
ModuleManagement.prototype.getData().modules.filter(m => m.active && m.hasPacks)
Context
Toggle Compendium Pack Visibility
What is the motivation or use case?
The
Toggle Compendium Pack Visibility
macro script can be manually adjusted to restrict to packs from specific sources and/or package types. This change would provide a user interface to make it easier to select or specify constraints and configurations.From v11, it is also possible to fallback to a defined default ownership configuration, which may be used to quickly reset changes.
What do you expect to happen?
DOCUMENT_OWNERSHIP_LEVELS
LIMITED
for non-GM users andOWNER
for GM usersReset
option to set to Default Pack Ownership settingsToggle
option to switch between Limited and Observer for selected packs and rolespackage type
(eg, "Actor","Item", "JournalEntry", "Scene", "Macro")sources
, eitherAdditional context
This probably won't be backwards compatible prior to v11.
References
Spun out of #225