@d-healey i just tried your script, it had the same issues as the original one before.
Time Attenuation just "marches" across the table every note press instead of actually giving the note length.
EDIT: Here's a video for demonstration:
https://www.youtube.com/watch?v=Is_Q9DLsnK0&feature=youtu.be
I assume the fix is the same as i did for the first one, apparently changing the collection type for the noteLength to an Array fixes it for me.