go edit mode func
parent
a021535b3f
commit
ef566c494f
12
utils.py
12
utils.py
|
@ -1100,4 +1100,14 @@ def create_follow_path_constraint(ob, curve, follow_curve=False):
|
||||||
# const.forward_axis = orentation_track_from_vector(root_world_base_direction) # 'TRACK_NEGATIVE_Y' # bpy.context.scene.anim_cycle_settings.forward_axis # 'FORWARD_X'
|
# const.forward_axis = orentation_track_from_vector(root_world_base_direction) # 'TRACK_NEGATIVE_Y' # bpy.context.scene.anim_cycle_settings.forward_axis # 'FORWARD_X'
|
||||||
# print('const.forward_axis: ', const.forward_axis)
|
# print('const.forward_axis: ', const.forward_axis)
|
||||||
# const.use_curve_follow = True
|
# const.use_curve_follow = True
|
||||||
# return curve, const
|
# return curve, const
|
||||||
|
|
||||||
|
def go_edit_mode(ob, context=None):
|
||||||
|
'''set mode to object, set passed obhject as active and go Edit'''
|
||||||
|
|
||||||
|
context = context or bpy.context
|
||||||
|
bpy.ops.object.mode_set(mode='OBJECT', toggle=False)
|
||||||
|
ob.select_set(True)
|
||||||
|
context.view_layer.objects.active = ob
|
||||||
|
bpy.ops.object.mode_set(mode='EDIT', toggle=False)
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue