summaryrefslogtreecommitdiff
path: root/src/interfacegats.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/interfacegats.cpp')
-rw-r--r--src/interfacegats.cpp29
1 files changed, 29 insertions, 0 deletions
diff --git a/src/interfacegats.cpp b/src/interfacegats.cpp
index 696c6b6..b6ad859 100644
--- a/src/interfacegats.cpp
+++ b/src/interfacegats.cpp
@@ -1,10 +1,15 @@
1#include "interfacegats.h" 1#include "interfacegats.h"
2 2
3#include "smlnode.h" 3#include "smlnode.h"
4#include "gamestate.h"
5
4#include "smlrendererhtml.h" 6#include "smlrendererhtml.h"
5 7
6#include <bu/plugger.h> 8#include <bu/plugger.h>
7#include <bu/sio.h> 9#include <bu/sio.h>
10#include <bu/file.h>
11#include <gats/gatsstream.h>
12#include <gats/types.h>
8 13
9using namespace Bu; 14using namespace Bu;
10 15
@@ -21,6 +26,30 @@ InterfaceGats::~InterfaceGats()
21 26
22void InterfaceGats::run( class Game *pGame ) 27void InterfaceGats::run( class Game *pGame )
23{ 28{
29 GameState gs( pGame, this );
30
31 {
32 Gats::GatsStream gsIn( sioRaw );
33 Gats::Object *pObj = gsIn.readObject();
34
35 if( pObj )
36 {
37 gs.fromGats( dynamic_cast<Gats::Dictionary *>(pObj) );
38
39 delete pObj;
40 }
41 else
42 {
43 gs.init();
44 }
45 }
46
47 gs.execCommand("status");
48
49 //{
50 // Gats::GatsStream gs
51 //pObj = gs.toGats();
52
24} 53}
25 54
26void InterfaceGats::display( const SmlNode *pSml ) 55void InterfaceGats::display( const SmlNode *pSml )