Works nicely except do you know why the player can go through ceilings and off the map when walking up slopes or stairs? See the attached map and walk to the end of the map. It is possible to jump off the map as well as jump onto the platform. I presume it is due to manually adjusting the my.z, circumventing collision detection.

Attached Files
bug.zip (89 downloads)