Important changes to repositories hosted on mbed.com
Mbed hosted mercurial repositories are deprecated and are due to be permanently deleted in July 2026.
To keep a copy of this software download the repository Zip archive or clone locally using Mercurial.
It is also possible to export all your personal repositories from the account settings page.
Dependencies: mbed
Badengine Class Reference
#include <Badengine.h>
Public Member Functions | |
| Badengine () | |
| Default Badengine object constructor. | |
| ~Badengine () | |
| Default Badengine object destructor. | |
| void | init () |
| Mutator method initialises the badengine object by initialising the respective charactersprites,grid,ghost and badman classes used in the game. | |
| void | readInput (Gamepad &pad) |
| Mutator method records the users interactions with the badman character based on the joystick movement. | |
| void | setGhostNumber (int number) |
| Mutator method sets the number of ghosts being used at the respective point in time within the game. | |
| void | update (Gamepad &pad) |
| Mutator method updates the game accordingly depending on the users choice of movement. | |
| void | draw (N5110 &lcd) |
| Mutator method displays the entire game on the lcd screen. | |
Detailed Description
Badengine Class.
- Date:
- April 2019 Badengine Class
Badengine controls the operation of the game per level using the charactersprites,grid,ghost and badman classes
- Version:
- 1.0
- Date:
- April 2019
Definition at line 31 of file Badengine.h.
Constructor & Destructor Documentation
| Badengine | ( | ) |
Default Badengine object constructor.
Definition at line 4 of file Badengine.cpp.
| ~Badengine | ( | ) |
Default Badengine object destructor.
Definition at line 8 of file Badengine.cpp.
Member Function Documentation
| void draw | ( | N5110 & | lcd ) |
Mutator method displays the entire game on the lcd screen.
- Parameters:
-
lcd Refrence NOKIA 5110 LCD screen object
Definition at line 47 of file Badengine.cpp.
| void init | ( | ) |
Mutator method initialises the badengine object by initialising the respective charactersprites,grid,ghost and badman classes used in the game.
Definition at line 27 of file Badengine.cpp.
| void readInput | ( | Gamepad & | pad ) |
Mutator method records the users interactions with the badman character based on the joystick movement.
Definition at line 39 of file Badengine.cpp.
| void setGhostNumber | ( | int | number ) |
Mutator method sets the number of ghosts being used at the respective point in time within the game.
- Parameters:
-
number Integer value representing the number of ghosts that will appear within the game
Definition at line 14 of file Badengine.cpp.
| void update | ( | Gamepad & | pad ) |
Mutator method updates the game accordingly depending on the users choice of movement.
- Parameters:
-
pad Refrence Gamepad object
Definition at line 57 of file Badengine.cpp.
Generated on Thu Aug 4 2022 12:05:20 by
1.7.2