foundryvtt / foundryvtt-premium-content

Public issue tracking for feature requests and bug reports related to first-party premium content for Foundry Virtual Tabletop.

Home Page:https://foundryvtt.com/packages/premium

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

[Bug]: Deadtide for Otari Macro not updating landing and otari scenes with lights

Sadert opened this issue · comments

What happened?

Deadtide for Otari macro:
const playlist = game.playlists.getName("Musical Stings");
const sound = playlist.sounds.getName("Imminent Danger");
const light1 = canvas.scene.lights.get("OjJ1RGGXvWbptPi3");
const light2 = canvas.scene.lights.get("3GO1CvMROPZBzeKH");

if (sound) await playlist.playSound(sound);
if (light1) await light1.update({hidden: !light1.data.hidden})
if (light2) await light2.update({hidden: !light2.data.hidden})

Sounds works, constant lights do not.

What package are you reporting this for?

Pathfinder: Abomination Vaults

Version

3.1.2

Relevant log output

Uncaught (in promise) TypeError: Cannot read properties of undefined (reading 'hidden')
    at MacroPF2e.eval (eval at #executeScript (foundry.js:19867:16), <anonymous>:9:59)
commented

Thank you for the report - this should be fixed in 3.1.3 along with all the rest of the broken macros!