ADRIFT Forum


The place to discuss the ADRIFT Interactive Fiction toolkit

Trying to get an ongoing task to repeatedly execute.

This forum is the place to learn about and discuss ADRIFT 5. Feel free to mention any bugs you find here, but please also add these to the Bugs & Enhancements list.

Please also refer to the ADRIFT 5 Wiki for more information.

Trying to get an ongoing task to repeatedly execute.

Postby maddieface » Wed Jan 30, 2019 9:17 am

Hi guys, I'm tinkering with a spellcasting game with a mana stat, and I'm having trouble getting the latter working. I've got it set with two variables (a maximum and a current), and I'm trying to get a task to execute each turn to check if the current mana is lower than maximum and, if so, increment it by 1. Said task is called by a repeating 1 turn event initiated from the start of the game and set to repeat on finishing. I'm reasonably sure the event is working fine (it's triggering other upkeep style tasks that are working as intended) but the mana recharge task is only ever executing once, and then never again. It is tagged as being repeatable so I don't know what gives. I'm screenshotting the three pages of the task below in case someone can point out what's wrong.

image1.png
image1.png (19.08 KiB) Viewed 110 times


image2.png
image2.png (13.61 KiB) Viewed 110 times


image3.png
image3.png (12.31 KiB) Viewed 110 times
maddieface
 
Posts: 2
Joined: Wed Jan 30, 2019 9:06 am

Re: Trying to get an ongoing task to repeatedly execute.

Postby R2T1 » Fri Feb 01, 2019 2:29 am

I have a similar situation (System TASK - Countdown) except my variable counts down each turn and I have no restrictions. Everything else looks the same as mine. I do have an extra tab called Advanced, which has a Task Priority of 11, Aggregate output where possible is ticked and Display completion message AFTER executing actions. (This is possibly because I have Simple Mode unchecked in the game settings.)

This is controlled from an event which is Turn Based to start immediately and lasts 1 turn and repeats on completion. It contains only 1 Sub-Event - After 1 turn from Start of Event, Run Task Countdown.

Not sure if any of that will help as there may be something else that is stopping it. You could try adding an extra sub-Event that outputs a message at the same time as the variable increments to see if is firing as expected.
User avatar
R2T1
 
Posts: 104
Joined: Thu Dec 20, 2012 10:41 am
Location: Sydney, Australia
Points: 13

Re: Trying to get an ongoing task to repeatedly execute.

Postby maddieface » Fri Feb 01, 2019 3:37 am

I got rid of and rebuilt the Magical Power variables and now it's working so I have no idea what was going on, but thanks so much for the help!
maddieface
 
Posts: 2
Joined: Wed Jan 30, 2019 9:06 am


Return to ADRIFT 5.0

Who is online

Users browsing this forum: No registered users and 4 guests

cron