sourcemm/sample_mm/SamplePlugin.h
author David Anderson <dvander@alliedmods.net>
Mon Apr 18 19:33:44 2005 +0000 (2005-04-18)
changeset 20 7d2ff2c0999b
parent 7 8ef11f6189e4
child 22 3fe8e457c5a2
permissions -rw-r--r--
Updated for API 004, also added sourcehook stuff again
     1 #ifndef _INCLUDE_SAMPLEPLUGIN_H
     2 #define _INCLUDE_SAMPLEPLUGIN_H
     3 
     4 #include <ISmmPlugin.h>
     5 
     6 class SamplePlugin : public ISmmPlugin
     7 {
     8 public:
     9 	bool Load(PluginId id, ISmmAPI *ismm, factories *list, char *error, size_t maxlen);
    10 	bool Unload(char *error, size_t maxlen);
    11 	void AllPluginsLoaded();
    12 	bool Pause(char *error, size_t maxlen)
    13 	{
    14 		return true;
    15 	}
    16 	bool Unpause(char *error, size_t maxlen)
    17 	{
    18 		return true;
    19 	}
    20 public:
    21 	int GetApiVersion() { return PLAPI_VERSION; }
    22 public:
    23 	const char *GetAuthor()
    24 	{
    25 		return "BAILOPAN";
    26 	}
    27 	const char *GetName()
    28 	{
    29 		return "Sample Plugin";
    30 	}
    31 	const char *GetDescription()
    32 	{
    33 		return "Sample plugin that hooks basic things";
    34 	}
    35 	const char *GetURL()
    36 	{
    37 		return "http://www.sourcemm.net/";
    38 	}
    39 	const char *GetLicense()
    40 	{
    41 		return "zlib/libpng";
    42 	}
    43 	const char *GetVersion()
    44 	{
    45 		return "1.00";
    46 	}
    47 	const char *GetDate()
    48 	{
    49 		return __DATE__;
    50 	}
    51 	const char *GetLogTag()
    52 	{
    53 		return "SAMPLE";
    54 	}
    55 };
    56 
    57 extern SamplePlugin g_SamplePlugin;
    58 PLUGIN_GLOBALVARS();
    59 
    60 #endif //_INCLUDE_SAMPLEPLUGIN_H