11.07.2015 Views

Here - 1000 BiT

Here - 1000 BiT

Here - 1000 BiT

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

WATCH OUT, TWO SPRITES ARE GOING TO BUMP!When two sprites overlap on the screen, their bit values added together appear in boxV+30, the "sprite hit sprite?" register. Example:87 H=PEEK(V+30)88 PRINT HOIf "6" is printed, then you know that sprites 1 and 2 have hit each other because their bitvalues, 2+4, add to 6.If a sprite hits something you have drawn on the screen, its bit value is added to boxV+31, the "sprite hit background?" register.Assignment 31B:1. Make two sprites which can move horizontally. Start them at opposite ends of thescreen. When they hit, make a "crash" sound.2. Make a Bumper Car rink. Put a border around the screen. Have two sprites (differentcolors) for bumper cars. Make eight pictures of cars, going up, down left, right andtoward each diagonal. Control the cars with keys for "turn left" and "turn right."When the cars hit, they have to back away.183

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!