AVestedInterest

u/AVestedInterest





r/FoundryVTT•

I wrote a macro that's supposed to add light emissions to a bunch of tokens at once, but I can't get it to activate with the right animation. Help?

(async () => {
const actorName = "Magic Pillar";
const lightSettings = {
    dim: 50,
    bright: 0,
    angle: 360,
    color: "#e45cff",
    alpha: 0.25,
    priority: 0,
    luminosity: 0,
    animation: {
        type: "EnergyField",
        speed: 5,
        intensity:
    }
};

const actor = game.actors.getName(actorName);

if (!actor) {
    ui.notifications.warn(`Actor "${actorName}" not found.`);
    return;
}

   const tokens = actor.getActiveTokens(
35