Search Unity

  1. Calling all beginners! Join the FPS Beginners Mods Challenge until December 13.
    Dismiss Notice
  2. It's Cyber Week at the Asset Store!
    Dismiss Notice

Puppet2D - An advanced skeletal animation tool

Discussion in 'Assets and Asset Store' started by jamieniman, Dec 31, 2013.

  1. Recon03

    Recon03

    Joined:
    Aug 5, 2013
    Posts:
    439
    I checked and did not see it on sale with everything else, and was disappointed so I checked the asset itself and bam!! It was on sale finally was able to buy it after almost a year. Thanks! I been checking daily for almost a year for this to be on sale... lol...
     
  2. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    I'm glad you didn't miss it then!

    Puppet2D is on Sale! 50% Off. Limited Time Offer!
     
  3. PaulAfello

    PaulAfello

    Joined:
    Sep 19, 2015
    Posts:
    15
    I do not seem able to make Puppet2D work after upgrading to Unity 5.2 :(

    I reimported Puppet2D multiple times now in all the different ways I could think of. Problem stays the same: Old animations are broke and the Puppet2D window/tab is not working. The tab does show up but without the content, I am barely able to drag it around and am not able to close it. If you need more information let me know!

    Thanks in advance
     
  4. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    You must be getting console errors.
    Could you send me some so I can better see what is breaking.
    If the errors are long you can send them to puppet2d@gmail.com
     
  5. PaulAfello

    PaulAfello

    Joined:
    Sep 19, 2015
    Posts:
    15
    As soon as I open the Puppet2D window and start dragging it around or try to close it, it gives this message in the console:

    NullReferenceException: Object reference not set to an instance of an object
    Puppet2D_Editor.OnGUI () (at Assets/Plugins/Puppet2D/Scripts/Editor/Puppet2D_Editor.cs:167)
    System.Reflection.MonoMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) (at /Users/builduser/buildslave/mono-runtime-and-classlibs/build/mcs/class/corlib/System.Reflection/MonoMethod.cs:222)

    Will include this the next time I might get an error I cannot fix, thanks for your patience!
     
  6. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Could you check your puppet2d folder and see if you have:
    Puppet2D/Textures/GUI/BoneScaled.psd
     
  7. PaulAfello

    PaulAfello

    Joined:
    Sep 19, 2015
    Posts:
    15
    That fixed it, thanks! I did not select that folder while reimporting for I thought it only contained files for the example projects. Maybe it would be an idea to separate example files and necessary files more clearly when importing? Beside this minor hick up I am very happy with Puppet2D, it such a great animation tool!
     
  8. Yangsheng-Cheng

    Yangsheng-Cheng

    Joined:
    Apr 3, 2015
    Posts:
    7
    Hey, @jamieniman,
    I have 3 questions:
    1. How about the performance of Puppet2D? Can I create 180+ simple skeletal animations in a scene?
    2. Can I directly change the sprite of a bone from script?
    3. Is there a way to convert skeletal animation data from other tools to Puppet2D?
     
  9. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Thats possible, if you go for a more optimised setup (eg parented sprites would perform better than skinned meshes)
    To learn more about performance see here:
    http://www.puppet2d.com/#!performance-tips/c22l9
    yes, although the bones aren't intended to be visible in game - there more visible helpers for rigging.
    I haven't looked into this really - in theory it would be possible, but i'm not sure if it would be straight forward.
     
  10. Happygallo

    Happygallo

    Joined:
    Aug 27, 2014
    Posts:
    4
    I have this problem with FFD: Screen Shot 2015-09-28 at 7.43.07 PM.png Screen Shot 2015-09-28 at 7.43.23 PM.png Screen Shot 2015-09-28 at 7.43.33 PM.png Screen Shot 2015-09-28 at 7.43.07 PM.png Screen Shot 2015-09-28 at 7.43.23 PM.png Screen Shot 2015-09-28 at 7.43.33 PM.png
     
  11. atmuc

    atmuc

    Joined:
    Feb 28, 2011
    Posts:
    1,035
    i have body, clothes and hair sprites/meshes. i plan to sell clothes in my game. is it possible to make them as separate prefabs for the same rig? i want to make them downloadable resource pack.
     
  12. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Make sure your sprite image is:
    - square
    - power of 2
    - has mip mapping turned off
     
    Happygallo likes this.
  13. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    I'm thinking that one option would be to have a duplicate of the bones with the skinned mesh attached, and then you could parent each of the bones to rigged&animated bones in code. That way the downloadable resource will be simple and clean.
     
  14. berdanka

    berdanka

    Joined:
    Sep 29, 2015
    Posts:
    5
    Thank you for a wonderful Asset.
    I have a problem here.
    When I create an FFD surface and try to add a Physics 2D (spring joint for example) component to the FFD bone, it works.
    But when I try to turn off the FFD_visibility in Global_CTRL settings, all my components of FFD bones become disabled.
    However, this does not happen with Controls and Controls_visibility. When I disable it, Physics 2D continues to work with Controls of bones.

    What can I do to hide FFD and does not affect the activity of FFD bones components?
     
  15. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    in the Puppet2D_GlobalControl.cs script change lines 123 & 124 to

    Code (CSharp):
    1. if(ffdCtrl)
    2. ffdCtrl.transform.GetComponent<SpriteRenderer>().enabled = FFD_Visiblity;
     
  16. Gozdek

    Gozdek

    Joined:
    Jun 21, 2015
    Posts:
    356
    Nice Work
     
  17. berdanka

    berdanka

    Joined:
    Sep 29, 2015
    Posts:
    5
    Thank you. It works now.
     
  18. Caffeen

    Caffeen

    Joined:
    Dec 25, 2013
    Posts:
    28
    Hi, as of 5.2 my console gets spammed with the following error message:

    UnassignedReferenceException: The variable topJointTransform of Puppet2D_IKHandle has not been assigned.
    You probably need to assign the topJointTransform variable of the Puppet2D_IKHandle script in the inspector.
    UnityEngine.Transform.get_position () (at C:/buildslave/unity/build/artifacts/generated/common/runtime/UnityEngineTransformBindings.gen.cs:20)
    Puppet2D_IKHandle.CalculateIK () (at Assets/Puppet2D/Scripts/Puppet2D_IKHandle.cs:85)
    Puppet2D_GlobalControl.Run () (at Assets/Puppet2D/Scripts/Puppet2D_GlobalControl.cs:264)
    Puppet2D_GlobalControl.LateUpdate () (at Assets/Puppet2D/Scripts/Puppet2D_GlobalControl.cs:220)

    Any idea what I broke? Thanks in advance.
     
  19. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    That looks like you have lost the assignments to your IK controls variables.
    Usually thats a bad sign of things going wrong on update - do you have a backed up version to try updating it again?
     
  20. DeadendX

    DeadendX

    Joined:
    Oct 3, 2015
    Posts:
    1
    Hi there! I want to start using the product but i need something explained!About puppet creation.I saw in the videos that the spines can be created kinda automatically. (with 3 nodes)But what if in the drawing i break the spine into 2 parts -upper and lower and make the character sit for example.If the puppet is created via photoshop or whatever (with inks and colour) i guess there will be deformation and weirdness.Are there ways to do this without ruining the art and have a natural animation?Thanks in regards!
     
  21. mogwhy

    mogwhy

    Joined:
    Nov 20, 2014
    Posts:
    36
    i also got these errors when updating.
    i reverted back to 5.1.3

    UnassignedReferenceException: The variable topJointTransform of Puppet2D_IKHandle has not been assigned.
    You probably need to assign the topJointTransform variable of the Puppet2D_IKHandle script in the inspector.
    UnityEngine.Transform.get_position () (at
     
  22. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    What can happen when you update to 5.2 is variables that are stored in prefab scripts lose their assignment somehow.
    Its really annoying - as it breaks lots of things.

    Try opening the project in an older version, exporting all the p2d assets as a package, and then import that package into the project in 5.2.
     
  23. boorch

    boorch

    Joined:
    Oct 7, 2015
    Posts:
    33
    hi guys,
    is there any way to prevent (freeze?) Z rotation of a piece when i move a bone?
     
  24. TurboNuke

    TurboNuke

    Joined:
    Dec 20, 2014
    Posts:
    63
    Great product so far, thanks.

    Quick tip for anyone with performance issues:
    I was having a look at the profiler in-game and found that Puppet2D_HiddenBone.LateUpdate was taking 6-7% of my frame on android. Looking at the code it would seem that it's only necessary in Edit mode.
    Just having a LateUpdate function in 100s of bones is causing the spike, even though it's not doing very much in there, so I've simply surrounded the LateUpdate function with an [#if UNITY_EDITOR ] block. That's 7% back from my frame time. :)
     
  25. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    I'll look to fixing this for the next release
     
    TurboNuke likes this.
  26. Diet-Chugg

    Diet-Chugg

    Joined:
    Jul 4, 2012
    Posts:
    51
    Do you have/ or could make a tutorial video on using the FFD tool that has audio. I found this tutorial but it doesn't explain how to do it:


    I also didn't see it in the walk through.

    Thanks,
    Michael Chugg
     
  27. Maui-M

    Maui-M

    Joined:
    Sep 24, 2009
    Posts:
    7
    When I am attempting to convert a sprite to a mesh I get a null object reference.
    Script: Puppet2D_Skinning.cs Line 81
    MeshedSprite.GetComponent<Renderer>().sharedMaterial.shader = Shader.Find("Unlit/Transparent");
    It is getting a null when trying to get the sharedMaterial

    Any idea on how to fix this?
     
  28. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Perhaps the Models/Materials Folder has been deleted? If it has create a new one and that will fix it
     
  29. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    this has audio and shows you how to create an FFD
     
  30. Maui-M

    Maui-M

    Joined:
    Sep 24, 2009
    Posts:
    7
    There is a Models/Materials folder but there is nothing in the folders. Tried re downloading the package and importing and still no files. Is the folder supposed to be empty?

    Thanks for the quick reply!

    Also, we are currently on unity version 5.2
    Seemed like there was mention of that in earlier post so I'll read up when I get home.
     
    Last edited: Oct 11, 2015
  31. aL0nerWolf

    aL0nerWolf

    Joined:
    Apr 8, 2014
    Posts:
    43
    Probably a silly question, but can you export finished animations as a sequence of separate png images? Looking to purchase the asset but wanted to know first.
     
  32. Diet-Chugg

    Diet-Chugg

    Joined:
    Jul 4, 2012
    Posts:
    51
  33. martibergoglio

    martibergoglio

    Joined:
    May 28, 2015
    Posts:
    14
    I have the finished animation and when I tried to play it i realized that i am having a problem to hide some bones and controls, I think at some point i deleted some global_CTRL object and I can only hide half the bones and controls. Tried disabling each sprite renderer but I get the white triangles rendering from joint to joint. Any suggestions?

    Edit: I just realize on "Refresh Global Control" --> problem resolved :p
     
    Last edited: Oct 13, 2015
  34. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Are you still getting your issue? I'm unsure why the mesh wouldn't be getting its material assigned.
    The only thing I could think of was that you somehow lost the "Puppet2D/Models/Materials/" folder. As that would stop the material being created. But if its not that, do you get any other console errors?
     
  35. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Sure you can!
    (See 28m38s in)


    I wouldn't necessary recommend using a png sequence for realtime use - it takes up a lot of memory and file space!
     
  36. Maui-M

    Maui-M

    Joined:
    Sep 24, 2009
    Posts:
    7
    Ok, so I went through the tutorials and got it working. I was working in 5.2.1

    The artist was having issues with it in 5.2 but I will have them update and go through it with them.
     
  37. EmeralLotus

    EmeralLotus

    Joined:
    Aug 10, 2012
    Posts:
    1,317
    Is it possible to retarget the animation during runtime.
     
  38. JoeyBlakeston

    JoeyBlakeston

    Joined:
    Jul 27, 2015
    Posts:
    5
    Hey there, sorry if you have already answered this but I cant seem to add a key frame when I want to flip an IK joint. Also the 'elbow' section of my joints often freaks out in my animations if it's a tight bend, Even if it's a straight line in the curves editor it tends to fly around in a circle when I play the animation.

    Thanks a lot, love Puppet 2D and it's great value.
     
  39. jehullerena

    jehullerena

    Joined:
    Oct 29, 2015
    Posts:
    2
    Tengo problemas para usar los bones estos aparecen debajo de mi cartoon y no puedo verlos al momento de crear bones
     
  40. jehullerena

    jehullerena

    Joined:
    Oct 29, 2015
    Posts:
    2
    how export animation png background transparent????
     
  41. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    Do you mean you want to switch the character and keep the same animation? Then yes - if the character is a sprite then you can switch it by changing the sprite
    Code (CSharp):
    1. GetComponent<SpriteRenderer>().sprite = newSprite;
    If its a mesh then you can have a different texture that shares the same UV space, and switch the materials in code
    Code (CSharp):
    1. GetComponent<SkinnedMeshRenderer>().sharedMaterial = newMaterial;
     
  42. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    I've fixed this for the next version - I hope to release it soon

    Could you make a video showing the issue - I'd like to see the hierachy as well to see if anything is wrong there. (You can send it to puppet2d@gmail.com)
     
  43. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    You need to first set up the correct sorting layers then set them in the puppet2d GUI (you should have control, bone and character sorting layers)
    https://unity3d.com/learn/tutorials/modules/beginner/2d/sorting-layers
     
  44. jamieniman

    jamieniman

    Joined:
    Jan 7, 2013
    Posts:
    783
    You can export the alpha by clicking the Render Alpha button. You can use this to extract the alpha in an external editing software.
     
  45. EmeralLotus

    EmeralLotus

    Joined:
    Aug 10, 2012
    Posts:
    1,317
    Great, thanks for the tips.
     
  46. berdanka

    berdanka

    Joined:
    Sep 29, 2015
    Posts:
    5
    I can not animate a "Sorting Layer Order" variable in Puppet 2D_Sorting Layer (script) component.
    MA8YaEB.png
    Also, when I try to add this property in animation via manual "Add Property" - there is no such property.
    9Rx4zQj.png
    How can I make the variable visible to the animation?
    ---------
    UPD: I can solve the problem, with placing all the objects on a single layer and using the z transform.
     
    Last edited: Nov 6, 2015
  47. TokyoDan

    TokyoDan

    Joined:
    Jun 16, 2012
    Posts:
    1,080
  48. tkoknordic

    tkoknordic

    Joined:
    Jan 31, 2013
    Posts:
    93
    Hi, I don't know about svgimporter but I just quickly tested Simply SVG with Puppet2D and it seems to work all right.


    Smooth skins and weighted vertices had some problems because the svg mesh was edited and something broke inside.

    Simply SVG https://www.assetstore.unity3d.com/en/#!/content/46496
     
  49. TokyoDan

    TokyoDan

    Joined:
    Jun 16, 2012
    Posts:
    1,080
    Thanks. Dd you have to do any 'tricks' or anything special, anything that was not the normal way of doing things with Puppet2D?
     
  50. tkoknordic

    tkoknordic

    Joined:
    Jan 31, 2013
    Posts:
    93
    Simply SVG imports svg's as meshes and you can use them with basic MeshRenderers. Also the shader we have with it is very simple and doesn't do any extra tricks. So there wasn't anything special I needed to do.