avoided seg fault at scene destructor, maybe another bug fixes