Different heights and attractor lines

I’m working on a project where I need to assign different heights to courtyard buildings. Furthermore, I would like some of these buildings, confined to the outside, to follow a specific attractor axis. Could anyone suggest an approach or component in Grasshopper that would allow me to accomplish this setup?
altezze e linee attrattori.gh (19.1 KB)
altezze e linee attrattori.3dm (387.8 KB)

do you want some thing like this?

and i think this is your mean for “attractor axis”

in reality respect the external axis, as if there was a road beyond the boundary of the lot, the height of the buildings should follow that axis.