#Custom Documents
1 messages · Page 1 of 1 (latest)
Isn't that kinda what Stairways does? (https://foundryvtt.com/packages/stairways)
Creating custom documents that get stored and distributed to all clients?
Stairways (Teleporter), a Module available for Foundry Virtual Tabletop
I've spent all of about 30 seconds looking at it, but it looks like it might be embedding the custom document type in the existing Scene documents.
So, it's not actually storing custom documents, it's writing data to Scenes and letting the Scene document store the data
At which point, it's just a fancy wrapper around an object being stuck into an existing Document
Yeah, looks like it's storing data in flags and then pulling it out into the scene's data scope as-needed
scene.stairways = foundry.utils.duplicate(scene.flags.stairways || []) (which is ultimately called from a setup hook)
Interesting...