mirror of
https://bitbucket.org/theswgsource/src-1.2.git
synced 2026-09-24 09:12:51 -04:00
83 lines
2.1 KiB
C++
Executable File
83 lines
2.1 KiB
C++
Executable File
//========================================================================
|
|
//
|
|
// ServerGroupObjectTemplate.h
|
|
//
|
|
//IMPORTANT: Any code between //@BEGIN TFD... and //@END TFD... will be
|
|
//overwritten the next time the template definition is compiled. Do not
|
|
//make changes to code inside these blocks.
|
|
//
|
|
// copyright 2001 Sony Online Entertainment
|
|
//
|
|
//========================================================================
|
|
|
|
#ifndef _INCLUDED_ServerGroupObjectTemplate_H
|
|
#define _INCLUDED_ServerGroupObjectTemplate_H
|
|
|
|
#include "ServerUniverseObjectTemplate.h"
|
|
#include "sharedFoundation/DynamicVariable.h"
|
|
#include "sharedUtility/TemplateParameter.h"
|
|
|
|
|
|
class Vector;
|
|
typedef StructParam<ObjectTemplate> StructParamOT;
|
|
//@BEGIN TFD TEMPLATE REFS
|
|
//@END TFD TEMPLATE REFS
|
|
|
|
|
|
class ServerGroupObjectTemplate : public ServerUniverseObjectTemplate
|
|
{
|
|
public:
|
|
//@BEGIN TFD ID
|
|
enum
|
|
{
|
|
ServerGroupObjectTemplate_tag = TAG(G,R,U,P)
|
|
};
|
|
//@END TFD ID
|
|
public:
|
|
ServerGroupObjectTemplate(const std::string & filename);
|
|
virtual ~ServerGroupObjectTemplate();
|
|
|
|
virtual Tag getId(void) const;
|
|
virtual Tag getTemplateVersion(void) const;
|
|
virtual Tag getHighestTemplateVersion(void) const;
|
|
static void install(bool allowDefaultTemplateParams = true);
|
|
|
|
//@BEGIN TFD
|
|
public:
|
|
|
|
|
|
protected:
|
|
virtual void load(Iff &file);
|
|
|
|
private:
|
|
//@END TFD
|
|
|
|
public:
|
|
// user functions
|
|
virtual Object * createObject(void) const;
|
|
|
|
private:
|
|
Tag m_templateVersion; // the template version
|
|
bool m_versionOk; // flag that the template version loaded is the one we expect
|
|
static bool ms_allowDefaultTemplateParams; // flag to allow defaut params instead of fataling
|
|
|
|
static void registerMe(void);
|
|
static ObjectTemplate * create(const std::string & filename);
|
|
|
|
// no copying
|
|
ServerGroupObjectTemplate(const ServerGroupObjectTemplate &);
|
|
ServerGroupObjectTemplate & operator =(const ServerGroupObjectTemplate &);
|
|
};
|
|
|
|
|
|
inline void ServerGroupObjectTemplate::install(bool allowDefaultTemplateParams)
|
|
{
|
|
ms_allowDefaultTemplateParams = allowDefaultTemplateParams;
|
|
//@BEGIN TFD INSTALL
|
|
ServerGroupObjectTemplate::registerMe();
|
|
//@END TFD INSTALL
|
|
}
|
|
|
|
|
|
#endif // _INCLUDED_ServerGroupObjectTemplate_H
|