On RSO control.lua line 1828, you read the list of starting_points out of surface.map_gen_settings. This list is sometimes nil or empty, so lines 1829-1830 check for that and only add to surfaceData.starting_areas if the map_gen_settings.starting_points exist.
On line 1061, the line that is crashing assumes that the given index of starting_areas exists, but starting_areas might be an empty array. I would suggest that you add a check to make sure that surfaceData.starting_areas[index] exists before attempting to use it, and maybe print a warning message if it doesn't rather than crash the game. It's still good for other mods to use the interface to disable the RSO logic completely, but this would fail more gracefully.