Revenge of the Mouse
Dependencies: 4DGL-uLCD-SE EthernetInterface Game_Synchronizer LCD_fonts MMA8452 SDFileSystem mbed-rtos mbed wave_player
Fork of 2035_Tanks_Shell by
Diff: map/map.h
- Revision:
- 10:5da9b27e050e
--- /dev/null Thu Jan 01 00:00:00 1970 +0000 +++ b/map/map.h Fri Oct 23 03:33:35 2015 +0000 @@ -0,0 +1,24 @@ +#ifndef MAP_H__ +#define MAP_H__ + +#define MAP_WIDTH 128 +#define MAP_HEIGHT 128 + +#define GROUND_VAL 0 +#define SKY_VAL 1 +#define OBSTACLE_VAL 2 + +int terrain[MAP_WIDTH][MAP_HEIGHT]; + +void map_init() { + for(int x = 0; x < MAP_WIDTH; x++) { + for(int y = 0; y < MAP_HEIGHT; y++) { + if(x < 20) {terrain[x][y] = GROUND_VAL; } + else if( 50 < y && 78 > y) { terrain[x][y] = OBSTACLE_VAL; } + } + } +} + + + +#endif \ No newline at end of file