I
I
icetomcat2020-02-28 14:27:03
JavaScript
icetomcat, 2020-02-28 14:27:03

Are there ready libraries for task queues?

There is a WebGL game with a bunch of sounds, animations and server requests. All this can be mixed up and performed sequentially and in parallel. But there is a task to interrupt these sequences, instead of the player waiting for long animations, when the button is clicked again, all current animations stop and the game continues.

Now this is implemented through a bunch of flags and a mess of twins, I would like a more elegant solution and preferably without bicycles.

I gave an approximate idea of ​​​​such tasks here . Searches did not give suitable results, I hope for your help.

Thanks for answers! =)

Answer the question

In order to leave comments, you need to log in

1 answer(s)
A
Alex, 2020-02-28
@kostia256

The usual stack of commands within each command should have start/stop methods.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question