Retrieve Cursor Coordinates: How to?

Left-clicking on an object sets the cursor onto the object surface, where the muse-cursor was.
How can I retrieve the cursor location on the object surface now?

Check the cusor location on the right panel. If the panel is not open, press N. I hope this is what you’re looking for.

If I’m not mistaken, you can get the 3d cursor location by:

bpy.context.scene.cursor_location

The coordinates will be in world space - but you should be able to convert this to any objects local space:

[SOLVED] Global to Local coordinates

And by the way: for more advanced needs you can always use ray casts. This will give you more information about the object/face. Blender comes with an example/template on this matter: “operator_modal_view3d_raycast.py”

Thank you Helge! That was what I was looking for.

Glad it helped. Good luck with the script :slight_smile: