Question: Create a game in HTML/CSS A character runs around the screen collecting pieces and tries to get as many as they can in 30 seconds.

Create a game in HTML/CSS

A character runs around the screen collecting pieces and tries to get as many as they can in 30 seconds.

Could be an animal eating food Could be a person running after money Could be a pirate collecting gold Could be Little Bo Peep running after her sheep Anything you can think of where some character is trying to collect some items.

Title screen that plays some music with a Play button and an Help button.

The Help button will tell you the controls and object of the game.

Pressing Play will start the game.

Have background music

Have a background image (if you have an image that includes a sky or water, limit the location of your character and items collected to the area where the character can move).

Offer a "mute" checkbox, that if checked the game does not play the sounds.

Have game where there is a character is controlled by the 9 way directional number-pad on the keyboard.

Have a timer that goes for 30 seconds (counting down each second).

Have a counter indicating how many pieces the character collected.

You might prefer to use an array of preplaced locations, rather than a total random x,y location for the piece, to make things seem a bit more natural (or have the locations not be exact x,y but in steps of 10 pixels or so).

On the screen, randomly place an item that the character must collect (again, try to place them in a natural position, such as on land if a person is moving to get them).

When the character gets the piece (collides with it):

Play some funny or happy sound.

Increment the collection counter.

Place the piece at a new randomly selected place on the screen.

When the timer runs out:

Stop the game (player cannot move)

Stop the counter.

Play a "game over" sound effect.

Display "Game Over" on the screen.

Display a button so that the user can play again. If they play again, reset the counters.

Pick a theme for your game. Something funny and interesting. You can find images by looking on Google Images. If you add the word "sprite" to your search, you'll find game images. Please be sure to crop or resize your image (and make it transparent it possible). http://images.google.com Sounds and music can be found here: http://flashkit.com/

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!