I keep getting Asset path error with PrefabUtility.SaveAsPrefabAsset

Hi I’m trying to make a function that makes objects in hierarchy into prefabs. but I keep getting this error.

I tried “”, “Assets/”, “Assets”, and etc but all of them keep giving me this path error. I’m not sure whats wrong.

Prefabs have to be saved with the extension “.prefab”.

The old utilities used to have a more explicit error message in this situation, odd that they’ve changed it to this unhelpful one.

You might want to think about giving them different names, too.