Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from mathutils import Vector, Quaternion, Matrix, Euler
- bpy.context.scene.frame_set(1)
- M1 = Matrix.Translation(Vector((0, 0, 0)))
- bpy.data.objects['Armature'].pose.bones[0].matrix = M1
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('rotation_quaternion')
- M2 = Matrix.Translation(Vector((0, 0, 2)))
- bpy.data.objects['Armature'].pose.bones[1].matrix = M2
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('rotation_quaternion')
- M3 = Matrix.Translation(Vector((0, 2, 4)))
- bpy.data.objects['Armature'].pose.bones[2].matrix = M3
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('rotation_quaternion')
- bpy.context.scene.frame_set(2)
- M1 = Matrix.Translation(Vector((0, 0, 0)))
- bpy.data.objects['Armature'].pose.bones[0].matrix = M1
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('rotation_quaternion')
- M2 = Matrix.Translation(Vector((0, 1, 3)))
- bpy.data.objects['Armature'].pose.bones[1].matrix = M2
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('rotation_quaternion')
- M3 = Matrix.Translation(Vector((0, 3, 5)))
- bpy.data.objects['Armature'].pose.bones[2].matrix = M3
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('rotation_quaternion')
- bpy.context.scene.frame_set(3)
- M1 = Matrix.Translation(Vector((0, 0, 0)))
- bpy.data.objects['Armature'].pose.bones[0].matrix = M1
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('rotation_quaternion')
- M2 = Matrix.Translation(Vector((0, 2, 4)))
- bpy.data.objects['Armature'].pose.bones[1].matrix = M2
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('rotation_quaternion')
- M3 = Matrix.Translation(Vector((0, 4, 6)))
- bpy.data.objects['Armature'].pose.bones[2].matrix = M3
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('rotation_quaternion')
- bpy.context.scene.frame_set(4)
- M1 = Matrix.Translation(Vector((0, 0, 0)))
- bpy.data.objects['Armature'].pose.bones[0].matrix = M1
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('rotation_quaternion')
- M2 = Matrix.Translation(Vector((0, 2, 4)))
- bpy.data.objects['Armature'].pose.bones[1].matrix = M2
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('rotation_quaternion')
- M3 = Matrix.Translation(Vector((0, 5, 7)))
- bpy.data.objects['Armature'].pose.bones[2].matrix = M3
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('rotation_quaternion')
- bpy.context.scene.frame_set(5)
- M1 = Matrix.Translation(Vector((0, 0, 0)))
- bpy.data.objects['Armature'].pose.bones[0].matrix = M1
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[0].keyframe_insert('rotation_quaternion')
- M2 = Matrix.Translation(Vector((0, 2, 4)))
- bpy.data.objects['Armature'].pose.bones[1].matrix = M2
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[1].keyframe_insert('rotation_quaternion')
- M3 = Matrix.Translation(Vector((0, 6, 8)))
- bpy.data.objects['Armature'].pose.bones[2].matrix = M3
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('location')
- bpy.data.objects['Armature'].pose.bones[2].keyframe_insert('rotation_quaternion')
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement