Asset Pipeline v2 #145

Closed
Nick Alberelli wants to merge 431 commits from (deleted):feature/asset-pipeline-v2 into main

When changing the target branch, be careful to rebase the branch in your fork to match. See documentation.
2 changed files with 14 additions and 0 deletions
Showing only changes of commit 0f2ce7fd10 - Show all commits

View File

@ -35,6 +35,9 @@ class AssetTransferMapping:
self._no_match_source_colls: Set[bpy.types.Object] = set()
self._no_match_target_colls: Set[bpy.types.Object] = set()
self.conflict_objects = []
self.conflict_trasnfer_data = []
self.generate_mapping()
def generate_mapping(self) -> None:
@ -67,12 +70,16 @@ class AssetTransferMapping:
if local_obj.asset_id_owner in self._local_tls:
external_obj = self._get_external_object(local_obj)
if external_obj:
if external_obj.asset_id_owner != local_obj.asset_id_owner:
self.conflict_objects.append(local_obj)
object_map[external_obj] = local_obj
# IF ITEM IS NOT OWNED BY LOCAL TASK LAYERS
else:
external_obj = self._get_external_object(local_obj)
if external_obj:
if external_obj.asset_id_owner != local_obj.asset_id_owner:
self.conflict_objects.append(local_obj)
object_map[local_obj] = external_obj
else:
# REMOVE OBJ NOT OWNED BY LOCAL TASK LAYER THAT HAS NO MATCH

View File

@ -168,6 +168,13 @@ def merge_task_layer(
for conflict in map.conflict_trasnfer_data:
error_msg += f"Transfer Data conflict found for '{conflict.name}' on obj '{conflict.id_data.name}'\n"
return error_msg
if len(map.conflict_objects) != 0:
error_msg = ''
for conflict_obj in map.conflict_objects:
error_msg += f"Ownership conflic found for '{conflict_obj.name}'\n"
return error_msg
# Remove all transfer data from target objects
for source_obj in map.object_map:
target_obj = map.object_map[source_obj]