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

API: Hourglass

Is there an easy way to change this API to send a message to the GM when the timer is up?
!delay seems like the natural solution here unless there's a better one I don't know of.
!delay doesn't seem to trigger anything in my game. 
1535144396
keithcurtis
Forum Champion
Marketplace Creator
API Scripter
Hi Volomon. Delay is a script by Kastion that needs to be installed into your API in order to function. It basically will allow you to delay the API commands that come after it by a specific interval.
1535145999
The Aaron
Pro
API Scripter
Alternatively, Hourglass could be changed to send a message to the GM when the timer goes off.  If you can link to the script, I can make the change for you.
<a href="https://github.com/Roll20/roll20-api-scripts/blob/master/Hourglass/1.0/hourglass.js" rel="nofollow">https://github.com/Roll20/roll20-api-scripts/blob/master/Hourglass/1.0/hourglass.js</a> Thanks Aaron!
1535147044
The Aaron
Pro
API Scripter
So, if you modify this function which starts on line 65: const timesUp = function(obj) { hourglass.remaining = 0; stopHourglass(); resetHourglass(obj); setBars(obj, 0); printMessage("The Timer has expired!"); }; Whatever you want to put in that bolded line will get whispered to the GM on completion.