You'd have to define the route-to command so that only resources or cities were legitimate targets.
But is that not feasible? Already there are some restrictions in the route-to function... but as I said, I'm not a modder, just throwing ideas around. I'm going to need someone to do this, if it's ever going to be anything but ideas...