Sorry, but that's not going to work. ScriptableObjects are supposed to act as assets which can be reused between scenes. That means you can't and shouldn't make them dependent on objects which exist in only one scene.
But what you can do instead is:
Ugly workaround 1: Have the ScriptableObject find its object(s) at runtime. You can do that by tag, by name ...
(1) Refer to the idea of an epsilon value which represents the float error range within which you are willing to accept a "success" condition.
It is normal for floats to be compared using an epsilon, for example:
float e = 0.0001f; //epsilon
public bool FloatEquals(float a, float b)
return Math.abs(a - b) <= e;
bool Vector2Equals(Vector2 a, ...
You basically have an ordered list of segments, making the segmented path you have described of that road. To smooth it up, you could simply take the centers of the segments and the points connecting them to create Bézeir curves from them.
Read here for a detailed explanation of how it's done.
Once you describe the path as connected Bézeir curves, it's ...