Asset Pipeline v2 #145
@ -25,21 +25,18 @@ class AssetTransferMapping:
|
||||
external_coll: bpy.types.Collection,
|
||||
local_tls: Set[str],
|
||||
):
|
||||
# TODO Check if any of the below properties can be removed
|
||||
self._local_col = local_coll
|
||||
self._external_col = external_coll
|
||||
self._local_tls = local_tls
|
||||
|
||||
self.local_obj_to_remove: Set[bpy.types.Object] = set()
|
||||
self.external_obj_to_add: Set[bpy.types.Object] = set()
|
||||
self._no_match_source_objs: Set[bpy.types.Object] = set()
|
||||
self._no_match_target_objs: Set[bpy.types.Object] = set()
|
||||
|
||||
self._no_match_source_colls: Set[bpy.types.Object] = set()
|
||||
self._no_match_target_colls: Set[bpy.types.Object] = set()
|
||||
|
||||
self.conflict_ids = []
|
||||
self.conflict_trasnfer_data = []
|
||||
self.conflict_ids: list[bpy.types.ID] = []
|
||||
self.conflict_transfer_data = [] # Item of bpy.types.CollectionProperty
|
||||
|
||||
self.generate_mapping()
|
||||
|
||||
@ -160,7 +157,7 @@ class AssetTransferMapping:
|
||||
if check_transfer_data_item is None:
|
||||
return
|
||||
if check_transfer_data_item.owner != transfer_data_item.owner:
|
||||
self.conflict_trasnfer_data.append(transfer_data_item)
|
||||
self.conflict_transfer_data.append(transfer_data_item)
|
||||
print("CONFLICT FOUND")
|
||||
return True
|
||||
|
||||
|
@ -174,9 +174,9 @@ def merge_task_layer(
|
||||
|
||||
map = AssetTransferMapping(local_col, external_col, local_tls)
|
||||
|
||||
if len(map.conflict_trasnfer_data) != 0:
|
||||
if len(map.conflict_transfer_data) != 0:
|
||||
error_msg = ''
|
||||
for conflict in map.conflict_trasnfer_data:
|
||||
for conflict in map.conflict_transfer_data:
|
||||
error_msg += f"Transfer Data conflict found for '{conflict.name}' on obj '{conflict.id_data.name}'\n"
|
||||
return error_msg
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user