Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -41,12 +41,12 @@ def visualize_planets():
|
|
41 |
for obj in bpy.context.scene.objects:
|
42 |
if obj.type == 'MESH' and "mass" in obj:
|
43 |
obj.select_set(True)
|
44 |
-
for area in bpy.context.screen.areas:
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
##bpy.ops.object.origin_set(type='ORIGIN_CURSOR')
|
51 |
##bpy.context.scene.cursor.location = (0, 0, 0)
|
52 |
|
|
|
41 |
for obj in bpy.context.scene.objects:
|
42 |
if obj.type == 'MESH' and "mass" in obj:
|
43 |
obj.select_set(True)
|
44 |
+
##for area in bpy.context.screen.areas:
|
45 |
+
## if area.type == 'VIEW_3D':
|
46 |
+
## override = bpy.context.copy()
|
47 |
+
## override['area'] = area
|
48 |
+
## bpy.ops.view3d.snap_cursor_to_selected(override)
|
49 |
+
bpy.ops.view3d.snap_cursor_to_selected()
|
50 |
##bpy.ops.object.origin_set(type='ORIGIN_CURSOR')
|
51 |
##bpy.context.scene.cursor.location = (0, 0, 0)
|
52 |
|