2D Toolkit Forum

2D Toolkit => Support => Topic started by: edo on July 20, 2013, 10:52:00 am

Title: Swich Library with Recourses.Load Problem
Post by: edo on July 20, 2013, 10:52:00 am
Hi,
i use Javascript with the 2.0 Api and i try to switch the animation collection (anim lib) with:

playerAnimation.Library = Resources.Load("Test", typeof(tk2dSpriteAnimation)) as tk2dSpriteAnimation;
playerAnimation.Play("Test");

but Unity got stuck everytime, no error in the Log.

playerAnimation called:
static var playerAnimation : tk2dSpriteAnimator;

and on Start function:
playerAnimation = GetComponent(tk2dSpriteAnimator);

and of course i've got animation collection called Test with clip called Test inside.

what am i doing wrong?

thanks,
Edo
Title: Re: Swich Library with Recourses.Load Problem
Post by: unikronsoftware on July 20, 2013, 11:03:49 am
What is the result of Resources.Load("Test", typeof(tk2dSpriteAnimation)) as tk2dSpriteAnimation;
Is it actually loading the sprite animation correctly?

Also what do you mean by "got stuck"? If you still haven't worked it out, send a repro case to support at unikronsoftware.com and I'll investigate for you.
Title: Re: Swich Library with Recourses.Load Problem
Post by: edo on July 20, 2013, 03:59:58 pm
Hi,
there is no reult, when it gets to the point where it should load the library, it just got stuck and i need to close unity from the system manager.

i'm sorry, but how do i send a repro case?
Title: Re: Swich Library with Recourses.Load Problem
Post by: unikronsoftware on July 20, 2013, 04:36:38 pm
Create a really simple project showing the issue (try to delete asmuch as possible, of course), zip up and send to support :D