I’m trying to make a timer that will count down to a meteor strike, and have the time left display in the status line. The code I have is this:
the meteor strikes in 13 minutes from now;
now the right hand status line is "[13 minutes minus the time of day]";
(inside an Instead rule for the activator)
But it just returns in the status line.
I’ve tried several different things, and this is the only one that compiles. Any tips?
[code]The time to strike is a number that varies. The time to strike is 14.
meteor-incoming is a truth-state that varies. meteor-incoming is false.
Every turn when meteor-incoming is true:
now time to strike is time to strike - 1;
and when you want to set the timer:
now meteor-incoming is true;
now the right hand status line is "[time to strike]";
(Or you can do it with time instead of number.)
You can also phrase it like this.
decrement the time to strike;
Hope this helps.