• Unity
  • Lit Universal Shader - FLIP ISSUE

Sorry to hear that your problem persists! Unfortunately, I can see nothing obviously wrong with your component and material settings.

Could you please send us a minimal Unity project that shows your issue? You can send it as a zip package to contact@esotericsoftware.com, briefly mentioning this forum thread URL so that we know the context. Then we can have a look at what's going wrong.

Related Discussions
...
4 ngày sau

Well yes, it seemed to be. Specially because I´ve used this config when not in URP and it worked well.
It will be litle harsh to export a small project, but I ll try me best here.

But this shaders are improved in 4.0 correct? Maybe upgrade Spine and Unity Pluggins will solve it?

Yes, these shaders have been improved in 4.0 and 4.1. For the complete changes on the URP shaders you can see the github history here:
https://github.com/EsotericSoftware/spine-runtimes/commits/4.1/spine-unity/Modules/com.esotericsoftware.spine.urp-shaders/Shaders

I just had a look, it might be that the following bugfix fixes your issue:
https://github.com/EsotericSoftware/spine-runtimes/commit/43e8000c80441d327252ac163c30aef486a52933

    8 tháng sau

    Harald Hi Harald,

    Sorry took me a while to write back, but we are updating to Unity 2021.3 LTS only today.
    One of the tasks from that update was to try to fix this lighting issue.

    I´ve tryied to include your solution, but it returned an error in: Spine-Sprite-ForwardPass-URP
    Please find attached.

    • Harald đã trả lời bài viết này.

      Sorry to hear you're facing issues after upgrading Unity.

      Which version of the Spine URP shaders (name of the zip package) are you using?
      Wich version of Unity's Universal RP package?

      Are you using the latest version of the Spine URP shaders UPM package (as I assume you are still on 4.0, are you using the latest 4.0 package?). If so, could you please send us a minimal Unity project that still demonstrates this issue? You can send it as a zip package to contact@esotericsoftware.com, briefly mentioning this forum thread URL so that we know the context.

        • Đã chỉnh sửa

        Harald

        Which version of the Spine URP shaders (name of the zip package) are you using?
        com.esotericsoftware.spine.urp-shaders-3.8-Unity2019.3-2021-03-04
        spine-unity-3.8-2021-11-10.unitypackage

        Wich version of Unity's Universal RP package?
        UNIVERSAL RP: Version 12.1.10 - February 07, 2023 (latest)
        HYBRID RENDERER: Version 0.51.1-preview.21 (latest)

        Our project is using Spine 3.8 - But I am considering upgrade it to 4.0 if no solution is found in 3.8. Specially since you mentioned previously that in 4.0 this issue is no longer present.

        Looking into making this minimal Unity project if nothing works. Harald,
        I´ve tested with the mentioned packages, and the issue is replicated.
        Was not required to use our own files. Please find below:

        Below is the same test with Spine 4 (same Unity)

        Sorry I didn't get all the context in my reply yesterday, just noticed that you already wrote you were using 3.8.

        decoamorim I´ve tryied to include your solution, but it returned an error in: Spine-Sprite-ForwardPass-URP
        Please find attached.

        Judging the error message, the bigfix commit that I recommended has not been integrated into your 3.8 Spine URP shaders package properly. The commit that I mentioned is this one, which does not touch the URP 2D Skeleton Lit shader, which causes errors to appear in your Console window. Please be sure to apply bugfix commits carefully.

        If possible, we would of course recommend upgrading the spine-unity runtime from 3.8 to the most recent version, which is 4.1. Just be aware that all skeleton assets need to be re-exported for 4.1 accordingly.

          • Đã chỉnh sửa

          Hi Harald ,
          It seems that the page I am being redirected in your "this one" link, is the same as your previous link provided. Gonna run it again to be 100%.

          But at the moment I am updating the project to 4.0, this already solved the lighting issue. Because we have a lot os spine files to export, this was my last option. Can you confirm if the below is expected when updating to 4.0:

          The exported files do not substitute the previous ones, the process seems to be considering the Spine file name instead of the Skeleton name given inside Spine. Though, continue to use the previous files and materials as the main ones in the Game Object.

          Ok solution was simple, just named de file as the skeleton was named. They both merged.
          We are moving forward updating to spine 4.0 or maybe 4.1.
          For that I dont need to update each file twice, correct? After updating Unity, just have to export all Spine files to 4.1?

          • Harald đã trả lời bài viết này.
            • Đã chỉnh sửa

            decoamorim Hi Harald ,
            It seems that the page I am being redirected in your "this one" link, is the same as your previous link provided. Gonna run it again to be 100%.

            Yes, because this is the one bugfix commit which I recommend porting to your older 3.8 package. Since your received error messages which are from another shader file than the files that are modified by the referenced commit, I pointed you to the same commit again, since something seems to have gone wrong with integrating the changes the first time.

            decoamorim But at the moment I am updating the project to 4.0, this already solved the lighting issue. Because we have a lot os spine files to export, this was my last option. Can you confirm if the below is expected when updating to 4.0:

            Glad to hear you are going with updating your Spine and spine-unity runtime version!
            Regarding the atlas name: It defaults to the filename, however you can set a custom name when exporting or packing via the Command Line Interface (CLI):
            http://en.esotericsoftware.com/spine-command-line-interface#Pack

            In general we very much recommend setting up scripts for automated export, as this allows you to re-export all your skeletons with one go, instead of tedious manual work.

            You can find spine-unity upgrade guides for 3.8 to 4.0 and 4.0 to 4.1 here, as well as two links on setting up a command line export script:
            http://esotericsoftware.com/spine-unity#Updating-the-spine-unity-Runtime

            decoamorim We are moving forward updating to spine 4.0 or maybe 4.1.
            For that I dont need to update each file twice, correct? After updating Unity, just have to export all Spine files to 4.1?

            Exactly, you can open and export your 3.8 Spine project in 4.1 and export it from there in one go, there is no need to open the 3.8 project in Spine 4.0, save it and then open it in Spine 4.1.

            You can also replace the spine-unity 3.8 runtime directly with the 4.1 runtime (be sure to remove the 3.8 runtime first as described in the documentation). You just need to perform the modifications of your own code according to the upgrade steps described in "Adapting your code to 4.0 API changes" and "Adapting your code to 4.1 API changes" in the upgrade guides below, one after another:
            https://esotericsoftware.com/forum/d/15981-spine-unity-38-to-40-upgrade-guide
            https://esotericsoftware.com/forum/d/17699-spine-unity-40-to-41-upgrade-guide

              Harald
              We are moving forward to update the project to Spine 4.1.

              At the moment, everything seems to be running smooth. In addition to the lighting issue being fixed, it seems that there is a graphic upgrade from 3.8 to 4.1.

              Thank you for all information and the amazing support!

              Glad to hear everything is going alright with the update, thanks for your kind words! 🙂