• Collisions

    To find out if an object has collided with another you can use the method that is present in all classes.

    Also, it is possible to check if there was a collision by using the static class Collision, with the method

    Example:

    The collision class can be used to check collision between any of the objects: GameObject, GameImage, Animation and Sprite.

    Example: Checking for collisions between objects.

    UFF - Universidade Federal Fluminense - Institudo de Computação - Ciência da Computação