© Rex van der Spuy 2015
Rex van der SpuyAdvanced Game Design with HTML5 and JavaScript10.1007/978-1-4302-5801-8_10

10. Tweening

Rex van der Spuy
(1)
Ontario, Canada
 
Tweening is an animation technique that you can use to make a sprite change its appearance or position over time in very specific ways. You can use tweening to make a sprite move along a fixed path or curve, or make a sprite fade in, fade out, pulse, or wobble. Using tweening effects will add a whole new dimension of interactivity and engagement to your games that will make them come alive in new and exciting ways.
How is tweening different from the other ways you’ve learned to move sprites in this book? In Chapter 5 you learned how to make sprites move using velocity and physics properties. ...

Get Advanced Game Design with HTML5 and JavaScript now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.