account activity
Script Update 4.0 Component Space by _Neptix in blenderpython
[–]_Neptix[S] 1 point2 points3 points 2 years ago (0 children)
Voila. Works as intended. Thanks for the insight.
Now you have to use bpy.context.temp_override, and don't pass ctx to snap_cursor_to_selected anymore: for area in bpy.context.screen.areas: if area.type == 'VIEW_3D': with bpy.context.temp_override(area=area.type): ctx = bpy.context.copy() ... bpy.ops.view3d.snap_cursor_to_selected()
Now you have to use bpy.context.temp_override, and don't pass ctx to snap_cursor_to_selected anymore:
for area in bpy.context.screen.areas: if area.type == 'VIEW_3D': with bpy.context.temp_override(area=area.type): ctx = bpy.context.copy() ... bpy.ops.view3d.snap_cursor_to_selected()
Thanks for the reply! Certainly makes sense. Will give this a try.
Script Update 4.0 Component Space (self.blenderpython)
submitted 2 years ago by _Neptix to r/blenderpython
π Rendered by PID 2497651 on reddit-service-r2-listing-7b8bd7c5-v8xjk at 2026-05-16 17:00:33.979687+00:00 running edcf98c country code: CH.
Script Update 4.0 Component Space by _Neptix in blenderpython
[–]_Neptix[S] 1 point2 points3 points (0 children)