This might be a really stupid question-I'm working in bpy right now and want to add a plane at a specific location...I know that How to add an object at a specific posistion in Blender Game Engine works for bge but am not sure if it'll work in bpy...
Asked
Active
Viewed 7,075 times
2 Answers
4
The tooltip of the Add > Mesh > Plane menu path shows this information, press Ctrl+C to copy it to clipboard.
Tooltip
All of these menu items trigger operators and take several optional arguments, location=(x,y,z) included. The same applies to the other items in the Curve, Surface Metaball etc., menus.
Docs
The total list can be found in several locations, in the docs
Blender's Python Console
use the auto complete feature (ctrl+space) in the Blender python console after typing bpy.ops.mesh.primitive_
The arguments to the bpy.ops.* can be found doing auto completion too
Info Panel
You can see the history of most of the code which has been triggered in the UI, in the Info panel if you drag it down
zeffii
- 39,634
- 9
- 103
- 186
-
"CTRL-C on a ToolTip" to copy the datapath or the Python function is a great TIP..works with SHIFT-CTRL-C on fields with values and checkboxes in all other windows – Master Heavy Oct 18 '19 at 06:27
0
bpy.ops.mesh.primitive_plane_add(location=(x,y,z))
does the trick
-
will you please add more to this answer, to make it more useful for future viewers. – David Aug 02 '15 at 02:24



