Platform game written for the GHI/OutrageousCircuits RETRO game device. Navigate the caves collecting all the pickups and avoiding the creatures and haunted mine carts that patrol the caves. Oh and remember to watch out for the poisonous plants... This game demonstrates the ability to have multiple animated sprites where the sprites can overlap the background environment. See how the player moves past the fence and climbs the wall in the 3rd screen.

Dependencies:   mbed

Committer:
taylorza
Date:
Mon Feb 16 03:46:57 2015 +0000
Revision:
16:f9227904afc4
Parent:
9:34008d8b1cdf
Added a 4th game screen

Who changed what in which revision?

UserRevisionLine numberNew contents of line
taylorza 9:34008d8b1cdf 1 #include "mbed.h"
taylorza 9:34008d8b1cdf 2 #include "Fix16.h"
taylorza 9:34008d8b1cdf 3 #include "SoundBlock.h"
taylorza 9:34008d8b1cdf 4
taylorza 9:34008d8b1cdf 5 SoundBlock::SoundBlock(ToneType toneType, uint16_t stepCount, uint16_t stepDuration, uint16_t pitch, int16_t pitchSlide, uint8_t duty, int8_t dutySlide)
taylorza 9:34008d8b1cdf 6 {
taylorza 9:34008d8b1cdf 7 initialize(toneType, stepCount, stepDuration, pitch, pitchSlide, duty, dutySlide);
taylorza 9:34008d8b1cdf 8 }
taylorza 9:34008d8b1cdf 9
taylorza 9:34008d8b1cdf 10 SoundBlock::SoundBlock(ToneType toneType, uint16_t stepCount, uint16_t stepDuration)
taylorza 9:34008d8b1cdf 11 {
taylorza 9:34008d8b1cdf 12 initialize(toneType, stepCount, stepDuration, 0, 0, 128, 0);
taylorza 9:34008d8b1cdf 13 }
taylorza 9:34008d8b1cdf 14
taylorza 9:34008d8b1cdf 15 SoundBlock::SoundBlock() {}
taylorza 9:34008d8b1cdf 16
taylorza 9:34008d8b1cdf 17 void SoundBlock::initialize(ToneType toneType, uint16_t stepCount, uint16_t stepDuration, uint16_t pitch, int16_t pitchSlide, uint8_t duty, int8_t dutySlide)
taylorza 9:34008d8b1cdf 18 {
taylorza 9:34008d8b1cdf 19 _toneType = toneType;
taylorza 9:34008d8b1cdf 20
taylorza 9:34008d8b1cdf 21 _stepCount = stepCount;
taylorza 9:34008d8b1cdf 22 _stepDuration = stepDuration;
taylorza 9:34008d8b1cdf 23 _pitch = fix16_from(pitch);
taylorza 9:34008d8b1cdf 24 _pitchSlide = fix16_from(pitchSlide);
taylorza 9:34008d8b1cdf 25 _duty = duty;
taylorza 9:34008d8b1cdf 26 _dutySlide = dutySlide;
taylorza 9:34008d8b1cdf 27 }
taylorza 9:34008d8b1cdf 28