I think this is better. The JunctAvailDirect is in the wrong place. You need to build the array for each junction that is ready for a change. I've moved it under event 142. I've cleaned it up too.
This still isn't perfect. There is still an issue when the wall is sliding - ghosts can overlap walls, and I still see the occasional invalid wall crossing, but they seem less, and I don't know if this is because the sliding issue leaves something in a funny state. I also just thought about two ghosts being on the same junction - does this cause an issue?
http://www.blackhornettechnologies.com/ ... r_bht.capx