You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
61 lines
1.6 KiB
C++
61 lines
1.6 KiB
C++
#ifndef OPENMW_MWMP_MAIN
|
|
#define OPENMW_MWMP_MAIN
|
|
|
|
#include "../mwworld/ptr.hpp"
|
|
#include <boost/program_options.hpp>
|
|
#include <components/files/collections.hpp>
|
|
|
|
namespace mwmp
|
|
{
|
|
class GUIController;
|
|
class CellController;
|
|
class LocalPlayer;
|
|
class Networking;
|
|
|
|
class Main
|
|
{
|
|
public:
|
|
Main();
|
|
~Main();
|
|
|
|
static void optionsDesc(boost::program_options::options_description *desc);
|
|
static void configure(const boost::program_options::variables_map &variables);
|
|
static bool init(std::vector<std::string> &content, Files::Collections &collections);
|
|
static void postInit();
|
|
static void destroy();
|
|
static const Main &get();
|
|
static void frame(float dt);
|
|
static void pressedKey(int key);
|
|
|
|
static bool isValidPacketScript(std::string script);
|
|
static std::string getResDir();
|
|
|
|
Networking *getNetworking() const;
|
|
LocalPlayer *getLocalPlayer() const;
|
|
GUIController *getGUIController() const;
|
|
CellController *getCellController() const;
|
|
|
|
void updateWorld(float dt) const;
|
|
|
|
private:
|
|
static std::string resourceDir;
|
|
static std::string address;
|
|
static std::string serverPassword;
|
|
Main (const Main&);
|
|
///< not implemented
|
|
Main& operator= (const Main&);
|
|
///< not implemented
|
|
static Main *pMain;
|
|
Networking *mNetworking;
|
|
LocalPlayer *mLocalPlayer;
|
|
|
|
GUIController *mGUIController;
|
|
CellController *mCellController;
|
|
|
|
std::string server;
|
|
unsigned short port;
|
|
};
|
|
}
|
|
|
|
#endif //OPENMW_MWMP_MAIN
|