Brushstroke Tools: Initial Version #328
@ -50,6 +50,19 @@ def mark_socket_context_type(mod_info, socket_name, link_type):
|
||||
socket_info.name = socket_name
|
||||
socket_info.link_context_type = link_type
|
||||
|
||||
def deep_copy_mod_info(source_object, target_object):
|
||||
for mod_info in source_object.modifier_info:
|
||||
mod_info_tgt = target_object.modifier_info.add()
|
||||
for attr in mod_info.keys():
|
||||
if attr == 'socket_info':
|
||||
continue
|
||||
setattr(mod_info_tgt, attr, getattr(mod_info, attr))
|
||||
for socket_info in mod_info.socket_info:
|
||||
socket_info_tgt = mod_info_tgt.socket_info.add()
|
||||
for attr in socket_info.keys():
|
||||
setattr(socket_info_tgt, attr, getattr(socket_info, attr))
|
||||
|
||||
|
||||
def get_addon_directory() -> str:
|
||||
"""
|
||||
Returns the path of the addon directory to be used to append resource data-blocks.
|
||||
|
Loading…
Reference in New Issue
Block a user