我在使用Unity製作遊戲時,有個場景的Spine動畫需要使用Spine/Skeleton Lit的Shader,以配合環境光變色,但我在另一場景使用SkeltonRenderTextureFadeout.cs或是我修改的SkeltonRenderTextureFadein.cs時,卻會出現角色變成深黑色而非正常顯示顏色的狀況(若使用Spine/Skeleton Fill的Shader可以正常Fadein/Fadeout,但就無法與環境光配合變色了),想請問我該怎麼辦呢?
有關Unity的Shader使用
Unfortunately, the RenderTexture
workflow in Unity is a bit limited and can only handle certain lighting setup. There are basically two ways:
1) Render the skeleton to the RenderTexture with an unlit shader,
and then render the RenderTexture quad to the screen with a lit shader.
2) Render the skeleton to the RenderTexture with a lit shader,
and then render the RenderTexture quad to the screen with an unlit shader.
Which of the two ways are you currently utilizing? In other words, which shaders are used at the skeleton, and which at the RenderTexture quad?
@markcky2433 If possible, could you please send us a minimal Unity project which still shows your issue? You can send it as a zip file to contact@esotericsoftware.com, briefly mentioning this forum thread URL so that we know the context. Then we can have a look at it.