Home / Merged error reference / 79

SpriteAtlasManager class registration and scene reference trio (ExtensionOfNativeClass / runtime script / not MonoBehaviour)

Covers IDs: U06, U07, U08 · Engine: Unity

U06 · Unity

‘SpriteAtlasManager’ is missing the class attribute ‘ExtensionOfNativeClass’!
Verification
原文命中(抓取页面)
Frequency
论坛点赞=0

Trigger: Importing a third-party/legacy asset package and running its demo scene, where a scene object references the SpriteAtlasManager managed class; the Console errors when managed class and native wrapper registration mismatch. English Unity log.

Typical cause: Native classes exported to the managed layer need the ExtensionOfNativeClass attribute; if the managed SpriteAtlasManager lacks it, or the package version/assembly mismatches the engine and serialization retains an old class name, the native binding cannot find a matching class.

Step-by-step fix:
  1. Upgrade the asset package to a version matching the current engine.
  2. Remove the broken SpriteAtlasManager object reference in the scene and re-serialize.
  3. Clear the Library/Artifacts cache and reopen the project.
  4. Confirm com.unity.2d.sprite and ugui package versions match the engine.

Per-entry sources and capture date are listed at /sources#U06.

U07 · Unity

GameObject (named ‘Sprite Atlas’) references runtime script in scene file. Fixing!
Verification
原文命中(抓取页面)
Frequency
论坛点赞=0

Trigger: A GameObject named 'Sprite Atlas' in the scene file references a runtime script that cannot currently be resolved; opening the scene logs this warning in the Console, often in the same batch as ExtensionOfNativeClass and component-type warnings.

Typical cause: The scene serialization saved a script reference, but that script cannot be resolved in the current project assemblies (class removed/renamed, assembly not loaded), so the serialized reference is invalid.

Step-by-step fix:
  1. Select the object in the Hierarchy, remove the Missing (Mono Script) component in the Inspector, then reattach the correct script.
  2. Check the asset package assembly definition and engine version compatibility.
  3. Re-save the scene.

Per-entry sources and capture date are listed at /sources#U07.

U08 · Unity

The class named ‘SpriteAtlasManager’ is not derived from MonoBehaviour or ScriptableObject!
Verification
原文命中(抓取页面)
Frequency
论坛点赞=0

Trigger: SpriteAtlasManager is attached as a component script on a scene/prefab, or a serialized reference points to this class; the Console warns, in the same batch as the ExtensionOfNativeClass error and runtime script warning.

Typical cause: SpriteAtlasManager is a static manager class (static events atlasRequested / atlasRegistered), not a MonoBehaviour or ScriptableObject; it cannot be attached as a component to a GameObject, and the serialization system rejects it on component-type validation.

Step-by-step fix:
  1. Do not attach SpriteAtlasManager as a component.
  2. Use a plain C# script to register the callback with SpriteAtlasManager.atlasRequested += OnAtlasRequested in Awake/OnEnable, and -= unregister in OnDisable.
  3. Remove the erroneous component reference to this class on the object.

Per-entry sources and capture date are listed at /sources#U08.

Related errors

Need an offline quick-reference checklist?

Atlas error library Pro pack: 123 error references (110 single + 13 merged) plus a quick-fix guide, $19 one-time purchase, delivered as electronic files.

View Pro pack / order