A New Animation Solution based on SWF for Cocos2d

Hi @Raymond,
A very nice concept. Will surely help in optimizing the animation stuff in code.
I am little curious to know, are you thinking to support this with TexturePacker.

I mean to say, instead of adding so many sprites in project, just having a spritesheet and all frames added to CCSpriteFrameCache.

Thanks,
Rahul

Rahul Kukreti wrote:

Hi @Raymond,
A very nice concept. Will surely help in optimizing the animation stuff in code.
I am little curious to know, are you thinking to support this with TexturePacker.
>
I mean to say, instead of adding so many sprites in project, just having a spritesheet and all frames added to CCSpriteFrameCache.
>
Thanks,
Rahul

Canā€™t agree more! Zwoptex may be a good choice.~

Hi @Raymond,
Thanks for this great tool.
Iā€™ve tried it and it works great on IOS. However, Iā€™ve got some errors on win32 and android.
I think for it to work on android, I had to change the FILE loading in SuperAnimDefMgr::LoadSuperAnimMainDef to cocos2dā€™s sharedFileUtils()->getFileData; otherwise Iā€™ll get an fatal error while creating SuperAnimNode.
Also in the SuperAnimNodeV2.cpp I had to change include of kazmath.h to kazmath/kazmath.h so it could compile in win32 and android.(I guess I could just include the directory when compile, but it seems more straightforward to just change the include since it also works in IOS.)
After the changes, it works great on all platforms. Please let me know if Iā€™m doing something wrong here or if the problems are actually because of me doing something wrong in the first place, thanks.

Terrific tool youā€™ve done there, Nice work.
I wanted to ask if I want the animation to work with Cocos-2d HTML5 version:

  1. How can I do it, Can you give the steps I should do?
  2. Do the exported ā€˜.samā€™ file has a documentation, so that I can develop js files that can somehow understand the .sam file and create animation with it?

Hi @Raymond,
This tool so nice :slight_smile:
Now, I trying to apply to our project. Itā€™s so awesome.
But i still have a few questions for you to

  1. Canā€™t play frame animation like sequence image play (gif).
  • One image per frame.
  • ā€œSuper Animation Converterā€ do not play frame animation.
  • but displayed frame still countered.
  1. Is there any plan to support movie-clip features?
  • swf parsing is technically difficult, but ā€¦
  • Flash artists want their support.

Iā€™m sorry, but could you do me a favor and answer?

Thanks,
yoonhwan

When I attempt to add some more fish like 3 ~ 4 fish, it starts getting laggy.

Raymond, are the Converter sources available anywhere? Are you planning to keep it free or will there be a paid version?

Also, I have been trying to use Vectorian Giotto to test some animations, and for some reason I cannot create Graphic Symbols, only Button or Movie. Can you add these in your converter to allow the use of Giotto, which is a free alternative to Flash?

Itā€™s awesome!
Thanks for your work.

BTW, could you make a converter tool running on Windows?

No Converter sources, converter tool for Windows
So I use Flash2Cocos2d: https://github.com/jyinkailej/Flash2Cocos2d-x :slight_smile:

Hi
thank you for this useful tool i want to ask you about how can i detect touch on the animation
i want to make idle animation and when user touch this animation i want to change the animation how can i do that

Hi thank you from usefull tool
i try it but i have problem when i export animation with anchor point changed the animation will play with wrong behavior spically when i change the anchor point for skew can we help me plz
thank you

Is there a limit to the dimensions the tool allows. I am currently trying to use a swf of 1600x2252. It plays fine but there seems to be a bug on how it sets the content size. Its logging as 1600 x ā€“1024.

Hey guys,

After suffering some bad days, lost my job, broke up with my gf, Iā€™ve made some new update for this projects:

Updates
1 Support sprite sheet, which means you can use TexturePacker to pack some small images into one big images
2 Support resize animation, you can resize one animation to different size to support multiple resolution
3 Add set flip x&y function
4 Fix some crash bugs, some depth bugs, alpha blend bugs, more stable now

Please read the new Help Doc first, then enjoy it!

Hey, Mike

Iā€™m sure Iā€™ve fixed this bug in the latest version.
Have a try.
:slight_smile:

Hey Raymond,
This is a great solution! I think this program fits perfectly for us flash animators used to optimizing animations there. Iā€™m just having one problem: It seems itā€™s only importing one (1) LAYER from the swf. For a second there it worked good, but I moved something on the timeline and isnā€™t working anymore. Any idea what this might be? Thanks in advance for the help. :slight_smile:

hey, Andres,

can you send me your fla by email?
you can find my email address on the first page of the help doc.
my Adobe Flash CS version is 5.5.

thank u.

Hi Raymond, can you provide the source code of converter?
I would like to porting it to win32 platform :stuck_out_tongue:

Hey, Splash,

thank u for your idea.
since this tool is still being improved, and not very stable,
I would like to do that porting later.
:wink:

any other idea, please email me.

Thanks for this tool! It looks great!
Iā€™m a noob on Cocos2d-X for now, but I have to create an android app with swf animations (Iā€™m using Linux for development, and my animators use Mac OS).

So as I have understoodā€¦ the tool is run on Mac OS, and it outputs three files, as the document says:

  • fish.plist
  • fish.png
  • fish.sam

Soā€¦ Once Iā€™m using Cocos2D-X, what should I do to use that files and get the animation?

I firsly should include this:

#include "SuperAnimNodeV2.h" using namespace SuperAnim;

create the animation object with:

mAnimNode = SuperAnimNode::create(anAnimFileFullPath, 0, this);

BTW, the anim file is the fish.sam, isnā€™t it?

Then, play it with:

mAnimNode->PlaySection("*whatever*");

And what I should add to the project is the files inside:

super-animation-samples / samples / cocos2d-2.0-x-2.0.4 / super-anim-samples / SuperAnim

Am I right?

My art partners complained, frame-by-frame animation is still very useful, but it seems not support ?