Post #3875: There is a way but it’s not straight forward, roaoao made something specific to
📋 Metadata
- Author: Motiomancer
- Date: 2021-05-25 14:27:10
- Type:
answer - Quality Score: 8/10
- Reply to: post_03873
- Replies (1): post_03877
🏷️ Tags
⚙️ Related PME Features
- Macro Editor
- Stack Key Editor
- Python Scripting
💬 Content
There is a way but it’s not straight forward, roaoao made something specific to store information temporally its called U.(random text)
This one saves orientation, pivot and tool:
U.orient = C.scene.transform_orientation_slots[0].type; U.pivot = C.scene.tool_settings.transform_pivot_point; U.tool = C.workspace.tools.from_space_view3d_mode(bpy.context.mode).idname
This one restores them:
C.scene.transform_orientation_slots[0].type = U.orient; C.scene.tool_settings.transform_pivot_point = U.pivot; bpy.ops.wm.tool_set_by_id(name=U.tool)
You should add the first line to the beginning of your macro to store the info and with the second line you can put it in a stack key with the macro or make another hotkey