I know you can find the path of the script file if you have an instance:
`AssetDatabase.GetAssetPath(MonoScript.FromScriptableObject(instance));`
However it seems odd to me that you need to have an instance of the object to get the path of the script. I need this in a static method so I don't have any reference to an object and it seems odd to just create a new instance for just finding the path.
Is there a way to do it with something like typeof(ClassName)?
↧