foundryvtt-gmScreen
foundryvtt-gmScreen copied to clipboard
v11 RollTables fix
The current GmScreen almost works as-is on v11. The only issue I found was with RollTables, which don't render properly. This is caused by three things:
-
getData
is now async, so it always returns a promise -
TextEditor.enrichHTML
is now async by default, but you can pass it a flag to make it sync -
CONST.TABLE_RESULT_TYPES
no longer has theENTITY
type, but instead aDOCUMENT
type
This PR fixes these issues and allows RollTables to be rendered correctly on the GmScreen. Also, the activateListeners
of the RollTable must be overriden, as it tries to set attributes of elements that do not exist. It does not stop rendering, but floods the console with error logs.
Let me know if you're fine with having a direct bump to v11 that doesn't work in v10, or if you'd rather have a check that changes the behavior depending on the detected version