i think you can get rid of the trigger compare and use the output of the trigger counter instead.
connecting trigger to trigger and reset to reset.
but that won’t solve your question.
i’m not super versed in msounds but i’m a dev. what i’d do is:
have an event for “Player crosses point” (ill call it IsPOnPoint)
Then i’ll get two trigger control TCA2B and TCB2A
the IsPOnPoint connects to both TCs but negated on one. So it opens and close them in the opposite cases.
The trigger input for both TCs would be the trigger from the Bar count (should trigger at the crossfade moment, eg bar 24).
the trigger output for each TC would connect to a different crossfade, from A to B in TCA2B and from B to A in TCB2A. (i’m not sure how you will animate that crossfade).
the trigger output for each should trigger a looped wav for A and B respectively.
the trigger output for each "could” trigger a stop on B an A respectively.
I wouldn’t use the trigger of the bar count 32 to play the wav, instead have a loopable section.
and maybe have the tail transition as a different wav. it might simplify it a bit, but it might introduce audio quirks, depending on how reliable is metasounds and the wavs authoring.
but you can still use the trigger bar count 32 to drive both audios. you might need to gate it with a TC and the same setup with IsPOnPoint.
if you have both bar counters, it will be a bit more difficult to connect, as they have different lengths (32 and 24).
you’re kinda making an implicit state machine, if i had more free time available i could actually design something that works well. but maybe someone else has better advice.
i hope at least it gives you an idea or start point.
alternatively you might be able to simplify a lot your code if you make use a different approach, and have a trigger repeat for the whole section instead of the bar.
for example one for Period**32 and another for Period**24
then you can just start/stop those triggers directily. maybe control them using the isPOnPoint event. thought that would look more like a bistable or flipflop in the sense that the output of one of the periods would trigger the switch to the other period.