diff options
author | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-02-01 23:38:03 +0100 |
---|---|---|
committer | madmaxoft@gmail.com <madmaxoft@gmail.com@0a769ca7-a7f5-676a-18bf-c427514a06d6> | 2012-02-01 23:38:03 +0100 |
commit | 48d30d6ab4657e00c0c861d67285256daeff1142 (patch) | |
tree | b9dc6b6e59f09224fe3e2b80c5c247b44331e469 /source/cRoot.h | |
parent | Added all current hooks to the new plugin structure. (diff) | |
download | cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar.gz cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar.bz2 cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar.lz cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar.xz cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.tar.zst cuberite-48d30d6ab4657e00c0c861d67285256daeff1142.zip |
Diffstat (limited to '')
-rw-r--r-- | source/cRoot.h | 42 |
1 files changed, 32 insertions, 10 deletions
diff --git a/source/cRoot.h b/source/cRoot.h index 86b6ac28a..3179d72b0 100644 --- a/source/cRoot.h +++ b/source/cRoot.h @@ -1,5 +1,15 @@ +
#pragma once
+
+
+
+#include "cAuthenticator.h"
+
+
+
+
+
class cThread;
class cMonsterConfig;
class cMCLogger;
@@ -10,6 +20,7 @@ class cWebAdmin; class cPluginManager;
class cServer;
class cWorld;
+
class cRoot //tolua_export
{ //tolua_export
public:
@@ -31,24 +42,31 @@ public: cFurnaceRecipe* GetFurnaceRecipe() { return m_FurnaceRecipe; } //tolua_export
cWebAdmin* GetWebAdmin() { return m_WebAdmin; } //tolua_export
cPluginManager* GetPluginManager() { return m_PluginManager; } //tolua_export
+ cAuthenticator & GetAuthenticator() {return m_Authenticator; }
- void ServerCommand( const char* a_Cmd ); //tolua_export
+ void ServerCommand(const char* a_Cmd ); //tolua_export
+
+ void KickUser(const AString & iUserName, const AString & iReason); // Kicks the user, no matter in what world they are. Used from cAuthenticator
+ void AuthenticateUser(const AString & iUserName); // Called by cAuthenticator to auth the specified user
void TickWorlds( float a_Dt );
+
private:
+
void LoadWorlds();
void UnloadWorlds();
- cServer* m_Server;
- cMonsterConfig *m_MonsterConfig;
+ cServer * m_Server;
+ cMonsterConfig * m_MonsterConfig;
- cGroupManager* m_GroupManager;
- cRecipeChecker* m_RecipeChecker;
- cFurnaceRecipe* m_FurnaceRecipe;
- cWebAdmin* m_WebAdmin;
- cPluginManager* m_PluginManager;
+ cGroupManager * m_GroupManager;
+ cRecipeChecker * m_RecipeChecker;
+ cFurnaceRecipe * m_FurnaceRecipe;
+ cWebAdmin * m_WebAdmin;
+ cPluginManager * m_PluginManager;
+ cAuthenticator m_Authenticator;
- cMCLogger* m_Log;
+ cMCLogger * m_Log;
bool m_bStop;
bool m_bRestart;
@@ -60,4 +78,8 @@ private: static void InputThread(void* a_Params);
static cRoot* s_Root;
-}; //tolua_export
\ No newline at end of file +}; //tolua_export
+
+
+
+
|