Uncle Stoo

Spriter Player for Phaser playback problem

Recommended Posts

Hi,

We're having a nightmare trying to incorporate Spriter into our project. It seems that the Spriter library doesn't like sprites living in subfolders within the project. 

 
So, as a test, we placed some frames in the project root folder, and made an animation from them (http://psygnomi.com/tmp/FailTest.zip). Here we get:
 
Cannot set frameName: 
 
...with each animation frame displayed. Nothing animates.
 
 
However, if I change line 3575 in spriter.js to this:
 
                this._sprite.frameName = file.name + '.png';
 
by adding the "+ '.png' " part, it works. (http://psygnomi.com/tmp/WorkingTest.zip)
 
If we try the modified library with a project containing frames within folders, we get the same problem. I think it stems from Spriter incorporating the folder path into the frame name, but referencing it using only the filename.
 
Obviously, placing hundreds if not thousands of sprite animation frames in the root folder isn't helpful, and will take many days to re-animate everything.

Any help is greatfully received and appreciated.

Mark & Stoo
 
 

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now


  • Recently Browsing   0 members

    No registered users viewing this page.