The current task I'm working on is moving objects in 4 basic relative directions. By using the local axes this can be accomplished relatively easy through View3d port.
However to script this behavior I can't figure out how to directly set coordinates in local space. The command "object.location" seems to always work in global coordinates. If I want to move, rotate, etc I can do this (or equivalent):
bpy.ops.transform.translate(value=(0,1,0), orient_type='LOCAL')
But I don't want to move objects, instead I want to place them. For instance in this picture the y-axis is flipped. The above command would correctly move it down one unit.
However I'm currently working with numbers that represent the actual location, so if I enter:
object.location[1] = 1
I would want the same action - moving down one unit. Is there a way to do that (outside of calculating world space coordinates and moving accordingly)?
This behavior is consistent no matter where I place the object origin or apply location transformations. It changes the relative coordinates but not the direction in which the axis is applied.