Search Unity

  1. Looking for a job or to hire someone for a project? Check out the re-opened job forums.
    Dismiss Notice
  2. Unity 2020 LTS & Unity 2021.1 have been released.
    Dismiss Notice
  3. Good news ✨ We have more Unite Now videos available for you to watch on-demand! Come check them out and ask our experts any questions!
    Dismiss Notice

Unity 2D Animation is out of preview for 2019.3

Discussion in '2D' started by rustum, Jan 30, 2020.

  1. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    Hello @EvOne,
    It seems you have the project setup in the correct way. It could be that the preview 2D Animation package for 2021 didn't make it into the beta version that you are using. I'll pull down the same version just to verify what went wrong there.
    In the meantime, you can follow these steps to manually bump the package version. Do note for anyone else who would like to manually update the package version, that 2D Animation 6.x requires Unity 2021.1.

    1. Open the Packages folder in your Unity Project
    2. Open the manifest.json file
    3. Update the following lines:
    "com.unity.2d.animation": "5.0.4",
    "com.unity.2d.psdimporter": "4.0.2",
    to
    "com.unity.2d.animation": "6.0.0-pre.2",
    "com.unity.2d.psdimporter": "5.0.0-pre.2",

    Give that a go @EvOne, and I'll get back to you once I've tested out the same editor version you are using.
     
    EvOne likes this.
  2. EvOne

    EvOne

    Joined:
    Jan 29, 2016
    Posts:
    122
    Thank You!:)

    i updated the package and everything started fine, the PSB files processed in earlier versions of the package were re-imported, everything works.

    Ok, I'm trying to import from scratch...

    But ... I don't understand ...
    -In my old files I did not see the "single identifier" - "Sprite Key hash", that you discussed above
    "Сategories" and "Labels" are still visible there
    -And the library component shows them and the spriteswapper changes, but ...

    -How to set all this with the newly imported PSB-file, considering the changes?

    from changelog:
    "[6.0.0-pre.1] - 2020-11-02

    Changed

    • Sprite Swap related features moved out of experimental namespace
    • Removed editing of Sprite Swap feature in Skinning Module
    • Updated Sprite Swap workflow focusing on Project Window and Inspector "
    Ok... see an opportunity to create a SpriteLibrary, add a Category, give it a name
    add Entry point... wait ...
    Wait...
    Previously, this could be done by selecting the "Convert Group / Layer to Category" item from context menu, _automatically_
    but now?

    Is it really just to manually name the Сategories and distribute sprites to the desired fields? 0_o
    ALL these variants of sprites that will change, -manually?

    No-no ... This can't be!.. :eek:
    Looking into the documentation ...
    Oh... it looks like it hasn't been updated yet ...
     
    Last edited: Feb 18, 2021
  3. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    So first off, I pulled down the same version you are using @EvOne, to see if I can reproduce the issue with not being able to find the 2D Animation 6.0.0-pre.2 package.
    These are the steps I took:
    1. Create a new project with Unity 2021.1.0b7.1944, using the 2D template
    2. Verify that the new project comes with 2D Animation 5.0.3
    3. Go to the Project Settings > Package Manager and Enable Pre-release packages
    4. Open the Package Manager
    6. Verify that my view in Package Manager is In Project
    7. Find 2D Animation in the list of packages and expand the section
    8. At the top of the list of 2D Animation versions is 2D Animation 6.0.0-pre.2

    Could you walk me through the steps you took when you were unable to see the package?

    Secondly, let's look into the feedback. Although I must say that the format is a bit tricky to read, so let me know if I missed anything.

    The previous code path is still in the package, so going from 2D Animation 5.x to 6.x will not break your animation clips. Any new animation clips created in 6.x will use the Sprite Key Hash instead of Category and Label.

    Not sure what you mean, could you elaborate?

    Yes, this context menu is no longer available in 6.x. We want to unify the SpriteLibrary workflow between .psb files and other image files. The context menu was only available for .psb files, which caused confusion. Any feedback on how you would like to see this workflow is appreciated.

    We are currently working on updating the documentation for 6.x, and it will be available in a future update. What information where you looking to find in the documentation?

    Thanks again for testing the package out and giving us feedback, this helps us creating a better package.
     
    EvOne likes this.
  4. EvOne

    EvOne

    Joined:
    Jan 29, 2016
    Posts:
    122
    I beg your pardon - English is not my native language, and relying entirely on Google translate - as you can see, leads to misunderstandings. :oops:
    I will try to describe everything in detail and formulate it as correctly as possible.
    But it will take a little time ...

    Thank you for your participation!:)
     
    Ted_Wikman likes this.
  5. alexlamar

    alexlamar

    Joined:
    Jan 16, 2014
    Posts:
    2
    @Ted_Wikman,
    Thanks for pointing me to the RuntimeSwap example! The SpriteLibrary.AddOverride API works great, and I've been able to successfully restructure around it.

    While I'm here -- I know there's been talk about bringing in SpriteSwap support for sprites with different bone hierarchies. Is that something that's on the roadmap? I just wanted to echo how useful it would be to be able to swap in different components with fundamentally different structures (i.e. a cape for a set of wings, as a contrived example) using a native interface.
     
  6. ErdTod

    ErdTod

    Joined:
    Jan 7, 2018
    Posts:
    8
    How is 2D Animation package "is ready for use" if it's performance is ass (like, a lot of ass) without an experimental package that isn't even listed when you enable experimental packages and you have to reference it with a direct link, and then it still doesn't work?.. </end angry forum post>
     
    EvOne likes this.
  7. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    @alexlamar awesome that the RuntimeSwap example could be of help!

    For your second question, in 2D Animation 6.0.0, we have added the ability to toggle an auto rebind action in the SpriteSkin. This action will trigger the SpriteSkin to try to find and rebind the bones that a new Sprite is requiring. Note that the transforms has to already exist in the GameObjects hierarchy for this to work. It will not create new transforms if the transforms cannot be found.
    You can read a bit more here: https://docs.unity3d.com/Packages/com.unity.2d.animation@6.0/manual/SLAsset.html#auto-rebind
    and let us know if you have any questions!
     
    EvOne likes this.
  8. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    Hello @ErdTod,
    If you would like us to act on your feedback, do provide some actual data on the issues you are experiencing. Without it, it is only a rant post.
    Thanks.
     
  9. ErdTod

    ErdTod

    Joined:
    Jan 7, 2018
    Posts:
    8
    Nope, I just wanted to make an angry forum post at the moment of emotional frustration. No constructive feedback yet!
     
  10. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    343
    You will need to enable pre-release packages in the Project settings -> package manager
    upload_2021-3-1_13-55-31.png
     
    EvOne likes this.
  11. indie6

    indie6

    Joined:
    Dec 15, 2012
    Posts:
    55
    Hi!

    Is there a way to automate "bone creation" and "auto geometry" via scripting? I want to create bones with exact length and distance from other bones, which is impossible to do with a mouse manually
     
    Last edited: Mar 21, 2021
    EvOne likes this.
  12. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    Hello @indie6,
    Currently there is no convenient way to update the Sprite's bone or mesh meta data. The only way to do it would be for you to create your own authoring module (See SpritePostProcess.cs if you are interested).

    If we could improve on the bone creation experience so that you could set the position, rotation and length of the bones, would that solve your issue?
    And what problem would you like to solve by being able to trigger the mesh generation from code?
     
  13. indie6

    indie6

    Joined:
    Dec 15, 2012
    Posts:
    55
    Thanks I'll check the SpritePostProcess script

    For improvement, it would be great if you can add some snapping functionality for rotation and length of bones. For e.g rotating at 15, 30, 45 degree

    I have different circular sprites with different sizes and I want them to have
    - bones with an exact difference of 45 degree
    - bones with exact same length for each sprite

    Thanks and have a nice day!
     
  14. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    Great, thanks for the feedback!
     
  15. Leo-Yaik

    Leo-Yaik

    Unity Technologies

    Joined:
    Aug 13, 2014
    Posts:
    343
    Hi, could we get a sample project to take a look?

    It sounds familiar and might be something we already fixed. Would it possible for you to try it on the LTS version 19.4 with the latest packages?
     
  16. SaltwaterAssembly

    SaltwaterAssembly

    Joined:
    Mar 8, 2016
    Posts:
    94
    Getting this error when we downgraded unity from 2021 to 2020:
    upload_2021-4-21_11-2-12.png

    Can't seem to resolve this, please help.
     
  17. Ted_Wikman

    Ted_Wikman

    Unity Technologies

    Joined:
    Oct 7, 2019
    Posts:
    357
    @SaltwaterAssembly it is in general never safe to downgrade Unity projects to an older version. You could try to remove the .meta files and let Unity re-generate those files. But be aware that your edited data will be lost.
    What is the reason for the downgrade in the first place?
     
unityunity