Rev | Line | |
---|
[2889] | 1 | #ifndef _GGZClient_H__ |
---|
| 2 | #define _GGZClient_H__ |
---|
| 3 | |
---|
| 4 | #include "OrxonoxPrereqs.h" |
---|
[2997] | 5 | #include "objects/Tickable.h" |
---|
[2889] | 6 | |
---|
| 7 | #include <ggzmod.h> |
---|
[2997] | 8 | #include <boost/asio.hpp> |
---|
[2889] | 9 | |
---|
| 10 | namespace orxonox |
---|
| 11 | { |
---|
[2997] | 12 | class _OrxonoxExport GGZClient : public Tickable |
---|
[2889] | 13 | { |
---|
| 14 | public: |
---|
| 15 | GGZClient(); |
---|
| 16 | ~GGZClient(); |
---|
| 17 | |
---|
| 18 | static GGZClient& getInstance(); |
---|
[3000] | 19 | static bool isActive(); |
---|
[2997] | 20 | virtual void tick(const float dt); |
---|
[2889] | 21 | |
---|
| 22 | private: |
---|
| 23 | static GGZClient* singletonRef_s; |
---|
| 24 | |
---|
[2997] | 25 | GGZMod * ggzmod; |
---|
| 26 | boost::asio::io_service io; |
---|
[3000] | 27 | boost::asio::local::stream_protocol::socket ggzSocket; |
---|
| 28 | boost::asio::local::stream_protocol::socket gameSocket; |
---|
[2889] | 29 | |
---|
| 30 | void initGGZ(); |
---|
| 31 | void deinitGGZ(); |
---|
[3000] | 32 | static void handleGame(const boost::system::error_code& e); |
---|
| 33 | static void handleGGZ(const boost::system::error_code& e); |
---|
[2889] | 34 | static void handleGGZModServer(GGZMod * ggzmod, GGZModEvent e, |
---|
| 35 | const void *data); |
---|
| 36 | }; |
---|
| 37 | } |
---|
| 38 | |
---|
| 39 | #endif /* _GGZClient_H__ */ |
---|
Note: See
TracBrowser
for help on using the repository browser.