Skip to content
Snippets Groups Projects
Commit 10f6997a authored by PAILLE Kyriann's avatar PAILLE Kyriann :8ball:
Browse files

Update game.h, location.h, stack.h

parent cea5419a
Branches
No related tags found
No related merge requests found
#ifndef GAME_H
#define GAME_H
#include "mobile.h"
#include "stack.h"
typedef struct
struct Stack;
typedef struct Game
{
Mobile *player;
struct Stack *locationStack;
} Game;
extern Game *GameInit();
......
......@@ -3,16 +3,20 @@
#include "exits.h"
#include "stack.h"
struct Game;
typedef struct Location
{
char *name;
char *desc;
int index;
struct Location *directions[6];
} Location;
Location *LocationInit(struct Game *game);
extern Location *LocationNew(char *name, char *desc);
extern Location *LocationDelete(Location *m);
extern void LocationPrint(Location *m);
extern Location *LocationInit();
extern void LocationSetExit(Location *l1, Direction direction, Location *l2);
#endif // LOCATION_H
\ No newline at end of file
#endif // LOCATION_H
......@@ -3,8 +3,9 @@
#include "Location.h"
struct Location;
typedef struct Stack
{
Location* location;
struct Stack* next;
}Stack;
}Stack;
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment