summaryrefslogtreecommitdiff
path: root/src/state.h
diff options
context:
space:
mode:
authorGuillaume Melquiond <guillaume.melquiond@gmail.com>2006-09-02 18:29:30 +0000
committerGuillaume Melquiond <guillaume.melquiond@gmail.com>2006-09-02 18:29:30 +0000
commit8fe0239f5a369b63c43345e5078a52dbbe98dd9d (patch)
tree86004c0e453a8aa5b3f3ae8ee84e0aa57d67f309 /src/state.h
parentc5b2f8c8f4794b87018f94a0cdb369d8668c6aa0 (diff)
downloadmanaserv-8fe0239f5a369b63c43345e5078a52dbbe98dd9d.tar.gz
manaserv-8fe0239f5a369b63c43345e5078a52dbbe98dd9d.tar.bz2
manaserv-8fe0239f5a369b63c43345e5078a52dbbe98dd9d.tar.xz
manaserv-8fe0239f5a369b63c43345e5078a52dbbe98dd9d.zip
Implemented unique public IDs.
Diffstat (limited to 'src/state.h')
-rw-r--r--src/state.h38
1 files changed, 4 insertions, 34 deletions
diff --git a/src/state.h b/src/state.h
index 955b37da..07d466a1 100644
--- a/src/state.h
+++ b/src/state.h
@@ -26,34 +26,9 @@
#include <map>
-#include "player.h"
+#include "object.h"
-class Map;
-
-/**
- * Combined map/entity structure.
- */
-struct MapComposite {
- /**
- * Default constructor.
- */
- MapComposite() : map(NULL) { }
-
- /**
- * Actual map.
- */
- Map *map;
-
- /**
- * Objects (items, players, monsters, etc) located on the map.
- */
- Objects objects;
-
- /**
- * Players located on the map.
- */
- Players players;
-};
+class MapComposite;
/**
* State class contains all information/procedures associated with the game
@@ -64,7 +39,7 @@ class State
/**
* List of maps.
*/
- std::map<unsigned int, MapComposite> maps;
+ std::map<unsigned int, MapComposite *> maps;
public:
State();
@@ -76,14 +51,9 @@ class State
void update();
/**
- * Send game state to given player.
- */
- void informPlayer(PlayerPtr playerPtr);
-
- /**
* Load map into game world.
*/
- bool loadMap(unsigned mapId);
+ MapComposite *loadMap(unsigned mapId);
/**
* Add object to the map.