I'm using Unity with spine assets, in URP. The characters use a designated material made with shadergraph and the material is applied within the designated Spine Atlas Asset.
This material functionality works perfectly fine in terms of functionality. I can edit the parameters such as specific colours perfectly fine, and I can adjust which graphic it uses too. However, if I were to change a setting on, or fully reimport, the mainTex art asset, the custom material gets fully deleted, and the Spine Atlas Asset switches to using the default generated material instead.
When the custom material doesn't have an asset with the correct name in the mainTex slot, it throws a few errors, so perhaps that has something to do with it. Maybe when the material is being refreshed due to the asset updating, some check doesn't see the asset as existing and thus hits an eject button. That's my current theory for the situation at least.
I am working in unity 6000.0.32f1
and using spine installed with the package called: spine-unity-4.2-2024-09-12
Changing settings on the art asset throws logs in the chat:
Player Character Purple_Final_Atlas :: Imported with 1 material
UnityEngine.Debug:Log (object,UnityEngine.Object)
Spine.Unity.Editor.AssetUtility:IngestSpineAtlas (UnityEngine.TextAsset,System.Collections.Generic.List`1<string>) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:733)
Spine.Unity.Editor.AssetUtility:ImportSpineContent (string[],System.Collections.Generic.List`1<string>,bool) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:403)
Spine.Unity.Editor.AssetUtility:HandleOnPostprocessAllAssets (string[],System.Collections.Generic.List`1<string>) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:118)
Spine.Unity.Editor.SpineEditorUtilities:OnPostprocessAllAssets (string[],string[],string[],string[]) (at Assets/Spine/Editor/spine-unity/Editor/Utility/SpineEditorUtilities.cs:102)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)
and also:
Changes to 'Assets/Characters/Player1/Player Character Purple_Final.json' or atlas detected. Clearing SkeletonDataAsset: Assets/Characters/Player1/Player Character Purple_Final_SkeletonData.asset
UnityEngine.Debug:LogFormat (string,object[])
Spine.Unity.Editor.AssetUtility:ReloadSkeletonData (string,Spine.Unity.SkeletonDataCompatibility/CompatibilityProblemInfo) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:578)
Spine.Unity.Editor.AssetUtility:ImportSpineContent (string[],System.Collections.Generic.List`1<string>,bool) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:419)
Spine.Unity.Editor.AssetUtility:HandleOnPostprocessAllAssets (string[],System.Collections.Generic.List`1<string>) (at Assets/Spine/Editor/spine-unity/Editor/Utility/AssetUtility.cs:118)
Spine.Unity.Editor.SpineEditorUtilities:OnPostprocessAllAssets (string[],string[],string[],string[]) (at Assets/Spine/Editor/spine-unity/Editor/Utility/SpineEditorUtilities.cs:102)
UnityEngine.GUIUtility:ProcessEvent (int,intptr,bool&)