-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathCommands.py
53 lines (53 loc) · 2.78 KB
/
Commands.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
commands = {
"delete object": "bpy.ops.object.delete()",
"delete objects": "bpy.ops.object.delete()",
"add cube": "bpy.ops.mesh.primitive_cube_add()",
"add monkey": "bpy.ops.mesh.primitive_monkey_add()",
"shade smooth": "bpy.ops.object.shade_smooth()",
"subdivide": "bpy.ops.object.modifier_add(type='SUBSURF')",
"edit mode": "bpy.ops.object.editmode_toggle()",
"object mode": "bpy.ops.object.editmode_toggle()",
"select all": "bpy.ops.object.select_all(action='SELECT')",
"deselect": "bpy.ops.object.select_all(action='DESELECT')",
"undo": "bpy.ops.ed.undo()",
"redo": "bpy.ops.ed.redo()",
"render image": "bpy.ops.render.render()",
"render animation": "bpy.ops.render.render(animation=True)",
"play": "bpy.ops.screen.animation_play()",
"stop": "bpy.ops.screen.animation_play()",
"go to frame ": "bpy.context.scene.frame_set(",
"go to frame": "bpy.context.scene.frame_set(",
"scale x ": "bpy.context.object.scale[0] = ",
"scale x": "bpy.context.object.scale[0] = ",
"scale y ": "bpy.context.object.scale[1] = ",
"scale y": "bpy.context.object.scale[1] = ",
"scale z ": "bpy.context.object.scale[2] = ",
"scale z": "bpy.context.object.scale[2] = ",
"rotate x": "bpy.context.object.rotation_euler[0] = math.radians(",
"rotate x ": "bpy.context.object.rotation_euler[0] = math.radians(",
"rotate y": "bpy.context.object.rotation_euler[1] = math.radians(",
"rotate y ": "bpy.context.object.rotation_euler[1] = math.radians(",
"rotate z": "bpy.context.object.rotation_euler[2] = math.radians(",
"rotate z ": "bpy.context.object.rotation_euler[2] = math.radians(",
"move x": "bpy.context.object.location[0] += ",
"movex": "bpy.context.object.location[0] += ",
"move x ": "bpy.context.object.location[0] += ",
"move x - ": "bpy.context.object.location[0] += ",
"move x -": "bpy.context.object.location[0] += ",
"movex - ": "bpy.context.object.location[0] += ",
"movex -": "bpy.context.object.location[0] += ",
"move y": "bpy.context.object.location[1] += ",
"movey": "bpy.context.object.location[1] += ",
"move y ": "bpy.context.object.location[1] += ",
"move y - ": "bpy.context.object.location[1] += ",
"move y -": "bpy.context.object.location[1] += ",
"movey - ": "bpy.context.object.location[1] += ",
"movey -": "bpy.context.object.location[1] += ",
"move z": "bpy.context.object.location[2] += ",
"movez": "bpy.context.object.location[2] += ",
"move z ": "bpy.context.object.location[2] += ",
"move z - ": "bpy.context.object.location[2] += ",
"move z -": "bpy.context.object.location[2] += ",
"movez - ": "bpy.context.object.location[2] += ",
"movez -": "bpy.context.object.location[2] += ",
}