Planet
navi homePPSaboutscreenshotsdownloaddevelopmentforum

source: code/trunk/src/libraries/network/WANDiscovery.h @ 8497

Last change on this file since 8497 was 8351, checked in by rgrieder, 14 years ago

Merged kicklib2 branch back to trunk (includes former branches ois_update, mac_osx and kicklib).

Notes for updating

Linux:
You don't need an extra package for CEGUILua and Tolua, it's already shipped with CEGUI.
However you do need to make sure that the OgreRenderer is installed too with CEGUI 0.7 (may be a separate package).
Also, Orxonox now recognises if you install the CgProgramManager (a separate package available on newer Ubuntu on Debian systems).

Windows:
Download the new dependency packages versioned 6.0 and use these. If you have problems with that or if you don't like the in game console problem mentioned below, you can download the new 4.3 version of the packages (only available for Visual Studio 2005/2008).

Key new features:

  • *Support for Mac OS X*
  • Visual Studio 2010 support
  • Bullet library update to 2.77
  • OIS library update to 1.3
  • Support for CEGUI 0.7 —> Support for Arch Linux and even SuSE
  • Improved install target
  • Compiles now with GCC 4.6
  • Ogre Cg Shader plugin activated for Linux if available
  • And of course lots of bug fixes

There are also some regressions:

  • No support for CEGUI 0.5, Ogre 1.4 and boost 1.35 - 1.39 any more
  • In game console is not working in main menu for CEGUI 0.7
  • Tolua (just the C lib, not the application) and CEGUILua libraries are no longer in our repository. —> You will need to get these as well when compiling Orxonox
  • And of course lots of new bugs we don't yet know about
  • Property svn:eol-style set to native
File size: 3.2 KB
Line 
1/*
2 *   ORXONOX - the hottest 3D action shooter ever to exist > www.orxonox.net <
3 *
4 *
5 *   License notice:
6 *
7 *   This program is free software; you can redistribute it and/or modify it
8 *   under the terms of the GNU General Public License as published by the Free
9 *   Software Foundation; either version 2 of the License, or (at your option)
10 *   any later version.
11 *
12 *   This program is distributed in the hope that it will be useful, but
13 *   WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY
14 *   or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License
15 *   for more details.
16 *
17 *   You should have received a copy of the GNU General Public License along
18 *   with this program; if not, write to the Free Software Foundation, Inc., 51
19 *   Franklin Street, Fifth Floor, Boston, MA  02110-1301, USA.
20 *
21 *   Author: Fabian 'x3n' Landau (original) Co-authors: Sandro 'smerkli' Merkli
22 *   (copied and adapted to WAN)
23 *
24 */
25
26#ifndef _WANDiscovery_H__
27#define _WANDiscovery_H__
28
29#include "NetworkPrereqs.h"
30#include "packet/ServerInformation.h"
31#include "core/ConfigFileManager.h"
32#include "util/Singleton.h"
33#include "core/OrxonoxClass.h"
34#include "core/ConfigValueIncludes.h"
35#include "core/CoreIncludes.h"
36#include "MasterServerComm.h"
37#include "MasterServerProtocol.h"
38
39#include <vector>
40
41#define WANDISC_MAXTRIES 5
42
43// tolua_begin
44namespace orxonox
45{
46
47  class _NetworkExport WANDiscovery
48// tolua_end
49    : public Singleton<WANDiscovery>, public OrxonoxClass
50  { // tolua_export
51    friend class Singleton<WANDiscovery>;
52    public:
53      /** constructor */
54      WANDiscovery();
55
56      /** destructor */
57      ~WANDiscovery();
58
59      /** \return Address of the master server
60       *
61       * Get the master server address
62       */
63      std::string getMSAddress()
64      { return this->msaddress; }
65
66      /** ask server for server list  */
67      void discover(); // tolua_export
68
69      /** \param index Index to get the name of
70       * \return The name of the server
71       *
72       * Get the name of the server at index index.
73       */
74      std::string getServerListItemName( unsigned int index ); // tolua_export
75
76      /** \param index Index to get the IP of
77       * \return The IP of the server
78       *
79       * Get the IP of the server at index index.
80       */
81      std::string getServerListItemIP( unsigned int index ); // tolua_export
82
83      /** \return an instance of WANDiscovery
84       *
85       * Create and return an instance of WANDiscovery.
86       */
87      static WANDiscovery& getInstance() { return Singleton<WANDiscovery>::getInstance(); } // tolua_export
88   
89      /* todo: might make this private and use getter/setter methods
90       * at some later time.
91       */
92      /** game server list */
93      std::vector<packet::ServerInformation> servers_;
94
95      /** Function used for the configuration file parameter update */
96      void setConfigValues();
97
98      /** Master server communications object */
99      MasterServerComm msc;
100     
101    private:
102      /** Singleton pointer */
103      static WANDiscovery* singletonPtr_s;
104
105      /** master server address */
106      std::string msaddress;
107
108  }; // tolua_export
109
110} // tolua_export
111
112#endif // _WANDiscovery_H__
Note: See TracBrowser for help on using the repository browser.