Not sure if this save still works
Thank you, it did work! Eventually, I've even figured out how to launch the spaceship. But I'm still working on the cloning-event routine …
-- These are the "solid" surface types
if not (surface_type == "planet" or surface_type == "moon" or surface_type == "vault") then
in_space = true
end
Earendel has added to that:
If it returns planet, moon, vault or nil then it is not a space area and vehicles can work, but otherwise vehicles should not work (unless they are spider vehicles).
Not sure if spider vehicles are relevant for your mod, but you should definitely add a check for nil! :-)
He also has plans for future SE versions:
There is an interface for get_zone_is_space, but I've just realised that it it won't work for spaceships because they are not true "zones", so I will add a new function that checks if a surface is space later.
Not sure if I understood that correctly. It could be just "I will add a new function … later", but I really hope for "new function that checks if a surface will become space later", so I could use that to skip the on_player_driving_changed_state …