The Java Game Framework.

Examples, tutorials, documentation and download of the Genuts Framework.
Games made with the Genuts Frameworks.
General articles around games.
Links covering all needs around game dev.
Who are we?
Terms of Service

API >> Tutorials >> Playfield Scrolling And Pre-Collision mode >> "Follow the ball" exercise

"Follow the ball" exercise

This course is a little bit special; it will explain nothing, because you know everything about elements which compose it. But it invites you to have a little reflection.

Your mission

The goal of this exercise is to transform the previous example by adding a wrapper to only one ball. This new wrapper will change the offset of the visible part of the playfield to follow this ball. Next, you have to add the ability to change the followed ball.

The result has to look like this:

    Click on a new ball to change the followed ball.  

You only need a new graphic element to represent the followed ball:

Help me!!

Did you succeed in your mission?

We give you a possible solution for this execise:

Now it is in your hands, have fun.

<< Previous Page

API >> Tutorials >> Playfield Scrolling And Pre-Collision mode >> "Follow the ball" exercise