Blender Asked by Seyed Morteza Kamali on January 27, 2021
I’m a beginner and I just want to set the location, rotation, and scale of the object.
I tried to get code by reverse engineering but when I moved, rotated, and scaled my object I saw complicated code.
if you want to get exact code you shouldn't change transform in view port. when you change the transform in this panel it works:
Location
import bpy
obj = bpy.context.object
obj.location = (0,0,0)
Rotation
import bpy
import math
obj = bpy.context.object
obj.rotation_euler = (0,math.radians(90),0)
Scale
import bpy
obj= bpy.context.object
obj.scale = (1,1,1)
Correct answer by Seyed Morteza Kamali on January 27, 2021
Get help from others!
Recent Answers
Recent Questions
© 2024 TransWikia.com. All rights reserved. Sites we Love: PCI Database, UKBizDB, Menu Kuliner, Sharing RPP