Adventure game written for ECE2035 at the Georgia Institute of Technology
Dependencies: mbed wave_player 4DGL-uLCD-SE MMA8452
Diff: map.h
- Revision:
- 2:0876296d9473
- Parent:
- 0:35660d7952f7
- Child:
- 3:289762133fd6
--- a/map.h Wed Apr 04 21:11:07 2018 +0000 +++ b/map.h Tue Apr 17 17:17:20 2018 +0000 @@ -46,6 +46,21 @@ void* data; } MapItem; +typedef struct{ + int x,y; // Current locations + int px, py; // Previous locations + int quest_requested; //check to see if player has asked for quest + int has_key; + int quest_complete; +} NonPlayer; + +typedef struct { + int x,y; // Current locations + int px, py; // Previous locations + int is_pushed; + int wall_touch; +} Rock; + typedef struct { int tm; int tx, ty; @@ -55,6 +70,11 @@ // Define more of these! #define WALL 0 #define PLANT 1 +#define NPC 2 +#define ROCK 3 +#define DOOR 4 +#define GOAL 5 +#define SPIKE 6 /** * Initializes the internal structures for all maps. This does not populate @@ -136,6 +156,12 @@ void map_erase(int x, int y); /** +makes everything walkable +**/ + +void omni(); + +/** * Add WALL items in a line of length len beginning at (x,y). * If dir == HORIZONTAL, the line is in the direction of increasing x. * If dir == VERTICAL, the line is in the direction of increasing y. @@ -150,5 +176,10 @@ * before adding the plant. */ void add_plant(int x, int y); +void add_rock(int x, int y); +void add_npc(int x, int y); +void add_door(int x, int y); +void add_goal(int x, int y); +void add_spike(int x, int y); #endif //MAP_H \ No newline at end of file