Bugfixes; better spawn handling