Abstract
The game components that animated continuously and independently are termed as sprites in the game field. The animated sprits collide each other and collide with other objects. These collisions trigger embedded collision detection and collision handlers for dynamically changing the game states and output scenes. The collision detection and collision handlers actually are collision-event-update-repaint chains, which have the similar functions as the action-event-update-repaint chains. The player of the game just follows the game rules to control the animated sprites in order to avoid the collisions or to engage the collisions. The simple video game Pong is our first game example to start the introduction of sprites and their collisions for illustrating these new concepts and new techniques.
Access this chapter
Tax calculation will be finalised at checkout
Purchases are for personal use only
Author information
Authors and Affiliations
Rights and permissions
Copyright information
© 2018 Springer Nature Switzerland AG
About this chapter
Cite this chapter
Xu, Cw. (2018). Animated Sprites and Collisions: A Game Pong. In: Learning Java with Games. Springer, Cham. https://doi.org/10.1007/978-3-319-72886-5_13
Download citation
DOI: https://doi.org/10.1007/978-3-319-72886-5_13
Published:
Publisher Name: Springer, Cham
Print ISBN: 978-3-319-72885-8
Online ISBN: 978-3-319-72886-5
eBook Packages: Computer ScienceComputer Science (R0)