Skip to content

Commit

Permalink
fix: OverflowException when create prefab
Browse files Browse the repository at this point in the history
  • Loading branch information
anatawa12 committed Dec 8, 2024
1 parent a681655 commit 4165579
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ public static void OnValidate<TComponent>(TComponent component,
PrefabSafeUniqueCollection.NestCount = nestCount;

var shouldUsePrefabOnSceneLayer =
PSUCRuntimeUtil.ShouldUsePrefabOnSceneLayer(component);
nestCount != 0 && PSUCRuntimeUtil.ShouldUsePrefabOnSceneLayer(component);
var maxLayerCount = shouldUsePrefabOnSceneLayer ? nestCount - 1 : nestCount;

// https://github.com/anatawa12/AvatarOptimizer/issues/52
Expand Down

0 comments on commit 4165579

Please sign in to comment.