deangiberson Posted January 25, 2014 Report Share Posted January 25, 2014 I'd like to share a javascript implementation of the Spriter format player, https://github.com/deangiberson/spriter-scon-js. It's designed to be generic but has a dependency on CraftyJS PreloadJS currently, but that's easily removed. The currently know problem is that it doesn't play well with negative scales. So for example the Ladder animations out of the PlatformPack don't work, everything else works great. For an example of how it's used look at examples/crafty/hero.js, for now that's all there is, but I'm adding more. lucid, maybe you could look and let me know if you see why negative scales aren't working? Asuqytrau 1 Quote Link to comment Share on other sites More sharing options...
Mike at BrashMonkey Posted January 28, 2014 Report Share Posted January 28, 2014 Very cool! Thanks deangiberson. cheers, Mike at BrashMonkey Quote Link to comment Share on other sites More sharing options...
lucid Posted February 16, 2014 Report Share Posted February 16, 2014 hi deangiberson, Can you show me a screenshot, of the incorrectly working negative scale? I may be able to figure out what's wrong, as I've seen issues with negative scale before. It's most likely this. If you're unmapping a child bone from local coordinates, you have to flip the angle to get mirrors to look right: if(parentBone.scaleX*parentBone.scaleY { unmappedChild.angle=(360-child.angle)+parentBone.angle; } else { unmappedChild.angle=child.angle+parentBone.angle; } Quote Link to comment Share on other sites More sharing options...
andrikaa Posted February 27, 2014 Report Share Posted February 27, 2014 HTML and Javascript? Im confused. What is Javascript used for? I know that you can write using javascript but what is the difference between javascript and HTML, how are they different, how do their uses differ? Thanks a lot. Quote Link to comment Share on other sites More sharing options...
Trumgottist Posted March 1, 2014 Report Share Posted March 1, 2014 HTML and Javascript? Im confused. What is Javascript used for? I know that you can write using javascript but what is the difference between javascript and HTML, how are they different, how do their uses differ? Thanks a lot. The simple answer is that html by itself makes static pages. (It's short for HyperText Markup Language.) With javascript (or another scripting language), you can make the pages change. Quote Link to comment Share on other sites More sharing options...
Idiot Posted August 12, 2015 Report Share Posted August 12, 2015 Thank you for this implementation, it really is helpful. Only problem I'm having is that my sprite animations don't show correct alphas, actually every object is visible all the time, even though they should not be. Is there some way in Spriter to make my problem go away? I make objects appears as the animations proceed, so this is very important to get working. EDIT: Got it working, it was a problem with updating the globalAlpha on my context. Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.