Version of Robotron arcade game using LPC1768, a Gameduino shield, a serial EEPROM (for high scores), two microswitch joysticks and two buttons plus a box to put it in. 20 levels of mayhem.

Dependencies:   25LCxxx_SPI CommonTypes Gameduino mbed

Committer:
RichardE
Date:
Sat Jun 08 16:44:54 2013 +0000
Revision:
7:e72691603fd3
Now have grunts wandering around on level 1. They follow the player but since no collision detection logic yet nobody ever gets killed.

Who changed what in which revision?

UserRevisionLine numberNew contents of line
RichardE 7:e72691603fd3 1 /*
RichardE 7:e72691603fd3 2 * SOURCE FILE : BrainBulletObject.h
RichardE 7:e72691603fd3 3 *
RichardE 7:e72691603fd3 4 * Definition of class BrainBulletObject.
RichardE 7:e72691603fd3 5 * This is the enemy object used as a bullet fired by BrainObject enemies.
RichardE 7:e72691603fd3 6 *
RichardE 7:e72691603fd3 7 */
RichardE 7:e72691603fd3 8
RichardE 7:e72691603fd3 9 #ifndef BrainBulletObjectDefined
RichardE 7:e72691603fd3 10
RichardE 7:e72691603fd3 11 #define BrainBulletObjectDefined
RichardE 7:e72691603fd3 12
RichardE 7:e72691603fd3 13 #include "EnemyObject.h"
RichardE 7:e72691603fd3 14
RichardE 7:e72691603fd3 15 class BrainBulletObject : public EnemyObject {
RichardE 7:e72691603fd3 16
RichardE 7:e72691603fd3 17 public :
RichardE 7:e72691603fd3 18
RichardE 7:e72691603fd3 19 // Horizontal and vertical velocities at which bullet is moving.
RichardE 7:e72691603fd3 20 // NOT pixel velocities.
RichardE 7:e72691603fd3 21 Int16 HVelocity, VVelocity;
RichardE 7:e72691603fd3 22
RichardE 7:e72691603fd3 23 /***************/
RichardE 7:e72691603fd3 24 /* CONSTRUCTOR */
RichardE 7:e72691603fd3 25 /***************/
RichardE 7:e72691603fd3 26 BrainBulletObject();
RichardE 7:e72691603fd3 27
RichardE 7:e72691603fd3 28 /*****************************/
RichardE 7:e72691603fd3 29 /* GET TYPE OF ENEMY THIS IS */
RichardE 7:e72691603fd3 30 /*****************************/
RichardE 7:e72691603fd3 31 // Returns enemy type.
RichardE 7:e72691603fd3 32 virtual EnemyType GetEnemyType( void ) {
RichardE 7:e72691603fd3 33 return BrainBullet;
RichardE 7:e72691603fd3 34 }
RichardE 7:e72691603fd3 35
RichardE 7:e72691603fd3 36 /*******************************************************/
RichardE 7:e72691603fd3 37 /* GET NUMBER OF POINTS AWARDED FOR KILLING THIS ENEMY */
RichardE 7:e72691603fd3 38 /*******************************************************/
RichardE 7:e72691603fd3 39 // Returns number of points (in BCD).
RichardE 7:e72691603fd3 40 virtual UInt8 GetPoints( void ) {
RichardE 7:e72691603fd3 41 return 0x10;
RichardE 7:e72691603fd3 42 }
RichardE 7:e72691603fd3 43
RichardE 7:e72691603fd3 44 /************************/
RichardE 7:e72691603fd3 45 /* DRAW THE GAME OBJECT */
RichardE 7:e72691603fd3 46 /************************/
RichardE 7:e72691603fd3 47 // Note if Visible is false this should not draw anything
RichardE 7:e72691603fd3 48 // and/or hide the visible object.
RichardE 7:e72691603fd3 49 virtual void Draw( Gameduino *gd );
RichardE 7:e72691603fd3 50
RichardE 7:e72691603fd3 51 protected :
RichardE 7:e72691603fd3 52
RichardE 7:e72691603fd3 53 /************************/
RichardE 7:e72691603fd3 54 /* MOVE THE GAME OBJECT */
RichardE 7:e72691603fd3 55 /************************/
RichardE 7:e72691603fd3 56 virtual void ProtectedMove( void );
RichardE 7:e72691603fd3 57
RichardE 7:e72691603fd3 58 };
RichardE 7:e72691603fd3 59
RichardE 7:e72691603fd3 60 #endif
RichardE 7:e72691603fd3 61
RichardE 7:e72691603fd3 62 /* END of BrainBulletObject.h */