slight refactoring of scriptthread setup
fix map editor button initial selection