rFactorPluginServer/Include/PluginObjects.hpp
2022-02-09 14:27:02 +01:00

83 lines
3.4 KiB
C++

//ÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜÜ
//Ý Þ
//Ý Module: Header file for plugin object types Þ
//Ý Þ
//Ý Description: interface declarations for plugin objects Þ
//Ý Þ
//Ý This source code module, and all information, data, and algorithms Þ
//Ý associated with it, are part of isiMotor Technology (tm). Þ
//Ý PROPRIETARY AND CONFIDENTIAL Þ
//Ý Copyright (c) 1996-2013 Image Space Incorporated. All rights reserved. Þ
//Ý Þ
//Ý Change history: Þ
//Ý tag.2008.02.15: created Þ
//Ý Þ
//ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß
#ifndef _PLUGIN_OBJECTS_HPP_
#define _PLUGIN_OBJECTS_HPP_
// rF currently uses 4-byte packing ... whatever the current packing is will
// be restored at the end of this include with another #pragma.
#pragma pack( push, 4 )
//ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
//³ types of plugins ³
//ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
enum PluginObjectType
{
PO_INVALID = -1,
//-------------------
PO_GAMESTATS = 0,
PO_NCPLUGIN = 1,
PO_IVIBE = 2,
PO_INTERNALS = 3,
PO_RFONLINE = 4,
//-------------------
PO_MAXIMUM
};
//ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
//³ PluginObject ³
//³ - interface used by plugin classes. ³
//ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
class PluginObject
{
private:
class PluginInfo *mInfo; // used by main executable to obtain info about the plugin that implements this object
public:
void SetInfo( class PluginInfo *p ) { mInfo = p; } // used by main executable
class PluginInfo *GetInfo() const { return( mInfo ); } // used by main executable
class PluginInfo *GetInfo() { return( mInfo ); } // used by main executable
};
//ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
//³ typedefs for dll functions - easier to use a typedef than to type ³
//³ out the crazy syntax for declaring and casting function pointers ³
//ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
typedef const char * ( __cdecl *GETPLUGINNAME )();
typedef PluginObjectType ( __cdecl *GETPLUGINTYPE )();
typedef int ( __cdecl *GETPLUGINVERSION )();
typedef PluginObject * ( __cdecl *CREATEPLUGINOBJECT )();
typedef void ( __cdecl *DESTROYPLUGINOBJECT )( PluginObject *obj );
//ÚÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄ¿
//ÀÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÄÙ
// See #pragma at top of file
#pragma pack( pop )
#endif // _PLUGIN_OBJECTS_HPP_