|
ds@1990
|
1 |
/** |
|
ds@1990
|
2 |
* vim: set ts=4 : |
|
ds@1990
|
3 |
* ============================================================================= |
|
ds@1990
|
4 |
* SourceMod Extension Code for Metamod:Source |
|
ds@1990
|
5 |
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved. |
|
ds@1990
|
6 |
* ============================================================================= |
|
ds@1990
|
7 |
* |
|
ds@1990
|
8 |
* This program is free software; you can redistribute it and/or modify it under |
|
ds@1990
|
9 |
* the terms of the GNU General Public License, version 3.0, as published by the |
|
ds@1990
|
10 |
* Free Software Foundation. |
|
ds@1990
|
11 |
* |
|
ds@1990
|
12 |
* This program is distributed in the hope that it will be useful, but WITHOUT |
|
ds@1990
|
13 |
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS |
|
ds@1990
|
14 |
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more |
|
ds@1990
|
15 |
* details. |
|
ds@1990
|
16 |
* |
|
ds@1990
|
17 |
* You should have received a copy of the GNU General Public License along with |
|
ds@1990
|
18 |
* this program. If not, see <http://www.gnu.org/licenses/>. |
|
ds@1990
|
19 |
* |
|
ds@1990
|
20 |
* As a special exception, AlliedModders LLC gives you permission to link the |
|
ds@1990
|
21 |
* code of this program (as well as its derivative works) to "Half-Life 2," the |
|
ds@1990
|
22 |
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software |
|
ds@1990
|
23 |
* by the Valve Corporation. You must obey the GNU General Public License in |
|
ds@1990
|
24 |
* all respects for all other code used. Additionally, AlliedModders LLC grants |
|
ds@1990
|
25 |
* this exception to all derivative works. AlliedModders LLC defines further |
|
ds@1990
|
26 |
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007), |
|
ds@1990
|
27 |
* or <http://www.sourcemod.net/license.php>. |
|
ds@1990
|
28 |
* |
|
ds@1990
|
29 |
* Version: $Id$ |
|
ds@1990
|
30 |
*/ |
|
ds@1990
|
31 |
|
|
ds@1990
|
32 |
#ifndef _INCLUDE_SAMPLE_MMS_SOURCEMOD_EXTENSION_ |
|
ds@1990
|
33 |
#define _INCLUDE_SAMPLE_MMS_SOURCEMOD_EXTENSION_ |
|
ds@1990
|
34 |
|
|
ds@1990
|
35 |
#include "sm_sdk_config.h" |
|
ds@1990
|
36 |
|
|
ds@1990
|
37 |
using namespace SourceMod; |
|
ds@1990
|
38 |
|
|
ds@1990
|
39 |
class MyExtension : public IExtensionInterface |
|
ds@1990
|
40 |
{ |
|
ds@1990
|
41 |
public: |
|
ds@1990
|
42 |
virtual bool OnExtensionLoad(IExtension *me, |
|
ds@1990
|
43 |
IShareSys *sys, |
|
ds@1990
|
44 |
char *error, |
|
ds@1990
|
45 |
size_t maxlength, |
|
ds@1990
|
46 |
bool late); |
|
ds@1990
|
47 |
virtual void OnExtensionUnload(); |
|
ds@1990
|
48 |
virtual void OnExtensionsAllLoaded(); |
|
ds@1990
|
49 |
virtual void OnExtensionPauseChange(bool pause); |
|
ds@1990
|
50 |
virtual bool QueryRunning(char *error, size_t maxlength); |
|
ds@1990
|
51 |
virtual bool IsMetamodExtension(); |
|
ds@1990
|
52 |
virtual const char *GetExtensionName(); |
|
ds@1990
|
53 |
virtual const char *GetExtensionURL(); |
|
ds@1990
|
54 |
virtual const char *GetExtensionTag(); |
|
ds@1990
|
55 |
virtual const char *GetExtensionAuthor(); |
|
ds@1990
|
56 |
virtual const char *GetExtensionVerString(); |
|
ds@1990
|
57 |
virtual const char *GetExtensionDescription(); |
|
ds@1990
|
58 |
virtual const char *GetExtensionDateString(); |
|
ds@1990
|
59 |
}; |
|
ds@1990
|
60 |
|
|
ds@1990
|
61 |
bool SM_LoadExtension(char *error, size_t maxlength); |
|
ds@1990
|
62 |
void SM_UnloadExtension(); |
|
ds@1990
|
63 |
|
|
ds@1990
|
64 |
extern IShareSys *sharesys; |
|
ds@1990
|
65 |
extern IExtension *myself; |
|
ds@1990
|
66 |
extern MyExtension g_SMExt; |
|
ds@1990
|
67 |
|
|
ds@1990
|
68 |
#endif //_INCLUDE_SAMPLE_MMS_SOURCEMOD_EXTENSION_ |
|
ds@1990
|
69 |
|