Courtesy of Minmay:
minmay wrote:GameObject:getPosition() returns only the x position in some circumstances in 2.1.17, if you update to 2.1.18 it should fix the issue.
Yeah sure, I'll dump the sources when I stop working on it. Also happy to share any specific sections if anyone is interested.
I will say though, my scripting isn't the most readable thing in the world. I'm no programmer and this is my first crack at lua, so I do not envy he who wants to make sense of some of the stuff I wrote when I first started.