Search Unity

  1. We are migrating the Unity Forums to Unity Discussions. On July 12, the Unity Forums will become read-only.

    Please, do not make any changes to your username or email addresses at id.unity.com during this transition time.

    It's still possible to reply to existing private message conversations during the migration, but any new replies you post will be missing after the main migration is complete. We'll do our best to migrate these messages in a follow-up step.

    On July 15, Unity Discussions will become read-only until July 18, when the new design and the migrated forum contents will go live.


    Read our full announcement for more information and let us know if you have any questions.

Smooth Moves - 2D Skeletal Animation

Discussion in 'Assets and Asset Store' started by echo17, Feb 20, 2012.

  1. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Hi benherrera. I sent a reply to your email. If you can either send me a screencast or package of your project, I'll take a look and see what might be happening. I can't seem to get it to freeze on my machine.
     
  2. TorontoJoe

    TorontoJoe

    Joined:
    Mar 25, 2012
    Posts:
    32
    Awesome update! Love all the additions.
     
  3. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256

    In case anyone else is wondering how to do this, the way we resolved the hiding of the bone was to set the keyframe type of the last frame of the attack animation on the Slash bone to a transform-only type. This effectively hides the bone after the attack so it won't appear in the walk (or other) animations.
     
    Last edited: May 4, 2012
  4. TorontoJoe

    TorontoJoe

    Joined:
    Mar 25, 2012
    Posts:
    32
    Hi echo, is it possible to play an animation in reverse?
     
  5. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    You sure can. Just set the animation speed to -1.0f (or whatever speed multiple you want as long as it is negative). Be sure to set this speed on the BoneAnimation and not the Animation component.

    Check out my videos showing how to do this. This makes the knight walk backward. The first video is how to do this in script, the second is how to do it in playmaker.

    scripting


    playmaker
     
  6. livio3d

    livio3d

    Joined:
    Feb 17, 2009
    Posts:
    145
    Really a great tool , let me easy create a nice hybrid 2d animations, i have 2 suggestion for the animationeditor, first can be really cool the possibility to drag the animations key(single or multiselected) on the timeline/dopesheet , and the possibility to set a blank key with doubleclick on empity one! This 2 features can really speedup my and i think others workflow!
     
  7. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Thanks! Yeah, the dragging keyframes is on my todo list, definitely needs that.

    Good idea about the blank keyframe double click. One thing you can do now to speed up your process is to select a frame, then hit the "B" button. This is a shortcut to create a blank keyframe. "P" creates a position/rotation keyframe and "T" creates a texture keyframe (good for sprite animation).
     
  8. huxley

    huxley

    Joined:
    Apr 27, 2009
    Posts:
    334
    I need to setup an inventory system where the character can change various pieces of equipment on their outfit. I watched the texture swapping tutorial, but I'd prefer not to create a separate animation for each outfit.

    I assume that I need to use SwapMaterial in code at runtime and make sure that the atlas of all the various costumes match the original atlas. Is there a more efficient way to do this if I only need to swap 1 part of the character (for example the shirt) and not the entire atlas?
     
  9. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Yeah, swapping the entire material is great for changing the overall look, but to change just one bone at a time, you'll want to use the texture replace functionality. Have a look at this tutorial:



    This system is a bit clunky and I plan on improving it in the future by integrating the swaps inside the animation editor, but this should get you by for now.
     
  10. Cru

    Cru

    Joined:
    May 10, 2012
    Posts:
    1
    Hi Echo,

    I am just getting started and I am really impressed with your Smooth Moves plugin. I purchased it yesterday. Now I am looking at getting a visual scripting editor and I am torn between Playmaker and Antares Universe. Apparently Playmaker is simple to use, but not as powerful and Antares and is more difficult to use, but a lot more flexible. My question is, does Smooth Moves integrate with Antares at all (I know it does with Playmaker).

    Thanks,

    Cru
     
  11. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Hi Cru,

    I haven't used Antares, so I couldn't say what all might work there. If Antares allows you to reference a component and access that component's methods and members (possibly through reflection), then you would be able to use Smooth Moves, but again I have no idea if this is true. I made some scripts for Playmaker to be able to Play animations on the BoneAnimation component. I am not even sure if you can create extendable scripts for Antares.

    Sorry for having no answer for you. Perhaps someone else subscribed to this forum has Antares and Smooth Moves and can give a better response.
     
  12. livio3d

    livio3d

    Joined:
    Feb 17, 2009
    Posts:
    145
    Great!
    I have another suggestion for animation editor, using a tree system for hide and show the child and keys of a bone, just for have a clean structure to work with (like everything on unity), actually with 20 + bones is hard to find the right one!

    sry for bad english :) i hope is clear
     
  13. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Perfectly clear. That is a good idea. I had actually started working on a foldout bone hierarchy before my initial launch. It was taking too long so I decided to put it on hold so I could get the product on the store. It is on my list, but it may be a while to get to it. Thanks for the suggestion!
     
  14. ThExplorer

    ThExplorer

    Joined:
    Mar 21, 2012
    Posts:
    1
    Hello Echo17,

    Thank you for a good and easy, straight forward tool..

    I'd like to report a bug that I discovered, looking for a solution - or if I need to redo all my animation clips.

    This is what I think happened...

    1. I made 4-5 clips in one Bone Animation Data, where legs and body where child of the root.
    2. I then realized perhaps it would be better if the body was a child of the leg, so I changed it.
    3. Everything seemed to be ok, and as it was using the predetermined "per clip/sprite" changed pivots. Everything stayed pretty much the same for the animations clips I had.
    4. I created 2 new clips, and they ALL show up ok in the Animation Editor. All sprites aligns perfectly..
    5. I then decided to NOT have the body under LEGS so I moved it back..
    6. All clips looks perfect in the Animation Editor, well aligned and all bones seems to work well with each animation data...

    The problem:
    When I play the game the sprites are all over the place...

    The first "default" animation lines up, but after playing one of the new animations clips, it looks like it inherit some of those bones or ignore updating all the bone data for each clip // even if there is key's set for that sprite.

    Ever experienced anything like this before?

    Conclusion: The Animation Editor shows the animations perfectly -> but the game does not position/rotate/scale the bones/sprites correctly after certain clips have been played..

    Thoughts?

    Thankful for any suggestions, I'm about to start over again....
     
  15. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Hi ThExplorer, sorry you're having trouble. If you could send me a package of your project to my email at: support@echo17.com, I'll take a look and see what is happening in the animation. Be sure to package the project using "Assets->Export Package" and include your original textures, atlases, and animation. This keeps the links intact so Unity will be able to find everything.
     
  16. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Hey everybody! Just wanted to thank all my loyal Smooth Movers out there for helping me to get to the Asset Store's front page. The plugin is now in the most popular list for the first time since its launch two months ago.

    Thanks!
     
    Last edited: May 17, 2012
  17. runonthespot

    runonthespot

    Joined:
    Sep 29, 2010
    Posts:
    305
    Cream of the crop, rise to the top.
     
  18. Demigiant

    Demigiant

    Joined:
    Jan 27, 2011
    Posts:
    3,242
    You totally deserved it :) Smooth Moves is just indispensable for 2D games (along with 2D Toolkit).
     
  19. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Thanks guys!
     
  20. robin_notts

    robin_notts

    Joined:
    Apr 7, 2010
    Posts:
    86
    It is great. The fact that I bought it and painlessy finished an animation within 30 minutes is testament to how good it is.
     
  21. TorontoJoe

    TorontoJoe

    Joined:
    Mar 25, 2012
    Posts:
    32
    I have all of the 2D extensions. All of them.

    This is the best. Hands down.
     
  22. willrmiller

    willrmiller

    Joined:
    Dec 15, 2009
    Posts:
    9
    We're experiencing a problem using the new 3.5.2 version of Unity that whenever we try to adjust the pivot of a sprite piece in the animation editor, Unity locks up and has to be force quit. We actually continue to see it after reverting to 3.5.1, after cleaning out the project, after rebooting, etc. Has anyone else seen something like this?
     
  23. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Someone else had reported this happening and it turned out it was a corrupted installation of Smooth Moves. It was missing a few textures in the editor Resources folder that was causing it to fail. What we did to fix this was delete smooth moves completely from the project, then redownload from the asset store. You might try this on a fresh project in case Unity has some database entries that make it think the package files are still hanging around. Everything worked peachy after that.

    If that doesn't fix it, shoot me an email at: support@echo17.com and I'll try to help you out.
     
  24. huxley

    huxley

    Joined:
    Apr 27, 2009
    Posts:
    334
    I'm creating a bone animation character, but each time that I build it out the textures become rasterized as seen in this screenshot.



    As you can see, everything looks good in the atlas (left example) but when rendered to the game view, the texture appears compressed.
     
  25. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Be sure the atlas texture is set to no mipmaps, no compression. This looks mostly like a color issue, meaning that it is set to 16 bit instead of 32. You can see the banding effect that a lower color depth causes.

    Also, be sure you are setting the values on the final atlas texture and not the source textures. The editor uses the source textures, but the in-game mesh uses the atlas texture.
     
  26. OmniverseProduct

    OmniverseProduct

    Joined:
    Feb 26, 2012
    Posts:
    1,568
    I'm going to purchase this soon but I have questions. It doesn't matter whether the graphics are scalable or not right? If I'm understanding this right, smooth moves makes a sort of 2d mesh out of the graphics?
     
  27. Samb88

    Samb88

    Joined:
    Mar 26, 2009
    Posts:
    208
    Hi echo17,
    I have something for you to think of. I know, that it COULD be too much work to be worth it, but sometimes you wake up and have a brillant idea how to make hard things easy!
    Ok, here it is: Lip synching tool.. It would be similar to the current animation tool, but when you press a sound file will be played.
    So this would be an idea that, I think, you could even extend. How about audio layers, let's say you can say in the animation editor that on frame 10 and 20 "footstep.wav" should get played.

    In the end, I think if you could intregate sounds into the animations, lip synching would be no problems, as long as, for example, if you start the preview from frame 24 with a fps of 24, the voice soundfile would also start at the first second and not at the beginning (for really long voice samples, so you won't have to play everything from the beginning to check if everything is insynch).

    So yes, just something to think about.

    Rock on :)
     
  28. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    I'm not sure what you mean by scalable. Smooth Moves does create a 3D mesh out of the textures you provide. The quads of the mesh are mostly in a 2D plane unless you use Z positioning.
     
  29. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Sounds like a cool idea. I'll add it to my list of possibilities. Thanks!
     
  30. OmniverseProduct

    OmniverseProduct

    Joined:
    Feb 26, 2012
    Posts:
    1,568
    Sorry, I could've been clearer. By scalable I meant vector graphics
     
  31. MaDDoX

    MaDDoX

    Joined:
    Nov 10, 2009
    Posts:
    764
    As far as I know SmoothMoves uses only quads, and extruded quads for collision. For vector graphics (or bitmap graphics with vector outlines) you'd use RageSpline + RageTools - but we don't have a custom editor, relying on Unity's animation window instead. So depends on what you want to do, if vector graphics are of no interest to you SmoothMoves is a great choice.
     
  32. OmniverseProduct

    OmniverseProduct

    Joined:
    Feb 26, 2012
    Posts:
    1,568
    Hm, I'll have to do some thinking. Thanks.
     
  33. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    I see. No, Smooth Moves does not use vector graphics. It creates a collection of quads (into a skinned mesh) that are moved around with animation curves. For collisions you can set box or sphere colliders on any of the bones. For complex collision shapes, you can create multiple child bones and have each of them set with a different collider, building up to a more refined edge for your collisions.
     
  34. robin_notts

    robin_notts

    Joined:
    Apr 7, 2010
    Posts:
    86
    echo17 - do you have any ideas why atlas texture items would have an incorrect relative scale to other objects in the same atlas even when the scale is set to (1,1,1)? I've noticed this a few times now and so far have worked around it. But it worries me, and I'd prefer not to have to compensate.
     
  35. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    I remember seeing that in earlier versions of smooth moves, and you can see it in my atlas tutorial. Sometimes Unity doesn't import the source texture as a non power of two size, even when you specify that in the importer in code. What I did in later version to compensate is import each source texture twice when generating the atlas. That seemed to get around the bug.

    Be sure you are on the latest version of Smooth Moves, and if it still persists, try clicking the "Rebuild" button in the atlas editor a couple of times to be certain. If this doesn't fix the issue, send me an email at support@echo17.com and I'll see if we can figure out what is going on.
     
  36. robin_notts

    robin_notts

    Joined:
    Apr 7, 2010
    Posts:
    86
    Thanks, I suspect I've found a habit like your first solution that sorts it out, cos it's all going well now.

    On another note: is there anyway to set the layer for all colliders in the animation?

    Also, part way through an animation I'm trying to de-activate an object, so, on the correct frame I'm setting its collider to None, setting its image to transform, setting that animation to ClampForever so it never comes back, which kinda works but it seems to pop back after a short time. Any ideas? I've kinda worked around it for now, and it's probably me not fully understanding Mix/Blend/Layer/Weight etc.
     
  37. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    You can set the collider layer to "Use Animation Layer" on each collider, then just change the layer of your bone animation gameobject in the scene. Using this setting automatically inherits whatever you've set on the gameobject. Other than that, there is no global way to change the collider layers for each bone.

    It sounds like there may be another animation playing mixed or blended on top of that animation that would cause a trigger to fire, setting your bone back to activated. I'd have to see your animation and the code that is calling the animations to tell you exactly what is happening. You can send me a stripped down (or complete) package of your project to my support@echo17.com email address if you want. Be sure to use the "Assets->Export Package" menu to keep the links preserved.

    [EDIT]
    Also check to be sure that you haven't set another frame (possibly the last frame) of the animation back to an active bone image. When I bookend my animations, copying the first frame to the last frame, I sometimes forget that the last frame is full of triggers that will fire when the animation completes.
    [/EDIT]
     
    Last edited: May 22, 2012
  38. Aschmidt

    Aschmidt

    Joined:
    May 22, 2012
    Posts:
    1
    Are there any plans to add a simple inverse kinematic system to Smooth Moves? Or has anyone seen an extension or script that does so?
    If so could you point me to it? Thanks!
     
  39. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    It's on my list, but unfortunately that list is a long one :)
     
  40. Demigiant

    Demigiant

    Joined:
    Jan 27, 2011
    Posts:
    3,242
    And, uh, where is a serious documentation on your list? I am a big fan of Smooth Moves (and always talk greatly about it), but having to watch a video each time I forget something is starting to take a serious toll :p
     
  41. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    It's definitely still up there pretty high. As time goes on, I'm spending more time supporting the product than improving or documenting it. The price of popularity :)
     
  42. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    If anyone is getting lockups in the editor pivot window editor, I believe I found the source of the problem. If you set your grid size to zero pixels or less in the settings window, Smooth Moves goes into an infinite loop trying to drawing an infinite amount of grid lines. The simple immediate solution is to be sure your grid size is higher than zero pixels. If you want to hide the grid, just uncheck "Show Grid" instead. If the editor locks up to where you can't even get to your settings, you can do the following to reset the grid size outside of the editor:

    1) Create a temporary script and attach it to some gameobject in your scene.
    2) Add the following code in the Awake or Start functions of your temporary script:

    Code (csharp):
    1. PlayerPrefs.SetInt("SmoothMoves_Editor_AnimationGridSize", 50);
    3) Run your scene, then stop.
    4) Open Smooth Moves editor. You should see the animation grid size is set to the default of 50 pixels.
    5) You can now delete the temporary script you created.
    6) Be sure to not set the grid size to zero pixels or lower. If you want to hide the grid, uncheck the "Show Grid" option in the Settings window.

    I will put a fix in the next release that will prohibit setting the grid size to zero pixels or lower.
     
  43. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    1.9 Preview

    The new features of 1.9 will benefit every animator, but this will especially help out the traditional sprite animators. 1.9 is in beta testing right now, so I anticipate its release fairly soon. I'll keep you updated on its progress.

    - Dragging selected keyframes backward and forward in time



    - Inserting frames (not keyframes), which shifts frames forward / to the right. Deleting frames which shifts frames backward / to the left. You can insert and delete frames on select bones or for an entire column of bones. Also if you select a group of frames and insert or delete, that number of frames will be shifted.



    - Copy / Paste property settings. You can now choose which properties are copied and pasted in the Settings window.

     
    Last edited: May 23, 2012
  44. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    MADNESS SALE!!!

    After seeing the success of the home grown madness sale, Unity has created their own madness sale integrated into the asset store. Smooth Moves was chosen as one of the first plugins to enter into the madness.

    Smooth Moves is now 50% off for a limited time! Check it out on the asset store front page.



     
  45. Chounard

    Chounard

    Joined:
    May 2, 2012
    Posts:
    2
    I just bought Smooth Moves yesterday. Blast! :p

    I've got a feature request for you: Onion Skinning.

    It's really helpful to be able to see the previous/next keyframes while you're editing. Here's a shot of onion skinning active in my skeletal animation tool. (The greenish outline is the next frame.)

    http://dl.dropbox.com/u/9594258/onion.png
     
  46. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Sorry about that. After Unity's invitation to the madness sale I wasn't even sure if they were going through with it. Hadn't heard back on it. Kind of surprised me too.

    That's a great request! I'll add it to my list.
     
  47. robin_notts

    robin_notts

    Joined:
    Apr 7, 2010
    Posts:
    86
    New features look great. I'd put in a vote for onion skinning as well.
     
  48. blaze

    blaze

    Joined:
    Dec 21, 2011
    Posts:
    211
    Hello echo17, I just bought the asset, by the Madness Sales. :)
    My unique question for now, is, I will have the updates of the asset, or I will need to pay again to get the 1.9 version, for example?
    Updates are free after buy?
     
  49. echo17

    echo17

    Joined:
    Nov 24, 2011
    Posts:
    1,256
    Yes updates are free.
     
  50. blaze

    blaze

    Joined:
    Dec 21, 2011
    Posts:
    211
    If you was a girl, I would say that I love you!

    Another question, I'm newbie yet, sorry.
    Have some tutorial, to get your sample (http://goo.gl/IieUl), running in touch controls? (Like Shadowgun)