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:
Sat Nov 29 06:40:50 2014 +0000
Revision:
0:2ee0812e2615
Child:
7:2fd875c1d9b1
Working engine with patrolling enemies

Who changed what in which revision?

UserRevisionLine numberNew contents of line
taylorza 0:2ee0812e2615 1 #include "mbed.h"
taylorza 0:2ee0812e2615 2 #include "Bitmap4bpp.h"
taylorza 0:2ee0812e2615 3
taylorza 0:2ee0812e2615 4 Bitmap4bpp::Bitmap4bpp(uint16_t width, uint16_t height) :
taylorza 0:2ee0812e2615 5 _width(width),
taylorza 0:2ee0812e2615 6 _height(height),
taylorza 0:2ee0812e2615 7 _stride((width >> 1) + (width & 0x01))
taylorza 0:2ee0812e2615 8 {
taylorza 0:2ee0812e2615 9 //_pBitmapData = new uint8_t[_stride * height];
taylorza 0:2ee0812e2615 10 _pBitmapData = (uint8_t*)malloc(_stride * height);
taylorza 0:2ee0812e2615 11 }
taylorza 0:2ee0812e2615 12
taylorza 0:2ee0812e2615 13 void Bitmap4bpp::clear()
taylorza 0:2ee0812e2615 14 {
taylorza 0:2ee0812e2615 15 memset(_pBitmapData, 0, _stride * _height);
taylorza 0:2ee0812e2615 16 }
taylorza 0:2ee0812e2615 17