[Bug] Divide by zero issue in MecanimSetLayerWeight

Forums 💬 NodeCanvas ⚙️ Support [Bug] Divide by zero issue in MecanimSetLayerWeight

Viewing 2 posts - 1 through 2 (of 2 total)
  • Author
    Posts
  • #15906
    hellhound
    Participant

      Hi,

      I found a divide by zero issue using the animator ActionTask MecanimSetLayerWeight. If the transitTime variable is set to zero, the setting of the animator layer wight causes in NaN failure .

      A simple quick fix is to calculate the layer wight regarding this possible zero value before setting it to animator component in OnUpdate method:

      Best regards,
       Christian

       

       

      #15907
      Gavalakis
      Keymaster

        Hello Christian,

        Thank you for the fix! 🙂

      Viewing 2 posts - 1 through 2 (of 2 total)
      • You must be logged in to reply to this topic.