Roll20 uses cookies to improve your experience on our site. Cookies enable you to enjoy certain features, social sharing functionality, and tailor message and display ads to your interests on our site and others. They also help us understand how our site is being used. By continuing to use our site, you consent to our use of cookies. Update your cookie preferences .
×

[Script] Gaslight — Per-Player Token Illusions

1782859023

Edited 1782859365
Aerotech
Pro
API Scripter
Gaslight — Per-Player Token Illusions Different players. Same token. Different reality. The Problem You've built the perfect encounter. The monster manifests as each player's greatest fear — the fighter sees a lich, the wizard sees their dead mentor, the rogue sees a locked door they can't pick. You set it all up. You tested it with alt accounts. It seemed to work. Session night. It does not work. Not even a little bit. Turns out, making one token look different to each player on Roll20 is... not easy. Your options are: run a separate map for each player (nightmare), use theater of the mind (defeats the point of a VTT), or give up on the idea entirely. Most GMs give up. Or maybe you want actual stealth. Not " Markos' passive perception is 22, so now everyone sees the assassin sneaking up on them " stealth. Real stealth — where Markos' player, Zack, can see the hidden assassin (because their passive perception beats it) and Rhea's player, Wyatt, literally cannot. The token isn't there for them. They don't know it exists. And when Zack says "What the heck is that?!" and Wyatt responds with "What the heck is what?! ", then you know you've got a wonderful game ahead of you. Man, if only something like that were possible... The Solution Gaslight creates per-player illusions on tokens. Each player can see a different image, name, bar values, aura — anything — on the same token, while the GM sees the truth. One creature, multiple realities. Under the hood, Gaslight gives each player their own page with mirrored tokens. Changes to the real token propagate instantly. Players don't know they're on separate pages — it looks and feels like they're on the same map. Use Cases Truesight — Everyone in the party loves Robert the rogue, but one day, Sally the sorcerer casts true sight and finds out that Robert is a changeling. Only Sally knows this information. Does she keep it a secret? Real stealth — Tokens are only visible to players whose passive perception beats the DC. Everyone else doesn't see them at all. No "okay just pretend you didn't see that token." Asymmetric information — Everyone in the party knows the friendly merchant as Hassalfax. It says it right there on his nameplate, see? One of the players knows him as Morganth. He'll never forget that face. Illusions — The party sees an empty corridor. The rogue checks the hallway and finds no traps, but a hidden loot stash is revealed to her when she gets close enough. She decides to lead the party down the opposite end of the hallway so she can come back later and keep all of the loot for herself. How It Works Duplicate your map page — one copy per player Customize each player's copy (different token art, hidden/visible tokens, different names) Run !gaslight setup <group> — Gaslight detects the pages, assigns players, and creates all config automatically Run !gaslight split <group> — Players get assigned to their pages, tokens link up, sync begins From that point on, the GM works on the master page. Move a token on master — it moves on all player pages. Players move their own tokens — it syncs back. But each player only sees what's on THEIR page. If you run a command on a token on the master page, it will run that same command on each player's page. If you run a command on a token on a player's page, it will only run on their page. When you're done: !gaslight merge <group> brings everyone back together to wherever the "banner" page is. Commands !gaslight setup — Quick-configure a group from pre-duplicated pages !gaslight test <group> — Dry-run: check linking, show warnings before activating !gaslight split <group> — Activate (assign players to pages, link + sync tokens) !gaslight merge <group> — Deactivate (return all players to master) !gaslight link [<name>|new] — Manually link tokens across pages !gaslight view [master|<player>] — Preview what a specific player sees !gaslight relay <views> <!command> — Run a command on specific player pages !gaslight stage — New tokens on the master page will not sync to player pages until you run this command. Allows you to tweak what you want before everyone sees it. !gaslight status — Show active groups and links !gaslight --help — Full reference Automation Gaslight allows for basic scripts to be written in handouts and assigned to maps with pins. Combined with RollCapture (for extracting roll results) and the relay system, you can build things like: Automatic stealth — tokens appear/disappear per player based on passive perception vs. Stealth DC Triggered reveals — a player passes an Insight check and the NPC's token image changes only for them Per-player FX — different spell effects visible to different players The building blocks are there. What you do with them is up to you. Dependencies Gaslight orchestrates several scripts behind the scenes: Anchor — Spatial sync (position, rotation, scale) between linked tokens Mirror — Property sync (HP, status, light, etc.) between linked tokens RollCapture — Read results of rolls for triggering scripted outcomes Meta-Toolbox — Allows scripting of gaslight automation through scripts like Fetch, SelectManager, and APILogic All install from the One-click installer. Install Available in the One-click installer. Requires: Anchor, Mirror, SelectManager, RollCapture Optional (but useful): Fetch, APILogic GitHub Source | Wiki Page
This looks like some good work!
1782865799
Gauss
Forum Champion
Hi Aerotech,  How are you handling the Turn Order without it becoming a jumbled mess for the GM? 
if possible, I'd love to see this in action (YT vid)
1782869331
Aerotech
Pro
API Scripter
Good point, Gauss. Actually, I hadn't considered that. I will figure out a way for that to not suck and add it in an update soon.
1782869891
Aerotech
Pro
API Scripter
Novercalis, I plan to make a YT video soon.
1783039499
timmaugh
Pro
API Scripter
Interesting (and ambitious) idea! I should point out that if people are going to install several of the metascripts, they should at probably include ZeroFrame (or just get the full Toolbox). This is because ZeroFrame gives an established, expected order (which can be modified in the command line) to the order the other scripts run. For instance, if you had Fetch and SelectManager installed, but not ZeroFrame, then a formation like this: {& select @(Thungus.gmnotes) } ...will work if Fetch is installed *before* SelectManager, but not if it's installed after. The Fetch construction will resolve, probably returning a list of token names/ids to select, then SelectManager will select those referenced tokens. If SelectManager tries to go first, it will look for a token named "@(Thungus.gmnotes)" and fail to find it. Meanwhile a formation like: @(selected.gmnotes) {&select Thungus} ...will work if Thungus is selected first, then Fetch can return data from the selected token. That means that SelectManager needs to be installed before Fetch. With ZeroFrame installed, SelectManager will default to going before Fetch unless you change it. That lets you have predictability between different games (the same command will work for all your games), and it means that you can change the order to make any construction function correctly. For instance, the first example could be made to work with backslashes to defer constructions: {\& select @(Thungus.gmnotes) } ...or by adding an ordering tag added to the line: {& select @(Thungus.gmnotes) } {&0 fetch sm}