I've been using construct for a long time now, but the largest headache I have is constantly having events trigger out of order/early/late/multiple times, causing days of rewrites sometimes just to try and accidentally find something that works.
Then I can add one new thing, and everything breaks in an equally nonsensical way.
Note: This all includes using wait:0's, wait signals, moving stuff off to functions/asynchronous functions and waiting for completion, etc.
Does anyone that's experienced this have a workflow/consistent solution for this?
For a recent point of reference, was trying to work on a recent game jam and spent straight 6 hours rebuilding an attempt to smoothly transition to a next turn of combat.
I wanted all of a turn to resolve before allowing input again, so I did many variations like adding 1 to a global when a character attacked, then subtracting 1 at the end of their attack animation. And added 1 at the start of an enemies hit animation (triggered before the end of an attack), reduced 1 at the end of the hit animation before it was destroyed. Once it returned to 0 you would then be able to input again.
Tried various waits, moving it around, signals, functions, etc adjacent to that idea, switched to/away from 'for each' in the on animation ends in-case there was a difference if 2 enemies triggered at the same time, but nothing worked. It would consistently, inconsistently have 1 left over and so stop working.
This is only my most recent example, it's a struggle I constantly run into and can be the majority of my effort in small games just hoping to randomly stumble upon some combination that works.
Sometimes wait 0's would fix something, other times it would break everything. Sometimes I end up with so many nested events just trying to hope they would properly run after another because they just didn't seem to even though nothing is meant to be parallel from what I've read.
I can't really provide an example because it feels so illogical and inconsistent that I don't know how to properly reproduce it, besides waiting for it to break, but even providing that could be one of any countless variations of struggling with this problem I've had and not be of universal help.
So I'd really appreciate if there's anyone who has developed a workflow to overcome these issues or found a common trick to resolve some of these cases that isn't just guess work.