SkBee
SkBee copied to clipboard
[SUGGESTION] make run task later return the current task id so it can be cancelled
Suggestion
As of right now, there is no way to use run task later in conjunction with the task id to cancel it before it runs.
Example Usage:
set {taskToBeRun} to run 1 minute later: broadcast "a minute has passed"
every 10 seconds: if "pzvi" parsed as player is offline: stop task with id {taskToBeRun}
Additional Information
No response
This is an interesting concept, and might be relatively simple to implement with section expressions. I'll look into it a bit later.
I ended up opting for a different solution.
Due to the fact the current section extends a loop section (to be able to stop the task within itself) it would have broken logic to make it a section expression.
Therefor I just adjusted the current task id expression to have an option for last created task id.
Example of how you could use this
on some event:
run task 1 minute later:
do some stuff
set {id} to last created task id
on blah blah:
cancel task with id {id}