@d-healey said in Confusing results from message delay?:
@VirtualVirgin I have a chord detector script which adds notes to an array as they come in and then processes them. Sounds like a similar thing.
Here's a simple snippet that adds note numbers to an array in on note on and removes them in on note off. Works with notes played at the same time and sequentially.
HiseSnippet 731.3ocsUstSaCCE1tzfV6tngzd.xOKSHTaoEnBMMfdYqaqP0JCMooIjiiSiEI1QNNrUMs248FrcbRfFfJtTokeTky8udNemSFqjTVbrTgvUOYVDCgel0jYBseWeBWfF1Cgeg0HRrloryTc3rHRbLyEgwq7NiBbkxnzm+71CIADAkMWEBcpjSYehGx0y0Nd+OxCBFPbYmvCK3cq8GRkhtx.YBfmUrpihHzyISYGQLtUxB8dRrOB+ZKGhScB0ya6lN65UuUy1McbZ41Bz3rSmNc7Z2fzdqcnTDd09tbsTMQSzrXHoGJcmMwW9CQVANkGycBXFgFnIPkyTi55yCbGeYyIFgvkGOuUsRVq5UVi3t7qzOuk8xTC1yinXSCW5tfTiGAjvEfT4LHsl0DphGomawfmmZMT.SPOBLaJBkLeQk9.1pqD7Pn2LjbNafBDtJhZaWu9F1vOquW0pJ1TagDvs8ar+122yKQP0bovVJNBzdrn15U+U0JARJIvV.9LB.AL.2bJSab3njPGlplISURSylQIw9C8.aGDnXD2Ym3yTrZBvieW09lo2y6QmeEKTdwhRn4OrRFDXb2jyaX1vLWrk7.qIRq0F1WPBRXW4HLIt93c0G13kl0+K3nTLTv0GGwxkGHCbMiMy62lLfxGfvaeYXOhlX3G45.+hXJM2.GbO1EvFYFaohUOV74ZYDrSdKpDPhktIAD80Y1lc9bCP+3ZzICkQDy0yJdS3QP2qemz8GJDWyZLWS8WLFKs.LBcp+GXL+Hwys564wn54.rr0futrWDtmx+YYhlKlNhnU7ehvVv9vD3XJkAUWHXAPxsvkLrkL45FYSGXBS3lJ7W3I2XCiLN2XiKMhBITk7LZ1Vf4LzSR0.XRjdltB78BP1tAJcynXeNDtJdl4pbwTcq.atrAt0xFXqkMv1KafaurAtyxF3t2eflOZcPhVFls1fPiF2O8TBF2WP.FXJaE8OLLOJoGPeek 2024-11-11 23-23.gif
Thanks :)
I'll check this out tomorrow.
I did end up solving for the delay problem by moving the rest of the code into a child container with another script processor.
Screenshot 2024-11-11 at 10.52.57 PM.png
Screenshot 2024-11-12 at 12.25.24 AM.png
The notes from the note recorder get delayed by 1 sample, and that gives room for the array to record all of the voices before sorting the order in the next module.
The basic problem that the delay solves is that the array cannot be sorted and reversed until all of the notes are in.
It is working so far:
Screenshot 2024-11-12 at 12.33.00 AM.png
I have a stray note off that I will try to clean up, but at the moment is not effecting the function.