Where pydrivers enable us to drive the change of one
IPOCurve by the change in another, PyConstraints provide us with ways to let object properties change only in a limited way.
Of course, Blender has many simple constraints predefined as we saw in previous sections and often a combination of simple constraints may be exactly what you want. But say you want your objects to move about freely within a non-rectangular area, for example to simplify the allowed placement of traffic lights and phone booths on a street grid. How would we achieve that? Enter pyconstraints.
PyConstraintsï»¿ are Python scripts that should be present as a text block in Blender's text editor and start with a comment line identifying it as a constraint: ...