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 .
×
Create a free account

Start of Turn triggered saving throw

1735059599

Edited 1735059651
I'm trying to trigger a popup in chat for a saving throw  at the start of a characters turn if they are in an aura. Specifically this one from the Nightwalker: Any creature that starts its turn within 30 feet of the nightwalker must succeed on a DC 21 Constitution saving throw or take 21 (6d6) necrotic damage. Undead are immune to this aura. I've seen some things that come close, but can't wrap my head around how to get it all working.  Thanks!
1735064396

Edited 1735064442
This sounds like it can be done with a combination of ScriptCards, Fetch, and OnMyTurn . OnMyTurn can trigger a ScriptCard on a character's turn that will look at the distance between the two tokens and then do the saving throw and damage if applicable. You'll need Fetch to get the token ids for the comparison.
Ha! I've been a Pro user long enough to know what all those things are... but what you are suggesting is way over my head at the moment!  Are there any good examples you can think of as a starting point? Zone of Truth spell is similar-ish if someone has that kicking around ;)
1735141052
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi Jeremy! Most any programmatic solution is going to take a similar amount of prep work. I'm assuming this is a one-off encounter? In which case, I suggest that your time would be better spent just remembering to ask for the save at the beginning of each turn for that one encounter.
Wait. You mean I'm not supposed to spend an hour automating a task I'll only use like 4 times? That doesn't sound right.
Hahah I come by it honestly... my dad used to be in the shop 'building a better hammer' for those last couple of nails :) keithcurtis said: Hi Jeremy! Most any programmatic solution is going to take a similar amount of prep work. I'm assuming this is a one-off encounter? In which case, I suggest that your time would be better spent just remembering to ask for the save at the beginning of each turn for that one encounter. Sadly for the heroes there will be a couple of these Nightwalkers in their future, plus a  boss  version! But still easy enough to take care of manually for sure. I figured there must be a tool for this that I haven't seen as yet (only been  pro  for a few months now and its information overload to be honest). It would be useful for things like the nightwalker, zone of truth spell, spirit guardians spell (though this is slightly different), dragons  frightful presence,  medusa  petrifying gaze,  etc.  Ultimately, I was hoping to build a 5e version of  blackfire   from Return to the Tomb of Horrors   This was a super fun game I ran 25 years ago! There is a  Winterwight  with the blackfire and I thought it would be fun to have a 5e version of this: "While a winter-wight's physical attacks are not to be ignored, the real threat this creature possesses is that its touch causes blackfire. In the same way that a conventional fire burns and propagates by consuming combustible fuel, blackfire burns on the fuel of a living being's life force. Those touched in combat are engulfed in cold flames the color of midnight. The afflicted character must immediately make a check to determine what happens. On a roll of 11 or more on 1d20, the character suffers no damage that round, and the blackfire burns lower; the target's hit point adjustment from Constitution applies as a bonus or penalty to the roll (all characters can claim the warrior adjustment for purposes of the roll). If three successful checks are made in three successive rounds, the blackfire gutters out. If the check fails, the target temporarily loses 1d2 points of Constitution, losing any associated hit points and special abilities. Each round that the blackfire burns on the victim's life force, another check must be made. If the creature's Constitution score reaches 0, it dies. Those killed by blackfire are irretrievably consumed. Nothing but a blackened, crumbling skeleton clad in undamaged clothes remains of the victim. Not even a wish can restore them. If any other living being comes within 2 feet of a victim engulfed in blackfire, that being must make a successful saving throw vs. death magic or face the same effects described above. Blackfire cannot be smothered by conventional means. However, blackfire will not burn in an anti-magic shell or on a being protected by a negative plane protection spell, and it can be blown out by the force of a fireball, lightning bolt, or similar energetic spell (the victim suffers damage from these normally) of at least 8 dice. Those who survive blackfire recover lost Constitution at the rate of one point per hour."
1735245967
timmaugh
Pro
API Scripter
So, there's nothing like just playing and seeing what happens! When OnMyTurn is installed in a game, it is going to watch for every time you advance the Turn Tracker. If the token that comes up as the current turn has a character sheet, and if that sheet has an Ability Macro named "OnMyTurn," then that command will be executed. So add an ability to your character, and put a token of theirs in the Turn Order (with a few others). When you come to the turn of your character (or, any character with an OnMyTurn ability), it will be executed. Pausing just to say: When it's Bob's turn, Bob's OnMyTurn gets executed. When it's Actual Cannibal Shia LeBeouf's turn, ACSL's OnMyTurn will be executed. Hopefully that was clear already, but figured I'd make a point of it. OK, so then in your OnMyTurn, put different things you want to try. For instance, you can use Fetch  (and the MetascriptToolbox) to get information about the token who's up in the Turn Tracker: !/w gm &{template:default}{{name=Info Proof of Concept}}{{Token Name=@(tracker.token_name) }} {{Token ID=@(tracker.token_id) }} {{Position=@(tracker.left), @(tracker.top) }}{&simple} That location can help to to do math (can be done somewhat automatically by scripts) for how close tokens are to each other (I had a metascript that would do some of that automatically -- like selecting the tokens within x-distance from some source -- but the path changes as a part of Jumpgate have pushed back the release). Figuring you're using the D&D 2014 sheet, I'm not the best for applying the damage (or knowing where to apply it). And I'm also not the best ScriptCards resource, but I'm sure others here can help close those gaps.