Introducing Unity Project Auditor: a tool to help you optimize your Unity projects!

This is a great package and I already try to use it as much as possible but I’m facing several issues :

  • warning UDR0005: Static event has non-static callbacks should have an OnDestroy method and use it to deregister the callbacks
    This warning is an issue for me knowing it pops even if the issue comes from a class which is not a MonoBehaviour (such as a ScriptableObject, an EditorWindow or even an Overlay
  • warning UDR0001: No method with [RuntimeInitializeOnLoadMethod] attribute
    Same issue as previously, is it require to do such a thing in EditorWindow or any Editor script at all?
  • Analysis in Project Auditor should have a way to define the scope to specific assemblies ALL THE TIME (such as Assembly-CSharp and any other assemblies we chose). A project can have many other assemblies and generally we don’t want to debug assemblies we don’t own.
  • Would be nice to have a way to exclude boxing issues when it is coming from string concatenation using $“”
  • Would be nice to have a way to exclude class, file(s) or folder(s) from being reviewed if possible
  • Some UnityEngine methods are reported as Major issue even when the non allocating version of this method is already in use (such as GetComponentsInChildren or CalculateFrustumPlanes)
  • The Object.name property allocates managed memory.
    Would be nice to have a way to ignore such issue. Our project is using a lot GameObject.name for debug purpose and I don’t know how we could do that differently!
3 Likes