Last change
on this file since 620 was
620,
checked in by scheusso, 17 years ago
|
gamestatehandling, error correction
|
File size:
890 bytes
|
Rev | Line | |
---|
[416] | 1 | // |
---|
| 2 | // C++ Interface: GameStateClient |
---|
| 3 | // |
---|
| 4 | // Description: |
---|
| 5 | // |
---|
| 6 | // |
---|
| 7 | // Author: <>, (C) 2007 |
---|
| 8 | // |
---|
| 9 | // Copyright: See COPYING file that comes with this distribution |
---|
| 10 | // |
---|
| 11 | // |
---|
| 12 | #ifndef NETWORK_GAMESTATECLIENT_H |
---|
| 13 | #define NETWORK_GAMESTATECLIENT_H |
---|
| 14 | |
---|
| 15 | #include "zlib.h" |
---|
| 16 | #include "Synchronisable.h" |
---|
[496] | 17 | #include "orxonox/core/CoreIncludes.h" |
---|
[505] | 18 | #include "orxonox/objects/BaseObject.h" |
---|
[416] | 19 | #include "GameStateManager.h" |
---|
| 20 | |
---|
| 21 | namespace network { |
---|
| 22 | |
---|
| 23 | /** |
---|
| 24 | @author |
---|
| 25 | */ |
---|
| 26 | class GameStateClient{ |
---|
| 27 | public: |
---|
| 28 | GameStateClient(); |
---|
| 29 | ~GameStateClient(); |
---|
[620] | 30 | bool pushGameState(GameStateCompressed *compstate); |
---|
[416] | 31 | private: |
---|
| 32 | bool loadSnapshot(GameState state); |
---|
| 33 | GameState diff(GameState a, GameState b); |
---|
| 34 | GameState decompress(GameStateCompressed a); |
---|
| 35 | GameState decode(GameState a, GameStateCompressed x); |
---|
[436] | 36 | GameState decode(GameStateCompressed x); |
---|
[416] | 37 | void removeObject(orxonox::Iterator<Synchronisable> &it); |
---|
| 38 | |
---|
| 39 | GameState reference; |
---|
| 40 | }; |
---|
| 41 | |
---|
| 42 | } |
---|
| 43 | |
---|
| 44 | #endif |
---|
Note: See
TracBrowser
for help on using the repository browser.