From: Steven <laz...@us...> - 2008-04-02 06:33:30
|
Update of /cvsroot/oge/oge/include/oge/systems/scriptsystem In directory sc8-pr-cvs3.sourceforge.net:/tmp/cvs-serv9902/include/oge/systems/scriptsystem Modified Files: OgeScriptManager.h Log Message: 2008/04/02 - CVS HEAD v0.2.20 - Added Place and Physics components - Added several sub SceneManagers (gui, physics, etc) - Updated the licensing year to 2008 - Fix several small fixes NOTE: This version will be branched to the 0.2.20 cvs version. There will probably not be any new commit to this 0.2 branch. The HEAD will be cleaned completely (even the folders) and replaced by the refactoring code (aka 0.3). Index: OgeScriptManager.h =================================================================== RCS file: /cvsroot/oge/oge/include/oge/systems/scriptsystem/OgeScriptManager.h,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** OgeScriptManager.h 29 Aug 2007 10:21:03 -0000 1.6 --- OgeScriptManager.h 2 Apr 2008 06:33:00 -0000 1.7 *************** *** 4,8 **** For the latest info, see http://sourceforge.net/projects/oge ! Copyright (c) 2006 The OGE Team Also see acknowledgements in Readme.html --- 4,8 ---- For the latest info, see http://sourceforge.net/projects/oge ! Copyright (c) 2006-2008 The OGE Team Also see acknowledgements in Readme.html *************** *** 54,93 **** * @brief Manages the scripts (only Squirrel for now) * ! * @author Steven GAY ! *************************************************************************/ class OGEAPI ScriptManager : public Singleton<ScriptManager> { public: ! /** ! * Used to create a singleton manager, if the manager is already ! * created returns the pointer to the manager. ! * ! * @return A pointer to the manager instance ! * @author Steven GAY ! *************************************************************************/ ! static ScriptManager* createManager(void); ! /** ! * Used to destroy the singleton manager, ! * ! * @author Steven GAY ! *************************************************************************/ ! static void destroyManager(void); ! /** ! * Returns the pointer to the manager. ! * ! * @return A pointer to the manager instance ! * @author Steven GAY ! *************************************************************************/ ! static inline ScriptManager* getSingletonPtr(void) ! { ! assert(mSingleton); ! return mSingleton; ! }; /** * Initialise the manager * * @return True if initialisation was successfull, false if not. ! * @author Steven GAY ! *************************************************************************/ bool initialise(); /** --- 54,75 ---- * @brief Manages the scripts (only Squirrel for now) * ! * @author Steven 'lazalong' Gay ! ****************************************************************************/ class OGEAPI ScriptManager : public Singleton<ScriptManager> { public: ! friend class Singleton<class ScriptManager>; ! ! private: ! boost::recursive_mutex mMutex; ! bool mIsInitialised; ! HSQUIRRELVM mVM; // The Squirrel Virtual Machine ! ! public: /** * Initialise the manager * * @return True if initialisation was successfull, false if not. ! */ bool initialise(); /** *************** *** 96,105 **** * * @return True if initialisation was successfull, false if not. ! * @author Steven GAY ! *************************************************************************/ bool runScript( String scriptFile ); /** * Returns the Squirell Virtual Machine ! *************************************************************************/ HSQUIRRELVM getVM() { return mVM; }; /** --- 78,86 ---- * * @return True if initialisation was successfull, false if not. ! */ bool runScript( String scriptFile ); /** * Returns the Squirell Virtual Machine ! */ HSQUIRRELVM getVM() { return mVM; }; /** *************** *** 107,140 **** * This method is principally used for debugging on remote pc (testers) * and determine if the appropriate libraries are present. ! *************************************************************************/ const String getLibrariesVersion(); protected: /** * Redirect the Squirrel VM output * @note ! * @author Steven GAY ! *************************************************************************/ static void _printFunc(HSQUIRRELVM v,const SQChar * s,...); /** * Bind classes to Squirrel. * @note The classes are hard-coded in this method. ! * @author Steven GAY ! *************************************************************************/ ! void _bindClasses( ); private: - boost::recursive_mutex mMutex; /** ! * @author Steven GAY ! *************************************************************************/ ! ScriptManager(void); /** ! * @author Steven GAY ! *************************************************************************/ ! ~ScriptManager(void); ! ! bool mIsInitialised; ! HSQUIRRELVM mVM; // The Squirrel Virtual Machine ! }; ! } #endif --- 88,114 ---- * This method is principally used for debugging on remote pc (testers) * and determine if the appropriate libraries are present. ! */ const String getLibrariesVersion(); + protected: /** * Redirect the Squirrel VM output * @note ! */ static void _printFunc(HSQUIRRELVM v,const SQChar * s,...); /** * Bind classes to Squirrel. * @note The classes are hard-coded in this method. ! */ ! void _bindClasses(); ! private: /** ! */ ! ScriptManager(); /** ! */ ! ~ScriptManager(); }; ! } // namespace #endif |