Added more missing svn:keywords properties to some files (this should be the last of them before I never have to do this again)
Moved sm_memtable files in sqlite extension to sdk directory (to be consistent with topmenus) Some extension source files had an incorrect extension name in their headers Updated copyright year on some rarely altered files --HG-- branch : sourcemod-1.0.x extra : convert_revision : svn%3A39bc706e-5318-0410-9160-8a85361fbb7c/branches/sourcemod-1.0.x%402038
This commit is contained in:
parent
be8146364f
commit
aff4431eea
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod Core"
|
VALUE "FileDescription", "SourceMod Core"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "sourcemod"
|
VALUE "InternalName", "sourcemod"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "sourcemod_mm.dll"
|
VALUE "OriginalFilename", "sourcemod_mm.dll"
|
||||||
VALUE "ProductName", "SourceMod"
|
VALUE "ProductName", "SourceMod"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod BinTools Extension
|
* SourceMod BinTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod BinTools Extension
|
* SourceMod BinTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod BinTools Extension
|
* SourceMod BinTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod BinTools Extension"
|
VALUE "FileDescription", "SourceMod BinTools Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod BinTools Extension"
|
VALUE "InternalName", "SourceMod BinTools Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "bintools.ext.dll"
|
VALUE "OriginalFilename", "bintools.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod BinTools Extension"
|
VALUE "ProductName", "SourceMod BinTools Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Counter-Strike:Source Extension
|
* SourceMod Counter-Strike:Source Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod Counter-Strike:Source Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod Counter-Strike:Source Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod CS:S Extension"
|
VALUE "FileDescription", "SourceMod CS:S Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod CS:S Extension"
|
VALUE "InternalName", "SourceMod CS:S Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "game.cstrike.ext.dll"
|
VALUE "OriginalFilename", "game.cstrike.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod CS:S Extension"
|
VALUE "ProductName", "SourceMod CS:S Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod GeoIP Extension
|
* SourceMod GeoIP Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod GeoIP Extension
|
* SourceMod GeoIP Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod GeoIP Extension
|
* SourceMod GeoIP Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod GeoIP Extension"
|
VALUE "FileDescription", "SourceMod GeoIP Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod GeoIP Extension"
|
VALUE "InternalName", "SourceMod GeoIP Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "geoip.ext.dll"
|
VALUE "OriginalFilename", "geoip.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod GeoIP Extension"
|
VALUE "ProductName", "SourceMod GeoIP Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod MySQL Extension
|
* SourceMod MySQL Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod MySQL Extension
|
* SourceMod MySQL Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod MySQL Extension
|
* SourceMod MySQL Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod MySQL Extension"
|
VALUE "FileDescription", "SourceMod MySQL Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod MySQL Extension"
|
VALUE "InternalName", "SourceMod MySQL Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "dbi.mysql.ext.dll"
|
VALUE "OriginalFilename", "dbi.mysql.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod MySQL Extension"
|
VALUE "ProductName", "SourceMod MySQL Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -1,155 +1,155 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Regular Expressions Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id$
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "pcre.h"
|
#include "pcre.h"
|
||||||
#include "CRegEx.h"
|
#include "CRegEx.h"
|
||||||
#include <sh_string.h>
|
#include <sh_string.h>
|
||||||
#include "extension.h"
|
#include "extension.h"
|
||||||
|
|
||||||
RegEx::RegEx()
|
RegEx::RegEx()
|
||||||
{
|
{
|
||||||
mErrorOffset = 0;
|
mErrorOffset = 0;
|
||||||
mError = NULL;
|
mError = NULL;
|
||||||
re = NULL;
|
re = NULL;
|
||||||
mFree = true;
|
mFree = true;
|
||||||
subject = NULL;
|
subject = NULL;
|
||||||
mSubStrings = 0;
|
mSubStrings = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
void RegEx::Clear ()
|
void RegEx::Clear ()
|
||||||
{
|
{
|
||||||
mErrorOffset = 0;
|
mErrorOffset = 0;
|
||||||
mError = NULL;
|
mError = NULL;
|
||||||
if (re)
|
if (re)
|
||||||
pcre_free(re);
|
pcre_free(re);
|
||||||
re = NULL;
|
re = NULL;
|
||||||
mFree = true;
|
mFree = true;
|
||||||
if (subject)
|
if (subject)
|
||||||
delete [] subject;
|
delete [] subject;
|
||||||
subject = NULL;
|
subject = NULL;
|
||||||
mSubStrings = 0;
|
mSubStrings = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
RegEx::~RegEx()
|
RegEx::~RegEx()
|
||||||
{
|
{
|
||||||
Clear();
|
Clear();
|
||||||
}
|
}
|
||||||
|
|
||||||
bool RegEx::isFree(bool set, bool val)
|
bool RegEx::isFree(bool set, bool val)
|
||||||
{
|
{
|
||||||
if (set)
|
if (set)
|
||||||
{
|
{
|
||||||
mFree = val;
|
mFree = val;
|
||||||
return true;
|
return true;
|
||||||
} else {
|
} else {
|
||||||
return mFree;
|
return mFree;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
int RegEx::Compile(const char *pattern, int iFlags)
|
int RegEx::Compile(const char *pattern, int iFlags)
|
||||||
{
|
{
|
||||||
if (!mFree)
|
if (!mFree)
|
||||||
Clear();
|
Clear();
|
||||||
|
|
||||||
re = pcre_compile(pattern, iFlags, &mError, &mErrorOffset, NULL);
|
re = pcre_compile(pattern, iFlags, &mError, &mErrorOffset, NULL);
|
||||||
|
|
||||||
if (re == NULL)
|
if (re == NULL)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
mFree = false;
|
mFree = false;
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
int RegEx::Match(const char *str)
|
int RegEx::Match(const char *str)
|
||||||
{
|
{
|
||||||
int rc = 0;
|
int rc = 0;
|
||||||
|
|
||||||
if (mFree || re == NULL)
|
if (mFree || re == NULL)
|
||||||
return -1;
|
return -1;
|
||||||
|
|
||||||
this->ClearMatch();
|
this->ClearMatch();
|
||||||
|
|
||||||
//save str
|
//save str
|
||||||
subject = new char[strlen(str)+1];
|
subject = new char[strlen(str)+1];
|
||||||
strcpy(subject, str);
|
strcpy(subject, str);
|
||||||
|
|
||||||
rc = pcre_exec(re, NULL, subject, (int)strlen(subject), 0, 0, ovector, 30);
|
rc = pcre_exec(re, NULL, subject, (int)strlen(subject), 0, 0, ovector, 30);
|
||||||
|
|
||||||
if (rc < 0)
|
if (rc < 0)
|
||||||
{
|
{
|
||||||
if (rc == PCRE_ERROR_NOMATCH)
|
if (rc == PCRE_ERROR_NOMATCH)
|
||||||
{
|
{
|
||||||
return 0;
|
return 0;
|
||||||
} else {
|
} else {
|
||||||
mErrorOffset = rc;
|
mErrorOffset = rc;
|
||||||
return -1;
|
return -1;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
mSubStrings = rc;
|
mSubStrings = rc;
|
||||||
|
|
||||||
return 1;
|
return 1;
|
||||||
}
|
}
|
||||||
void RegEx::ClearMatch()
|
void RegEx::ClearMatch()
|
||||||
{
|
{
|
||||||
// Clears match results
|
// Clears match results
|
||||||
mErrorOffset = 0;
|
mErrorOffset = 0;
|
||||||
mError = NULL;
|
mError = NULL;
|
||||||
if (subject)
|
if (subject)
|
||||||
delete [] subject;
|
delete [] subject;
|
||||||
subject = NULL;
|
subject = NULL;
|
||||||
mSubStrings = 0;
|
mSubStrings = 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
const char *RegEx::GetSubstring(int s, char buffer[], int max)
|
const char *RegEx::GetSubstring(int s, char buffer[], int max)
|
||||||
{
|
{
|
||||||
int i = 0;
|
int i = 0;
|
||||||
if (s >= mSubStrings || s < 0)
|
if (s >= mSubStrings || s < 0)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
char *substr_a = subject + ovector[2*s];
|
char *substr_a = subject + ovector[2*s];
|
||||||
int substr_l = ovector[2*s+1] - ovector[2*s];
|
int substr_l = ovector[2*s+1] - ovector[2*s];
|
||||||
|
|
||||||
for (i = 0; i<substr_l; i++)
|
for (i = 0; i<substr_l; i++)
|
||||||
{
|
{
|
||||||
if (i >= max)
|
if (i >= max)
|
||||||
break;
|
break;
|
||||||
buffer[i] = substr_a[i];
|
buffer[i] = substr_a[i];
|
||||||
}
|
}
|
||||||
|
|
||||||
buffer[i] = '\0';
|
buffer[i] = '\0';
|
||||||
|
|
||||||
return buffer;
|
return buffer;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1,59 +1,59 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Regular Expressions Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id$
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#ifndef _INCLUDE_CREGEX_H
|
#ifndef _INCLUDE_CREGEX_H
|
||||||
#define _INCLUDE_CREGEX_H
|
#define _INCLUDE_CREGEX_H
|
||||||
|
|
||||||
class RegEx
|
class RegEx
|
||||||
{
|
{
|
||||||
public:
|
public:
|
||||||
RegEx();
|
RegEx();
|
||||||
~RegEx();
|
~RegEx();
|
||||||
bool isFree(bool set=false, bool val=false);
|
bool isFree(bool set=false, bool val=false);
|
||||||
void Clear();
|
void Clear();
|
||||||
|
|
||||||
int Compile(const char *pattern, int iFlags);
|
int Compile(const char *pattern, int iFlags);
|
||||||
int Match(const char *str);
|
int Match(const char *str);
|
||||||
void ClearMatch();
|
void ClearMatch();
|
||||||
const char *GetSubstring(int s, char buffer[], int max);
|
const char *GetSubstring(int s, char buffer[], int max);
|
||||||
public:
|
public:
|
||||||
int mErrorOffset;
|
int mErrorOffset;
|
||||||
const char *mError;
|
const char *mError;
|
||||||
int mSubStrings;
|
int mSubStrings;
|
||||||
private:
|
private:
|
||||||
pcre *re;
|
pcre *re;
|
||||||
bool mFree;
|
bool mFree;
|
||||||
int ovector[30];
|
int ovector[30];
|
||||||
char *subject;
|
char *subject;
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif //_INCLUDE_CREGEX_H
|
#endif //_INCLUDE_CREGEX_H
|
||||||
|
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -38,7 +38,7 @@ using namespace SourceHook;
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @file extension.cpp
|
* @file extension.cpp
|
||||||
* @brief Implement extension code here.
|
* @brief Implement Regex extension code here.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
RegexExtension g_RegexExtension; /**< Global singleton for extension's main interface */
|
RegexExtension g_RegexExtension; /**< Global singleton for extension's main interface */
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -34,7 +34,7 @@
|
|||||||
|
|
||||||
/**
|
/**
|
||||||
* @file extension.h
|
* @file extension.h
|
||||||
* @brief Sample extension code header.
|
* @brief Regex extension code header.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#include "smsdk_ext.h"
|
#include "smsdk_ext.h"
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod Regular Expressions Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod SDKTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod SDKTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod SDKTools Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod SDKTools Extension"
|
VALUE "FileDescription", "SourceMod SDKTools Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod SDKTools Extension"
|
VALUE "InternalName", "SourceMod SDKTools Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "sdktools.ext.dll"
|
VALUE "OriginalFilename", "sdktools.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod SDKTools Extension"
|
VALUE "ProductName", "SourceMod SDKTools Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -17,7 +17,7 @@ PROJECT = dbi.sqlite
|
|||||||
#Uncomment for Metamod: Source enabled extension
|
#Uncomment for Metamod: Source enabled extension
|
||||||
#USEMETA = true
|
#USEMETA = true
|
||||||
|
|
||||||
OBJECTS = sdk/smsdk_ext.cpp extension.cpp sm_memtable.cpp \
|
OBJECTS = sdk/smsdk_ext.cpp sdk/sm_memtable.cpp extension.cpp \
|
||||||
driver/SqDatabase.cpp driver/SqDriver.cpp driver/SqQuery.cpp \
|
driver/SqDatabase.cpp driver/SqDriver.cpp driver/SqQuery.cpp \
|
||||||
driver/SqResults.cpp
|
driver/SqResults.cpp
|
||||||
|
|
||||||
|
@ -189,10 +189,6 @@
|
|||||||
RelativePath="..\extension.cpp"
|
RelativePath="..\extension.cpp"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
<File
|
|
||||||
RelativePath="..\sm_memtable.cpp"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
</Filter>
|
||||||
<Filter
|
<Filter
|
||||||
Name="Header Files"
|
Name="Header Files"
|
||||||
@ -203,10 +199,6 @@
|
|||||||
RelativePath="..\extension.h"
|
RelativePath="..\extension.h"
|
||||||
>
|
>
|
||||||
</File>
|
</File>
|
||||||
<File
|
|
||||||
RelativePath="..\sm_memtable.h"
|
|
||||||
>
|
|
||||||
</File>
|
|
||||||
</Filter>
|
</Filter>
|
||||||
<Filter
|
<Filter
|
||||||
Name="Resource Files"
|
Name="Resource Files"
|
||||||
@ -226,6 +218,14 @@
|
|||||||
Name="SourceMod SDK"
|
Name="SourceMod SDK"
|
||||||
UniqueIdentifier="{31958233-BB2D-4e41-A8F9-CE8A4684F436}"
|
UniqueIdentifier="{31958233-BB2D-4e41-A8F9-CE8A4684F436}"
|
||||||
>
|
>
|
||||||
|
<File
|
||||||
|
RelativePath="..\sdk\sm_memtable.cpp"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
|
<File
|
||||||
|
RelativePath="..\sdk\sm_memtable.h"
|
||||||
|
>
|
||||||
|
</File>
|
||||||
<File
|
<File
|
||||||
RelativePath="..\sdk\smsdk_config.h"
|
RelativePath="..\sdk\smsdk_config.h"
|
||||||
>
|
>
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod SQLite Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod SQLite Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod SQLite Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod SQLite Extension"
|
VALUE "FileDescription", "SourceMod SQLite Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod SQLite Extension"
|
VALUE "InternalName", "SourceMod SQLite Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "dbi.sqlite.ext.dll"
|
VALUE "OriginalFilename", "dbi.sqlite.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod SQLite Extension"
|
VALUE "ProductName", "SourceMod SQLite Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod TF2 Extension
|
* SourceMod Team Fortress 2 Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod TF2 Extension
|
* SourceMod Team Fortress 2 Extension
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod Team Fortress 2 Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Team Fortress 2 Extension
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Team Fortress 2 Extension
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod Team Fortress 2 Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SDKTools Extension
|
* SourceMod Team Fortress 2 Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -17,8 +17,8 @@ PROJECT = topmenus
|
|||||||
#Uncomment for Metamod: Source enabled extension
|
#Uncomment for Metamod: Source enabled extension
|
||||||
#USEMETA = true
|
#USEMETA = true
|
||||||
|
|
||||||
OBJECTS = sdk/smsdk_ext.cpp extension.cpp TopMenuManager.cpp TopMenu.cpp \
|
OBJECTS = sdk/smsdk_ext.cpp sdk/sm_memtable.cpp extension.cpp TopMenuManager.cpp \
|
||||||
sdk/sm_memtable.cpp smn_topmenus.cpp
|
TopMenu.cpp smn_topmenus.cpp
|
||||||
|
|
||||||
##############################################
|
##############################################
|
||||||
### CONFIGURE ANY OTHER FLAGS/OPTIONS HERE ###
|
### CONFIGURE ANY OTHER FLAGS/OPTIONS HERE ###
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Base Extension Code
|
* SourceMod Base Extension Code
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Sample Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -1,8 +1,8 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod SQLite Extension
|
* SourceMod TopMenus Extension
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod TopMenus Extension"
|
VALUE "FileDescription", "SourceMod TopMenus Extension"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "SourceMod TopMenus Extension"
|
VALUE "InternalName", "SourceMod TopMenus Extension"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "topmenus.ext.dll"
|
VALUE "OriginalFilename", "topmenus.ext.dll"
|
||||||
VALUE "ProductName", "SourceMod TopMenus Extension"
|
VALUE "ProductName", "SourceMod TopMenus Extension"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod
|
* SourceMod
|
||||||
* Copyright (C) 2004-2007 AlliedModders LLC. All rights reserved.
|
* Copyright (C) 2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -49,7 +49,7 @@ BEGIN
|
|||||||
VALUE "FileDescription", "SourceMod Loader"
|
VALUE "FileDescription", "SourceMod Loader"
|
||||||
VALUE "FileVersion", SVN_FULL_VERSION
|
VALUE "FileVersion", SVN_FULL_VERSION
|
||||||
VALUE "InternalName", "sourcemod"
|
VALUE "InternalName", "sourcemod"
|
||||||
VALUE "LegalCopyright", "Copyright (c) 2004-2007, AlliedModders LLC"
|
VALUE "LegalCopyright", "Copyright (c) 2004-2008, AlliedModders LLC"
|
||||||
VALUE "OriginalFilename", "sourcemod_mm.dll"
|
VALUE "OriginalFilename", "sourcemod_mm.dll"
|
||||||
VALUE "ProductName", "SourceMod Loader"
|
VALUE "ProductName", "SourceMod Loader"
|
||||||
VALUE "ProductVersion", SVN_FULL_VERSION
|
VALUE "ProductVersion", SVN_FULL_VERSION
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands
|
* SourceMod Basecommands
|
||||||
* Functionality related to banning.
|
* Functionality related to banning.
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
PrepareBan(client, target, time, const String:reason[])
|
PrepareBan(client, target, time, const String:reason[])
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecomm
|
* SourceMod Basecomm
|
||||||
* Part of Basecomm plugin, menu and other functionality.
|
* Part of Basecomm plugin, menu and other functionality.
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
enum CommType
|
enum CommType
|
||||||
|
@ -1,75 +1,75 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides cancelvote functionality.
|
* Provides cancelvote functionality.
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
PerformCancelVote(client)
|
PerformCancelVote(client)
|
||||||
{
|
{
|
||||||
if (!IsVoteInProgress())
|
if (!IsVoteInProgress())
|
||||||
{
|
{
|
||||||
ReplyToCommand(client, "[SM] %t", "Vote Not In Progress");
|
ReplyToCommand(client, "[SM] %t", "Vote Not In Progress");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
ShowActivity2(client, "[SM] ", "%t", "Cancelled Vote");
|
ShowActivity2(client, "[SM] ", "%t", "Cancelled Vote");
|
||||||
|
|
||||||
CancelVote();
|
CancelVote();
|
||||||
}
|
}
|
||||||
|
|
||||||
public AdminMenu_CancelVote(Handle:topmenu,
|
public AdminMenu_CancelVote(Handle:topmenu,
|
||||||
TopMenuAction:action,
|
TopMenuAction:action,
|
||||||
TopMenuObject:object_id,
|
TopMenuObject:object_id,
|
||||||
param,
|
param,
|
||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength)
|
maxlength)
|
||||||
{
|
{
|
||||||
if (action == TopMenuAction_DisplayOption)
|
if (action == TopMenuAction_DisplayOption)
|
||||||
{
|
{
|
||||||
Format(buffer, maxlength, "%T", "Cancel vote", param);
|
Format(buffer, maxlength, "%T", "Cancel vote", param);
|
||||||
}
|
}
|
||||||
else if (action == TopMenuAction_SelectOption)
|
else if (action == TopMenuAction_SelectOption)
|
||||||
{
|
{
|
||||||
PerformCancelVote(param);
|
PerformCancelVote(param);
|
||||||
RedisplayAdminMenu(topmenu, param);
|
RedisplayAdminMenu(topmenu, param);
|
||||||
}
|
}
|
||||||
else if (action == TopMenuAction_DrawOption)
|
else if (action == TopMenuAction_DrawOption)
|
||||||
{
|
{
|
||||||
buffer[0] = IsVoteInProgress() ? ITEMDRAW_DEFAULT : ITEMDRAW_IGNORE;
|
buffer[0] = IsVoteInProgress() ? ITEMDRAW_DEFAULT : ITEMDRAW_IGNORE;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
public Action:Command_CancelVote(client, args)
|
public Action:Command_CancelVote(client, args)
|
||||||
{
|
{
|
||||||
PerformCancelVote(client);
|
PerformCancelVote(client);
|
||||||
|
|
||||||
return Plugin_Handled;
|
return Plugin_Handled;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides exec cfg functionality
|
* Provides exec cfg functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
new Handle:g_ConfigMenu = INVALID_HANDLE;
|
new Handle:g_ConfigMenu = INVALID_HANDLE;
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides kick functionality
|
* Provides kick functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides map functionality
|
* Provides map functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public MenuHandler_ChangeMap(Handle:menu, MenuAction:action, param1, param2)
|
public MenuHandler_ChangeMap(Handle:menu, MenuAction:action, param1, param2)
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides reloadadmins functionality.
|
* Provides reloadadmins functionality.
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basecommands Plugin
|
* SourceMod Basecommands Plugin
|
||||||
* Provides sm_who functionality
|
* Provides sm_who functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
PerformWho(client, target, ReplySource:reply, bool:is_admin)
|
PerformWho(client, target, ReplySource:reply, bool:is_admin)
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basevotes Plugin
|
* SourceMod Basevotes Plugin
|
||||||
* Provides ban functionality
|
* Provides ban functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
DisplayVoteBanMenu(client, target)
|
DisplayVoteBanMenu(client, target)
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basevotes Plugin
|
* SourceMod Basevotes Plugin
|
||||||
* Provides kick functionality
|
* Provides kick functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basevotes Plugin
|
* SourceMod Basevotes Plugin
|
||||||
* Provides map functionality
|
* Provides map functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
new Handle:g_MapList = INVALID_HANDLE;
|
new Handle:g_MapList = INVALID_HANDLE;
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basefunvotes Plugin
|
* SourceMod Basefunvotes Plugin
|
||||||
* Provides votealltalk functionality
|
* Provides votealltalk functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
DisplayVoteAllTalkMenu(client)
|
DisplayVoteAllTalkMenu(client)
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basefunvotes Plugin
|
* SourceMod Basefunvotes Plugin
|
||||||
* Provides voteburn functionality
|
* Provides voteburn functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
DisplayVoteBurnMenu(client, target, String:name[])
|
DisplayVoteBurnMenu(client, target, String:name[])
|
||||||
|
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
DisplayVoteFFMenu(client)
|
DisplayVoteFFMenu(client)
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basefunvotes Plugin
|
* SourceMod Basefunvotes Plugin
|
||||||
* Provides votegravity functionality
|
* Provides votegravity functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@ -4,7 +4,7 @@
|
|||||||
* SourceMod Basefunvotes Plugin
|
* SourceMod Basefunvotes Plugin
|
||||||
* Provides voteslay functionality
|
* Provides voteslay functionality
|
||||||
*
|
*
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
@ -28,7 +28,7 @@
|
|||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id: admin-flatfile.sp 1438 2007-09-16 03:45:06Z dvander $
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
|
|
||||||
|
@ -1,325 +1,325 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This file is part of the SourceMod/SourcePawn SDK.
|
* This file is part of the SourceMod/SourcePawn SDK.
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id$
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if defined _bitbuffer_included
|
#if defined _bitbuffer_included
|
||||||
#endinput
|
#endinput
|
||||||
#endif
|
#endif
|
||||||
#define _bitbuffer_included
|
#define _bitbuffer_included
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a single bit to a writable bitbuffer (bf_write).
|
* Writes a single bit to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param bit Bit to write (true for 1, false for 0).
|
* @param bit Bit to write (true for 1, false for 0).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteBool(Handle:bf, bool:bit);
|
native BfWriteBool(Handle:bf, bool:bit);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a byte to a writable bitbuffer (bf_write).
|
* Writes a byte to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param byte Byte to write (value will be written as 8bit).
|
* @param byte Byte to write (value will be written as 8bit).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteByte(Handle:bf, byte);
|
native BfWriteByte(Handle:bf, byte);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a byte to a writable bitbuffer (bf_write).
|
* Writes a byte to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param chr Character to write.
|
* @param chr Character to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteChar(Handle:bf, chr);
|
native BfWriteChar(Handle:bf, chr);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a 16bit integer to a writable bitbuffer (bf_write).
|
* Writes a 16bit integer to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param num Integer to write (value will be written as 16bit).
|
* @param num Integer to write (value will be written as 16bit).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteShort(Handle:bf, num);
|
native BfWriteShort(Handle:bf, num);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a 16bit unsigned integer to a writable bitbuffer (bf_write).
|
* Writes a 16bit unsigned integer to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param num Integer to write (value will be written as 16bit).
|
* @param num Integer to write (value will be written as 16bit).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteWord(Handle:bf, num);
|
native BfWriteWord(Handle:bf, num);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a normal integer to a writable bitbuffer (bf_write).
|
* Writes a normal integer to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param num Integer to write (value will be written as 32bit).
|
* @param num Integer to write (value will be written as 32bit).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteNum(Handle:bf, num);
|
native BfWriteNum(Handle:bf, num);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a floating point number to a writable bitbuffer (bf_write).
|
* Writes a floating point number to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param num Number to write.
|
* @param num Number to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteFloat(Handle:bf, Float:num);
|
native BfWriteFloat(Handle:bf, Float:num);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a string to a writable bitbuffer (bf_write).
|
* Writes a string to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param string Text string to write.
|
* @param string Text string to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteString(Handle:bf, const String:string[]);
|
native BfWriteString(Handle:bf, const String:string[]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes an entity to a writable bitbuffer (bf_write).
|
* Writes an entity to a writable bitbuffer (bf_write).
|
||||||
* @note This is a wrapper around BfWriteShort().
|
* @note This is a wrapper around BfWriteShort().
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param ent Entity index to write.
|
* @param ent Entity index to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle, or invalid entity.
|
* @error Invalid or incorrect Handle, or invalid entity.
|
||||||
*/
|
*/
|
||||||
native BfWriteEntity(Handle:bf, ent);
|
native BfWriteEntity(Handle:bf, ent);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a bit angle to a writable bitbuffer (bf_write).
|
* Writes a bit angle to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param angle Angle to write.
|
* @param angle Angle to write.
|
||||||
* @param numBits Optional number of bits to use.
|
* @param numBits Optional number of bits to use.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteAngle(Handle:bf, Float:angle, numBits=8);
|
native BfWriteAngle(Handle:bf, Float:angle, numBits=8);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a coordinate to a writable bitbuffer (bf_write).
|
* Writes a coordinate to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param coord Coordinate to write.
|
* @param coord Coordinate to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteCoord(Handle:bf, Float:coord);
|
native BfWriteCoord(Handle:bf, Float:coord);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a 3D vector of coordinates to a writable bitbuffer (bf_write).
|
* Writes a 3D vector of coordinates to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param coord Coordinate array to write.
|
* @param coord Coordinate array to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteVecCoord(Handle:bf, Float:coord[3]);
|
native BfWriteVecCoord(Handle:bf, Float:coord[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a 3D normal vector to a writable bitbuffer (bf_write).
|
* Writes a 3D normal vector to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param vec Vector to write.
|
* @param vec Vector to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteVecNormal(Handle:bf, Float:vec[3]);
|
native BfWriteVecNormal(Handle:bf, Float:vec[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Writes a 3D angle vector to a writable bitbuffer (bf_write).
|
* Writes a 3D angle vector to a writable bitbuffer (bf_write).
|
||||||
*
|
*
|
||||||
* @param bf bf_write handle to write to.
|
* @param bf bf_write handle to write to.
|
||||||
* @param angles Angle vector to write.
|
* @param angles Angle vector to write.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfWriteAngles(Handle:bf, Float:angles[3]);
|
native BfWriteAngles(Handle:bf, Float:angles[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a single bit from a readable bitbuffer (bf_read).
|
* Reads a single bit from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Bit value read.
|
* @return Bit value read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native bool:BfReadBool(Handle:bf);
|
native bool:BfReadBool(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a byte from a readable bitbuffer (bf_read).
|
* Reads a byte from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Byte value read (read as 8bit).
|
* @return Byte value read (read as 8bit).
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadByte(Handle:bf);
|
native BfReadByte(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a character from a readable bitbuffer (bf_read).
|
* Reads a character from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Character value read.
|
* @return Character value read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadChar(Handle:bf);
|
native BfReadChar(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a 16bit integer from a readable bitbuffer (bf_read).
|
* Reads a 16bit integer from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Integer value read (read as 16bit).
|
* @return Integer value read (read as 16bit).
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadShort(Handle:bf);
|
native BfReadShort(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a 16bit unsigned integer from a readable bitbuffer (bf_read).
|
* Reads a 16bit unsigned integer from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Integer value read (read as 16bit).
|
* @return Integer value read (read as 16bit).
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadWord(Handle:bf);
|
native BfReadWord(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a normal integer to a readable bitbuffer (bf_read).
|
* Reads a normal integer to a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Integer value read (read as 32bit).
|
* @return Integer value read (read as 32bit).
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadNum(Handle:bf);
|
native BfReadNum(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a floating point number from a readable bitbuffer (bf_read).
|
* Reads a floating point number from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Floating point value read.
|
* @return Floating point value read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native Float:BfReadFloat(Handle:bf);
|
native Float:BfReadFloat(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a string from a readable bitbuffer (bf_read).
|
* Reads a string from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @param buffer Destination string buffer.
|
* @param buffer Destination string buffer.
|
||||||
* @param maxlength Maximum length of output string buffer.
|
* @param maxlength Maximum length of output string buffer.
|
||||||
* @param line If true the buffer will be copied until it reaches a '\n' or a null terminator.
|
* @param line If true the buffer will be copied until it reaches a '\n' or a null terminator.
|
||||||
* @return Number of bytes written to the buffer. If the bitbuffer stream overflowed,
|
* @return Number of bytes written to the buffer. If the bitbuffer stream overflowed,
|
||||||
* that is, had no terminator before the end of the stream, then a negative
|
* that is, had no terminator before the end of the stream, then a negative
|
||||||
* number will be returned equal to the number of characters written to the
|
* number will be returned equal to the number of characters written to the
|
||||||
* buffer minus 1. The buffer will be null terminated regardless of the
|
* buffer minus 1. The buffer will be null terminated regardless of the
|
||||||
* return value.
|
* return value.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadString(Handle:bf, String:buffer[], maxlength, bool:line=false);
|
native BfReadString(Handle:bf, String:buffer[], maxlength, bool:line=false);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads an entity from a readable bitbuffer (bf_read).
|
* Reads an entity from a readable bitbuffer (bf_read).
|
||||||
* @note This is a wrapper around BfReadShort().
|
* @note This is a wrapper around BfReadShort().
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Entity index read.
|
* @return Entity index read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadEntity(Handle:bf);
|
native BfReadEntity(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a bit angle from a readable bitbuffer (bf_read).
|
* Reads a bit angle from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @param numBits Optional number of bits to use.
|
* @param numBits Optional number of bits to use.
|
||||||
* @return Angle read.
|
* @return Angle read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native Float:BfReadAngle(Handle:bf, numBits=8);
|
native Float:BfReadAngle(Handle:bf, numBits=8);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a coordinate from a readable bitbuffer (bf_read).
|
* Reads a coordinate from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Coordinate read.
|
* @return Coordinate read.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native Float:BfReadCoord(Handle:bf);
|
native Float:BfReadCoord(Handle:bf);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a 3D vector of coordinates from a readable bitbuffer (bf_read).
|
* Reads a 3D vector of coordinates from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @param coord Destination coordinate array.
|
* @param coord Destination coordinate array.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadVecCoord(Handle:bf, Float:coord[3]);
|
native BfReadVecCoord(Handle:bf, Float:coord[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a 3D normal vector from a readable bitbuffer (bf_read).
|
* Reads a 3D normal vector from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @param vec Destination vector array.
|
* @param vec Destination vector array.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadVecNormal(Handle:bf, Float:vec[3]);
|
native BfReadVecNormal(Handle:bf, Float:vec[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Reads a 3D angle vector from a readable bitbuffer (bf_read).
|
* Reads a 3D angle vector from a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @param angles Destination angle vector.
|
* @param angles Destination angle vector.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfReadAngles(Handle:bf, Float:angles[3]);
|
native BfReadAngles(Handle:bf, Float:angles[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the number of bytes left in a readable bitbuffer (bf_read).
|
* Returns the number of bytes left in a readable bitbuffer (bf_read).
|
||||||
*
|
*
|
||||||
* @param bf bf_read handle to read from.
|
* @param bf bf_read handle to read from.
|
||||||
* @return Number of bytes left unread.
|
* @return Number of bytes left unread.
|
||||||
* @error Invalid or incorrect Handle.
|
* @error Invalid or incorrect Handle.
|
||||||
*/
|
*/
|
||||||
native BfGetNumBytesLeft(Handle:bf);
|
native BfGetNumBytesLeft(Handle:bf);
|
||||||
|
@ -1,272 +1,272 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This file is part of the SourceMod/SourcePawn SDK.
|
* This file is part of the SourceMod/SourcePawn SDK.
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id$
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if defined _sdktools_trace_included
|
#if defined _sdktools_trace_included
|
||||||
#endinput
|
#endinput
|
||||||
#endif
|
#endif
|
||||||
#define _sdktools_trace_included
|
#define _sdktools_trace_included
|
||||||
|
|
||||||
#define CONTENTS_EMPTY 0 /**< No contents. */
|
#define CONTENTS_EMPTY 0 /**< No contents. */
|
||||||
#define CONTENTS_SOLID 0x1 /**< an eye is never valid in a solid . */
|
#define CONTENTS_SOLID 0x1 /**< an eye is never valid in a solid . */
|
||||||
#define CONTENTS_WINDOW 0x2 /**< translucent, but not watery (glass). */
|
#define CONTENTS_WINDOW 0x2 /**< translucent, but not watery (glass). */
|
||||||
#define CONTENTS_AUX 0x4
|
#define CONTENTS_AUX 0x4
|
||||||
#define CONTENTS_GRATE 0x8 /**< alpha-tested "grate" textures. Bullets/sight pass through, but solids don't. */
|
#define CONTENTS_GRATE 0x8 /**< alpha-tested "grate" textures. Bullets/sight pass through, but solids don't. */
|
||||||
#define CONTENTS_SLIME 0x10
|
#define CONTENTS_SLIME 0x10
|
||||||
#define CONTENTS_WATER 0x20
|
#define CONTENTS_WATER 0x20
|
||||||
#define CONTENTS_MIST 0x40
|
#define CONTENTS_MIST 0x40
|
||||||
#define CONTENTS_OPAQUE 0x80 /**< things that cannot be seen through (may be non-solid though). */
|
#define CONTENTS_OPAQUE 0x80 /**< things that cannot be seen through (may be non-solid though). */
|
||||||
#define LAST_VISIBLE_CONTENTS 0x80
|
#define LAST_VISIBLE_CONTENTS 0x80
|
||||||
#define ALL_VISIBLE_CONTENTS (LAST_VISIBLE_CONTENTS | (LAST_VISIBLE_CONTENTS-1))
|
#define ALL_VISIBLE_CONTENTS (LAST_VISIBLE_CONTENTS | (LAST_VISIBLE_CONTENTS-1))
|
||||||
#define CONTENTS_TESTFOGVOLUME 0x100
|
#define CONTENTS_TESTFOGVOLUME 0x100
|
||||||
#define CONTENTS_UNUSED5 0x200
|
#define CONTENTS_UNUSED5 0x200
|
||||||
#define CONTENTS_UNUSED6 0x4000
|
#define CONTENTS_UNUSED6 0x4000
|
||||||
#define CONTENTS_TEAM1 0x800 /**< per team contents used to differentiate collisions. */
|
#define CONTENTS_TEAM1 0x800 /**< per team contents used to differentiate collisions. */
|
||||||
#define CONTENTS_TEAM2 0x1000 /**< between players and objects on different teams. */
|
#define CONTENTS_TEAM2 0x1000 /**< between players and objects on different teams. */
|
||||||
#define CONTENTS_IGNORE_NODRAW_OPAQUE 0x2000 /**< ignore CONTENTS_OPAQUE on surfaces that have SURF_NODRAW. */
|
#define CONTENTS_IGNORE_NODRAW_OPAQUE 0x2000 /**< ignore CONTENTS_OPAQUE on surfaces that have SURF_NODRAW. */
|
||||||
#define CONTENTS_MOVEABLE 0x4000 /**< hits entities which are MOVETYPE_PUSH (doors, plats, etc) */
|
#define CONTENTS_MOVEABLE 0x4000 /**< hits entities which are MOVETYPE_PUSH (doors, plats, etc) */
|
||||||
#define CONTENTS_AREAPORTAL 0x8000 /**< remaining contents are non-visible, and don't eat brushes. */
|
#define CONTENTS_AREAPORTAL 0x8000 /**< remaining contents are non-visible, and don't eat brushes. */
|
||||||
#define CONTENTS_PLAYERCLIP 0x10000
|
#define CONTENTS_PLAYERCLIP 0x10000
|
||||||
#define CONTENTS_MONSTERCLIP 0x20000
|
#define CONTENTS_MONSTERCLIP 0x20000
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @section currents can be added to any other contents, and may be mixed
|
* @section currents can be added to any other contents, and may be mixed
|
||||||
*/
|
*/
|
||||||
#define CONTENTS_CURRENT_0 0x40000
|
#define CONTENTS_CURRENT_0 0x40000
|
||||||
#define CONTENTS_CURRENT_90 0x80000
|
#define CONTENTS_CURRENT_90 0x80000
|
||||||
#define CONTENTS_CURRENT_180 0x100000
|
#define CONTENTS_CURRENT_180 0x100000
|
||||||
#define CONTENTS_CURRENT_270 0x200000
|
#define CONTENTS_CURRENT_270 0x200000
|
||||||
#define CONTENTS_CURRENT_UP 0x400000
|
#define CONTENTS_CURRENT_UP 0x400000
|
||||||
#define CONTENTS_CURRENT_DOWN 0x800000
|
#define CONTENTS_CURRENT_DOWN 0x800000
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @endsection
|
* @endsection
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#define CONTENTS_ORIGIN 0x1000000 /**< removed before bsping an entity. */
|
#define CONTENTS_ORIGIN 0x1000000 /**< removed before bsping an entity. */
|
||||||
#define CONTENTS_MONSTER 0x2000000 /**< should never be on a brush, only in game. */
|
#define CONTENTS_MONSTER 0x2000000 /**< should never be on a brush, only in game. */
|
||||||
#define CONTENTS_DEBRIS 0x4000000
|
#define CONTENTS_DEBRIS 0x4000000
|
||||||
#define CONTENTS_DETAIL 0x8000000 /**< brushes to be added after vis leafs. */
|
#define CONTENTS_DETAIL 0x8000000 /**< brushes to be added after vis leafs. */
|
||||||
#define CONTENTS_TRANSLUCENT 0x10000000 /**< auto set if any surface has trans. */
|
#define CONTENTS_TRANSLUCENT 0x10000000 /**< auto set if any surface has trans. */
|
||||||
#define CONTENTS_LADDER 0x20000000
|
#define CONTENTS_LADDER 0x20000000
|
||||||
#define CONTENTS_HITBOX 0x40000000 /**< use accurate hitboxes on trace. */
|
#define CONTENTS_HITBOX 0x40000000 /**< use accurate hitboxes on trace. */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @section Trace masks.
|
* @section Trace masks.
|
||||||
*/
|
*/
|
||||||
#define MASK_ALL (0xFFFFFFFF)
|
#define MASK_ALL (0xFFFFFFFF)
|
||||||
#define MASK_SOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< everything that is normally solid */
|
#define MASK_SOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< everything that is normally solid */
|
||||||
#define MASK_PLAYERSOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_PLAYERCLIP|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< everything that blocks player movement */
|
#define MASK_PLAYERSOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_PLAYERCLIP|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< everything that blocks player movement */
|
||||||
#define MASK_NPCSOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTERCLIP|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< blocks npc movement */
|
#define MASK_NPCSOLID (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTERCLIP|CONTENTS_WINDOW|CONTENTS_MONSTER|CONTENTS_GRATE) /**< blocks npc movement */
|
||||||
#define MASK_WATER (CONTENTS_WATER|CONTENTS_MOVEABLE|CONTENTS_SLIME) /**< water physics in these contents */
|
#define MASK_WATER (CONTENTS_WATER|CONTENTS_MOVEABLE|CONTENTS_SLIME) /**< water physics in these contents */
|
||||||
#define MASK_OPAQUE (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_OPAQUE) /**< everything that blocks line of sight for AI, lighting, etc */
|
#define MASK_OPAQUE (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_OPAQUE) /**< everything that blocks line of sight for AI, lighting, etc */
|
||||||
#define MASK_OPAQUE_AND_NPCS (MASK_OPAQUE|CONTENTS_MONSTER) /**< everything that blocks line of sight for AI, lighting, etc, but with monsters added. */
|
#define MASK_OPAQUE_AND_NPCS (MASK_OPAQUE|CONTENTS_MONSTER) /**< everything that blocks line of sight for AI, lighting, etc, but with monsters added. */
|
||||||
#define MASK_VISIBLE (MASK_OPAQUE|CONTENTS_IGNORE_NODRAW_OPAQUE) /**< everything that blocks line of sight for players */
|
#define MASK_VISIBLE (MASK_OPAQUE|CONTENTS_IGNORE_NODRAW_OPAQUE) /**< everything that blocks line of sight for players */
|
||||||
#define MASK_VISIBLE_AND_NPCS (MASK_OPAQUE_AND_NPCS|CONTENTS_IGNORE_NODRAW_OPAQUE) /**< everything that blocks line of sight for players, but with monsters added. */
|
#define MASK_VISIBLE_AND_NPCS (MASK_OPAQUE_AND_NPCS|CONTENTS_IGNORE_NODRAW_OPAQUE) /**< everything that blocks line of sight for players, but with monsters added. */
|
||||||
#define MASK_SHOT (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTER|CONTENTS_WINDOW|CONTENTS_DEBRIS|CONTENTS_HITBOX) /**< bullets see these as solid */
|
#define MASK_SHOT (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTER|CONTENTS_WINDOW|CONTENTS_DEBRIS|CONTENTS_HITBOX) /**< bullets see these as solid */
|
||||||
#define MASK_SHOT_HULL (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTER|CONTENTS_WINDOW|CONTENTS_DEBRIS|CONTENTS_GRATE) /**< non-raycasted weapons see this as solid (includes grates) */
|
#define MASK_SHOT_HULL (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_MONSTER|CONTENTS_WINDOW|CONTENTS_DEBRIS|CONTENTS_GRATE) /**< non-raycasted weapons see this as solid (includes grates) */
|
||||||
#define MASK_SHOT_PORTAL (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW) /**< hits solids (not grates) and passes through everything else */
|
#define MASK_SHOT_PORTAL (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW) /**< hits solids (not grates) and passes through everything else */
|
||||||
#define MASK_SOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_GRATE) /**< everything normally solid, except monsters (world+brush only) */
|
#define MASK_SOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_GRATE) /**< everything normally solid, except monsters (world+brush only) */
|
||||||
#define MASK_PLAYERSOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_PLAYERCLIP|CONTENTS_GRATE) /**< everything normally solid for player movement, except monsters (world+brush only) */
|
#define MASK_PLAYERSOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_PLAYERCLIP|CONTENTS_GRATE) /**< everything normally solid for player movement, except monsters (world+brush only) */
|
||||||
#define MASK_NPCSOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_MONSTERCLIP|CONTENTS_GRATE) /**< everything normally solid for npc movement, except monsters (world+brush only) */
|
#define MASK_NPCSOLID_BRUSHONLY (CONTENTS_SOLID|CONTENTS_MOVEABLE|CONTENTS_WINDOW|CONTENTS_MONSTERCLIP|CONTENTS_GRATE) /**< everything normally solid for npc movement, except monsters (world+brush only) */
|
||||||
#define MASK_NPCWORLDSTATIC (CONTENTS_SOLID|CONTENTS_WINDOW|CONTENTS_MONSTERCLIP|CONTENTS_GRATE) /**< just the world, used for route rebuilding */
|
#define MASK_NPCWORLDSTATIC (CONTENTS_SOLID|CONTENTS_WINDOW|CONTENTS_MONSTERCLIP|CONTENTS_GRATE) /**< just the world, used for route rebuilding */
|
||||||
#define MASK_SPLITAREAPORTAL (CONTENTS_WATER|CONTENTS_SLIME) /**< These are things that can split areaportals */
|
#define MASK_SPLITAREAPORTAL (CONTENTS_WATER|CONTENTS_SLIME) /**< These are things that can split areaportals */
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @endsection
|
* @endsection
|
||||||
*/
|
*/
|
||||||
|
|
||||||
enum RayType
|
enum RayType
|
||||||
{
|
{
|
||||||
RayType_EndPoint, /**< The trace ray will go from the start position to the end position. */
|
RayType_EndPoint, /**< The trace ray will go from the start position to the end position. */
|
||||||
RayType_Infinite /**< The trace ray will go from the start position to infinity using a direction vector. */
|
RayType_Infinite /**< The trace ray will go from the start position to infinity using a direction vector. */
|
||||||
};
|
};
|
||||||
|
|
||||||
funcenum TraceEntityFilter
|
funcenum TraceEntityFilter
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* Called on entity filtering.
|
* Called on entity filtering.
|
||||||
*
|
*
|
||||||
* @param entity Entity index.
|
* @param entity Entity index.
|
||||||
* @param contentsMask Contents Mask.
|
* @param contentsMask Contents Mask.
|
||||||
* @return True to allow the current entity to be hit, otherwise false.
|
* @return True to allow the current entity to be hit, otherwise false.
|
||||||
*/
|
*/
|
||||||
bool:public(entity, contentsMask),
|
bool:public(entity, contentsMask),
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called on entity filtering.
|
* Called on entity filtering.
|
||||||
*
|
*
|
||||||
* @param entity Entity index.
|
* @param entity Entity index.
|
||||||
* @param contentsMask Contents Mask.
|
* @param contentsMask Contents Mask.
|
||||||
* @param data Data value, if used.
|
* @param data Data value, if used.
|
||||||
* @return True to allow the current entity to be hit, otherwise false.
|
* @return True to allow the current entity to be hit, otherwise false.
|
||||||
*/
|
*/
|
||||||
bool:public(entity, contentsMask, any:data),
|
bool:public(entity, contentsMask, any:data),
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the contents mask and the entity index at the given position.
|
* Get the contents mask and the entity index at the given position.
|
||||||
*
|
*
|
||||||
* @param pos World position to test.
|
* @param pos World position to test.
|
||||||
* @param entindex Entity index found at the given position (by reference).
|
* @param entindex Entity index found at the given position (by reference).
|
||||||
* @return Contents mask.
|
* @return Contents mask.
|
||||||
*/
|
*/
|
||||||
native TR_GetPointContents(const Float:pos[3], &entindex=-1);
|
native TR_GetPointContents(const Float:pos[3], &entindex=-1);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Get the point contents testing only the given entity index.
|
* Get the point contents testing only the given entity index.
|
||||||
*
|
*
|
||||||
* @param entindex Entity index to test.
|
* @param entindex Entity index to test.
|
||||||
* @param pos World position.
|
* @param pos World position.
|
||||||
* @return Contents mask.
|
* @return Contents mask.
|
||||||
*/
|
*/
|
||||||
native TR_GetPointContentsEnt(entindex, const Float:pos[3]);
|
native TR_GetPointContentsEnt(entindex, const Float:pos[3]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Starts up a new trace ray using a global trace result.
|
* Starts up a new trace ray using a global trace result.
|
||||||
*
|
*
|
||||||
* @param pos Starting position of the ray.
|
* @param pos Starting position of the ray.
|
||||||
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
||||||
* @param flags Trace flags.
|
* @param flags Trace flags.
|
||||||
* @param rtype Method to calculate the ray direction.
|
* @param rtype Method to calculate the ray direction.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
*/
|
*/
|
||||||
native TR_TraceRay(const Float:pos[3], const Float:vec[3], flags, RayType:rtype);
|
native TR_TraceRay(const Float:pos[3], const Float:vec[3], flags, RayType:rtype);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Starts up a new trace ray using a global trace result and a customized trace ray filter.
|
* Starts up a new trace ray using a global trace result and a customized trace ray filter.
|
||||||
*
|
*
|
||||||
* Calling TR_TraceRayFilter or TR_TraceRayFilterEx from inside a filter function is
|
* Calling TR_TraceRayFilter or TR_TraceRayFilterEx from inside a filter function is
|
||||||
* currently not allowed and may not work.
|
* currently not allowed and may not work.
|
||||||
*
|
*
|
||||||
* @param pos Starting position of the ray.
|
* @param pos Starting position of the ray.
|
||||||
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
||||||
* @param flags Trace flags.
|
* @param flags Trace flags.
|
||||||
* @param rtype Method to calculate the ray direction.
|
* @param rtype Method to calculate the ray direction.
|
||||||
* @param filter Function to use as a filter.
|
* @param filter Function to use as a filter.
|
||||||
* @param data Arbitrary data value to pass through to the filter function.
|
* @param data Arbitrary data value to pass through to the filter function.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
*/
|
*/
|
||||||
native TR_TraceRayFilter(const Float:pos[3],
|
native TR_TraceRayFilter(const Float:pos[3],
|
||||||
const Float:vec[3],
|
const Float:vec[3],
|
||||||
flags,
|
flags,
|
||||||
RayType:rtype,
|
RayType:rtype,
|
||||||
TraceEntityFilter:filter,
|
TraceEntityFilter:filter,
|
||||||
any:data=0);
|
any:data=0);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Starts up a new trace ray using a new trace result.
|
* Starts up a new trace ray using a new trace result.
|
||||||
*
|
*
|
||||||
* @param pos Starting position of the ray.
|
* @param pos Starting position of the ray.
|
||||||
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
||||||
* @param flags Trace flags.
|
* @param flags Trace flags.
|
||||||
* @param rtype Method to calculate the ray direction.
|
* @param rtype Method to calculate the ray direction.
|
||||||
* @return Ray trace handle, which must be closed via CloseHandle().
|
* @return Ray trace handle, which must be closed via CloseHandle().
|
||||||
*/
|
*/
|
||||||
native Handle:TR_TraceRayEx(const Float:pos[3], const Float:vec[3], flags, RayType:rtype);
|
native Handle:TR_TraceRayEx(const Float:pos[3], const Float:vec[3], flags, RayType:rtype);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Starts up a new trace ray using a new trace result and a customized trace ray filter.
|
* Starts up a new trace ray using a new trace result and a customized trace ray filter.
|
||||||
*
|
*
|
||||||
* Calling TR_TraceRayFilter or TR_TraceRayFilterEx from inside a filter function is
|
* Calling TR_TraceRayFilter or TR_TraceRayFilterEx from inside a filter function is
|
||||||
* currently not allowed and may not work.
|
* currently not allowed and may not work.
|
||||||
*
|
*
|
||||||
* @param pos Starting position of the ray.
|
* @param pos Starting position of the ray.
|
||||||
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
* @param vec Depending on RayType, it will be used as the ending point, or the direction angle.
|
||||||
* @param flags Trace flags.
|
* @param flags Trace flags.
|
||||||
* @param rtype Method to calculate the ray direction.
|
* @param rtype Method to calculate the ray direction.
|
||||||
* @param filter Function to use as a filter.
|
* @param filter Function to use as a filter.
|
||||||
* @param data Arbitrary data value to pass through to the filter function.
|
* @param data Arbitrary data value to pass through to the filter function.
|
||||||
* @return Ray trace handle, which must be closed via CloseHandle().
|
* @return Ray trace handle, which must be closed via CloseHandle().
|
||||||
*/
|
*/
|
||||||
native Handle:TR_TraceRayFilterEx(const Float:pos[3],
|
native Handle:TR_TraceRayFilterEx(const Float:pos[3],
|
||||||
const Float:vec[3],
|
const Float:vec[3],
|
||||||
flags,
|
flags,
|
||||||
RayType:rtype,
|
RayType:rtype,
|
||||||
TraceEntityFilter:filter,
|
TraceEntityFilter:filter,
|
||||||
any:data=0);
|
any:data=0);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the time fraction from a trace result (1.0 means no collision).
|
* Returns the time fraction from a trace result (1.0 means no collision).
|
||||||
*
|
*
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @return Time fraction value of the trace.
|
* @return Time fraction value of the trace.
|
||||||
* @error Invalid Handle.
|
* @error Invalid Handle.
|
||||||
*/
|
*/
|
||||||
native Float:TR_GetFraction(Handle:hndl=INVALID_HANDLE);
|
native Float:TR_GetFraction(Handle:hndl=INVALID_HANDLE);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the collision position of a trace result.
|
* Returns the collision position of a trace result.
|
||||||
*
|
*
|
||||||
* @param pos Vector buffer to store data in.
|
* @param pos Vector buffer to store data in.
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid Handle.
|
* @error Invalid Handle.
|
||||||
*/
|
*/
|
||||||
native TR_GetEndPosition(Float:pos[3], Handle:hndl=INVALID_HANDLE);
|
native TR_GetEndPosition(Float:pos[3], Handle:hndl=INVALID_HANDLE);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns the entity index that collided with the trace.
|
* Returns the entity index that collided with the trace.
|
||||||
*
|
*
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @return Entity index or -1 for no collision.
|
* @return Entity index or -1 for no collision.
|
||||||
* @error Invalid Handle.
|
* @error Invalid Handle.
|
||||||
*/
|
*/
|
||||||
native TR_GetEntityIndex(Handle:hndl=INVALID_HANDLE);
|
native TR_GetEntityIndex(Handle:hndl=INVALID_HANDLE);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns if there was any kind of collision along the trace ray.
|
* Returns if there was any kind of collision along the trace ray.
|
||||||
*
|
*
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @return True if any collision found, otherwise false.
|
* @return True if any collision found, otherwise false.
|
||||||
* @error Invalid Handle.
|
* @error Invalid Handle.
|
||||||
*/
|
*/
|
||||||
native bool:TR_DidHit(Handle:hndl=INVALID_HANDLE);
|
native bool:TR_DidHit(Handle:hndl=INVALID_HANDLE);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Returns in which body hit group the trace collided if any.
|
* Returns in which body hit group the trace collided if any.
|
||||||
*
|
*
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @return Body hit group.
|
* @return Body hit group.
|
||||||
* @error Invalid Handle.
|
* @error Invalid Handle.
|
||||||
*/
|
*/
|
||||||
native TR_GetHitGroup(Handle:hndl=INVALID_HANDLE);
|
native TR_GetHitGroup(Handle:hndl=INVALID_HANDLE);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Find the normal vector to the collison plane of a trace.
|
* Find the normal vector to the collison plane of a trace.
|
||||||
*
|
*
|
||||||
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
* @param hndl A trace Handle, or INVALID_HANDLE to use a global trace result.
|
||||||
* @param normal Vector buffer to store the vector normal to the collision plane
|
* @param normal Vector buffer to store the vector normal to the collision plane
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid Handle
|
* @error Invalid Handle
|
||||||
*/
|
*/
|
||||||
native TR_GetPlaneNormal(Handle:hndl, Float:normal[3]);
|
native TR_GetPlaneNormal(Handle:hndl, Float:normal[3]);
|
||||||
|
|
||||||
|
@ -1,290 +1,290 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This file is part of the SourceMod/SourcePawn SDK.
|
* This file is part of the SourceMod/SourcePawn SDK.
|
||||||
*
|
*
|
||||||
* This program is free software; you can redistribute it and/or modify it under
|
* This program is free software; you can redistribute it and/or modify it under
|
||||||
* the terms of the GNU General Public License, version 3.0, as published by the
|
* the terms of the GNU General Public License, version 3.0, as published by the
|
||||||
* Free Software Foundation.
|
* Free Software Foundation.
|
||||||
*
|
*
|
||||||
* This program is distributed in the hope that it will be useful, but WITHOUT
|
* This program is distributed in the hope that it will be useful, but WITHOUT
|
||||||
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
* ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS
|
||||||
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
* FOR A PARTICULAR PURPOSE. See the GNU General Public License for more
|
||||||
* details.
|
* details.
|
||||||
*
|
*
|
||||||
* You should have received a copy of the GNU General Public License along with
|
* You should have received a copy of the GNU General Public License along with
|
||||||
* this program. If not, see <http://www.gnu.org/licenses/>.
|
* this program. If not, see <http://www.gnu.org/licenses/>.
|
||||||
*
|
*
|
||||||
* As a special exception, AlliedModders LLC gives you permission to link the
|
* As a special exception, AlliedModders LLC gives you permission to link the
|
||||||
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
* code of this program (as well as its derivative works) to "Half-Life 2," the
|
||||||
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
* "Source Engine," the "SourcePawn JIT," and any Game MODs that run on software
|
||||||
* by the Valve Corporation. You must obey the GNU General Public License in
|
* by the Valve Corporation. You must obey the GNU General Public License in
|
||||||
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
* all respects for all other code used. Additionally, AlliedModders LLC grants
|
||||||
* this exception to all derivative works. AlliedModders LLC defines further
|
* this exception to all derivative works. AlliedModders LLC defines further
|
||||||
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
* exceptions, found in LICENSE.txt (as of this writing, version JULY-31-2007),
|
||||||
* or <http://www.sourcemod.net/license.php>.
|
* or <http://www.sourcemod.net/license.php>.
|
||||||
*
|
*
|
||||||
* Version: $Id$
|
* Version: $Id$
|
||||||
*/
|
*/
|
||||||
|
|
||||||
#if defined _topmenus_included
|
#if defined _topmenus_included
|
||||||
#endinput
|
#endinput
|
||||||
#endif
|
#endif
|
||||||
#define _topmenus_included
|
#define _topmenus_included
|
||||||
|
|
||||||
#include <menus>
|
#include <menus>
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Actions a top menu will take on an object.
|
* Actions a top menu will take on an object.
|
||||||
*/
|
*/
|
||||||
enum TopMenuAction
|
enum TopMenuAction
|
||||||
{
|
{
|
||||||
/**
|
/**
|
||||||
* An option is being drawn for a menu (or for sorting purposes).
|
* An option is being drawn for a menu (or for sorting purposes).
|
||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID, client index.
|
* INPUT : TopMenu Handle, object ID, client index.
|
||||||
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_DisplayOption = 0,
|
TopMenuAction_DisplayOption = 0,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* The title of a menu is being drawn for a given object.
|
* The title of a menu is being drawn for a given object.
|
||||||
*
|
*
|
||||||
* Note: The Object ID will be INVALID_TOPMENUOBJECT if drawing the
|
* Note: The Object ID will be INVALID_TOPMENUOBJECT if drawing the
|
||||||
* root title. Otherwise, the Object ID is a category.
|
* root title. Otherwise, the Object ID is a category.
|
||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID, client index.
|
* INPUT : TopMenu Handle, object ID, client index.
|
||||||
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
* OUTPUT: Buffer for rendering, maxlength of buffer.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_DisplayTitle = 1,
|
TopMenuAction_DisplayTitle = 1,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A menu option has been selected.
|
* A menu option has been selected.
|
||||||
*
|
*
|
||||||
* The Object ID will always be an item (not a category).
|
* The Object ID will always be an item (not a category).
|
||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID, client index.
|
* INPUT : TopMenu Handle, object ID, client index.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_SelectOption = 2,
|
TopMenuAction_SelectOption = 2,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* A menu option is being drawn and its flags can be overridden.
|
* A menu option is being drawn and its flags can be overridden.
|
||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID, client index.
|
* INPUT : TopMenu Handle, object ID, client index.
|
||||||
* OUTPUT: The first byte of the 'buffer' string should be set
|
* OUTPUT: The first byte of the 'buffer' string should be set
|
||||||
* to the desired flags. By default, it will contain
|
* to the desired flags. By default, it will contain
|
||||||
* ITEMDRAW_DEFAULT.
|
* ITEMDRAW_DEFAULT.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_DrawOption = 3,
|
TopMenuAction_DrawOption = 3,
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Called when an object is being removed from the menu.
|
* Called when an object is being removed from the menu.
|
||||||
* This can be used to clean up data stored in the info string.
|
* This can be used to clean up data stored in the info string.
|
||||||
*
|
*
|
||||||
* INPUT : TopMenu Handle, object ID.
|
* INPUT : TopMenu Handle, object ID.
|
||||||
*/
|
*/
|
||||||
TopMenuAction_RemoveObject = 4,
|
TopMenuAction_RemoveObject = 4,
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Top menu object types.
|
* Top menu object types.
|
||||||
*/
|
*/
|
||||||
enum TopMenuObjectType
|
enum TopMenuObjectType
|
||||||
{
|
{
|
||||||
TopMenuObject_Category = 0, /**< Category (sub-menu branching from root) */
|
TopMenuObject_Category = 0, /**< Category (sub-menu branching from root) */
|
||||||
TopMenuObject_Item = 1 /**< Item on a sub-menu */
|
TopMenuObject_Item = 1 /**< Item on a sub-menu */
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Top menu starting positions for display.
|
* Top menu starting positions for display.
|
||||||
*/
|
*/
|
||||||
enum TopMenuPosition
|
enum TopMenuPosition
|
||||||
{
|
{
|
||||||
TopMenuPosition_Start = 0, /**< Start/root of the menu */
|
TopMenuPosition_Start = 0, /**< Start/root of the menu */
|
||||||
TopMenuPosition_LastRoot = 1, /**< Last position in the root menu */
|
TopMenuPosition_LastRoot = 1, /**< Last position in the root menu */
|
||||||
TopMenuPosition_LastCategory = 3, /**< Last position in their last category */
|
TopMenuPosition_LastCategory = 3, /**< Last position in their last category */
|
||||||
};
|
};
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Top menu object tag for type checking.
|
* Top menu object tag for type checking.
|
||||||
*/
|
*/
|
||||||
enum TopMenuObject
|
enum TopMenuObject
|
||||||
{
|
{
|
||||||
INVALID_TOPMENUOBJECT = 0,
|
INVALID_TOPMENUOBJECT = 0,
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* TopMenu callback prototype.
|
* TopMenu callback prototype.
|
||||||
*
|
*
|
||||||
* @param topmenu Handle to the TopMenu.
|
* @param topmenu Handle to the TopMenu.
|
||||||
* @param action TopMenuAction being performed.
|
* @param action TopMenuAction being performed.
|
||||||
* @param object_id The object ID (if used).
|
* @param object_id The object ID (if used).
|
||||||
* @param param Extra parameter (if used).
|
* @param param Extra parameter (if used).
|
||||||
* @param buffer Output buffer (if used).
|
* @param buffer Output buffer (if used).
|
||||||
* @param maxlength Output buffer (if used).
|
* @param maxlength Output buffer (if used).
|
||||||
* @noreturn
|
* @noreturn
|
||||||
*/
|
*/
|
||||||
functag TopMenuHandler public(Handle:topmenu,
|
functag TopMenuHandler public(Handle:topmenu,
|
||||||
TopMenuAction:action,
|
TopMenuAction:action,
|
||||||
TopMenuObject:object_id,
|
TopMenuObject:object_id,
|
||||||
param,
|
param,
|
||||||
String:buffer[],
|
String:buffer[],
|
||||||
maxlength);
|
maxlength);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Creates a TopMenu.
|
* Creates a TopMenu.
|
||||||
*
|
*
|
||||||
* @param handler Handler to use for drawing the root title.
|
* @param handler Handler to use for drawing the root title.
|
||||||
* @return A new TopMenu Handle, or INVALID_HANDLE on failure.
|
* @return A new TopMenu Handle, or INVALID_HANDLE on failure.
|
||||||
*/
|
*/
|
||||||
native Handle:CreateTopMenu(TopMenuHandler:handler);
|
native Handle:CreateTopMenu(TopMenuHandler:handler);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Re-sorts the items in a TopMenu via a configuration file.
|
* Re-sorts the items in a TopMenu via a configuration file.
|
||||||
*
|
*
|
||||||
* The format of the configuration file should be a Valve Key-Values
|
* The format of the configuration file should be a Valve Key-Values
|
||||||
* formatted file that SourceMod can parse. There should be one root
|
* formatted file that SourceMod can parse. There should be one root
|
||||||
* section, and one sub-section for each category. Each sub-section's
|
* section, and one sub-section for each category. Each sub-section's
|
||||||
* name should match the category name.
|
* name should match the category name.
|
||||||
*
|
*
|
||||||
* Each sub-section may only contain key/value pairs in the form of:
|
* Each sub-section may only contain key/value pairs in the form of:
|
||||||
* key: "item"
|
* key: "item"
|
||||||
* value: Name of the item as passed to AddToTopMenu().
|
* value: Name of the item as passed to AddToTopMenu().
|
||||||
*
|
*
|
||||||
* The TopMenu will draw items in the order declared in the configuration
|
* The TopMenu will draw items in the order declared in the configuration
|
||||||
* file. If items do not appear in the configuration file, they are sorted
|
* file. If items do not appear in the configuration file, they are sorted
|
||||||
* per-player based on how the handler function renders for that player.
|
* per-player based on how the handler function renders for that player.
|
||||||
* These items appear after the configuration sorted items.
|
* These items appear after the configuration sorted items.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param file File path.
|
* @param file File path.
|
||||||
* @param error Error buffer.
|
* @param error Error buffer.
|
||||||
* @param maxlength Maximum size of the error buffer.
|
* @param maxlength Maximum size of the error buffer.
|
||||||
* Error buffer will be filled with a
|
* Error buffer will be filled with a
|
||||||
* zero-terminated string if false is
|
* zero-terminated string if false is
|
||||||
* returned.
|
* returned.
|
||||||
* @return True on success, false on failure.
|
* @return True on success, false on failure.
|
||||||
* @error Invalid TopMenu Handle.
|
* @error Invalid TopMenu Handle.
|
||||||
*/
|
*/
|
||||||
native bool:LoadTopMenuConfig(Handle:topmenu, const String:file[], String:error[], maxlength);
|
native bool:LoadTopMenuConfig(Handle:topmenu, const String:file[], String:error[], maxlength);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Adds an object to a TopMenu.
|
* Adds an object to a TopMenu.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param name Object name (MUST be unique).
|
* @param name Object name (MUST be unique).
|
||||||
* @param type Object type.
|
* @param type Object type.
|
||||||
* @param handler Handler for object.
|
* @param handler Handler for object.
|
||||||
* @param cmdname Command name (for access overrides).
|
* @param cmdname Command name (for access overrides).
|
||||||
* @param flags Default access flags.
|
* @param flags Default access flags.
|
||||||
* @param parent Parent object ID, or INVALID_TOPMENUOBJECT for none.
|
* @param parent Parent object ID, or INVALID_TOPMENUOBJECT for none.
|
||||||
* Items must have a category parent.
|
* Items must have a category parent.
|
||||||
* Categories must not have a parent.
|
* Categories must not have a parent.
|
||||||
* @param info_string Arbitrary storage (max 255 bytes).
|
* @param info_string Arbitrary storage (max 255 bytes).
|
||||||
* @return A new TopMenuObject ID, or INVALID_TOPMENUOBJECT on
|
* @return A new TopMenuObject ID, or INVALID_TOPMENUOBJECT on
|
||||||
* failure.
|
* failure.
|
||||||
* @error Invalid TopMenu Handle.
|
* @error Invalid TopMenu Handle.
|
||||||
*/
|
*/
|
||||||
native TopMenuObject:AddToTopMenu(Handle:topmenu,
|
native TopMenuObject:AddToTopMenu(Handle:topmenu,
|
||||||
const String:name[],
|
const String:name[],
|
||||||
TopMenuObjectType:type,
|
TopMenuObjectType:type,
|
||||||
TopMenuHandler:handler,
|
TopMenuHandler:handler,
|
||||||
TopMenuObject:parent,
|
TopMenuObject:parent,
|
||||||
const String:cmdname[]="",
|
const String:cmdname[]="",
|
||||||
flags=0,
|
flags=0,
|
||||||
const String:info_string[]="");
|
const String:info_string[]="");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieves the info string of a top menu item.
|
* Retrieves the info string of a top menu item.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param object TopMenuObject ID.
|
* @param object TopMenuObject ID.
|
||||||
* @param buffer Buffer to store info string.
|
* @param buffer Buffer to store info string.
|
||||||
* @param maxlength Maximum size of info string.
|
* @param maxlength Maximum size of info string.
|
||||||
* @return Number of bytes written, not including the
|
* @return Number of bytes written, not including the
|
||||||
* null terminator.
|
* null terminator.
|
||||||
* @error Invalid TopMenu Handle or TopMenuObject ID.
|
* @error Invalid TopMenu Handle or TopMenuObject ID.
|
||||||
*/
|
*/
|
||||||
native GetTopMenuInfoString(Handle:topmenu, TopMenuObject:parent, String:buffer[], maxlength);
|
native GetTopMenuInfoString(Handle:topmenu, TopMenuObject:parent, String:buffer[], maxlength);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Retrieves the name string of a top menu item.
|
* Retrieves the name string of a top menu item.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param object TopMenuObject ID.
|
* @param object TopMenuObject ID.
|
||||||
* @param buffer Buffer to store info string.
|
* @param buffer Buffer to store info string.
|
||||||
* @param maxlength Maximum size of info string.
|
* @param maxlength Maximum size of info string.
|
||||||
* @return Number of bytes written, not including the
|
* @return Number of bytes written, not including the
|
||||||
* null terminator.
|
* null terminator.
|
||||||
* @error Invalid TopMenu Handle or TopMenuObject ID.
|
* @error Invalid TopMenu Handle or TopMenuObject ID.
|
||||||
*/
|
*/
|
||||||
native GetTopMenuObjName(Handle:topmenu, TopMenuObject:object, String:buffer[], maxlength);
|
native GetTopMenuObjName(Handle:topmenu, TopMenuObject:object, String:buffer[], maxlength);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Removes an object from a TopMenu.
|
* Removes an object from a TopMenu.
|
||||||
*
|
*
|
||||||
* Plugins' objects are automatically removed all TopMenus when the given
|
* Plugins' objects are automatically removed all TopMenus when the given
|
||||||
* plugin unloads or pauses. In the case of unpausing, all items are restored.
|
* plugin unloads or pauses. In the case of unpausing, all items are restored.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param object TopMenuObject ID.
|
* @param object TopMenuObject ID.
|
||||||
* @noreturn
|
* @noreturn
|
||||||
* @error Invalid TopMenu Handle.
|
* @error Invalid TopMenu Handle.
|
||||||
*/
|
*/
|
||||||
native RemoveFromTopMenu(Handle:topmenu, TopMenuObject:object);
|
native RemoveFromTopMenu(Handle:topmenu, TopMenuObject:object);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Displays a TopMenu to a client.
|
* Displays a TopMenu to a client.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param client Client index.
|
* @param client Client index.
|
||||||
* @param position Position to display from.
|
* @param position Position to display from.
|
||||||
* @return True on success, false on failure.
|
* @return True on success, false on failure.
|
||||||
* @error Invalid TopMenu Handle or client not in game.
|
* @error Invalid TopMenu Handle or client not in game.
|
||||||
*/
|
*/
|
||||||
native bool:DisplayTopMenu(Handle:topmenu, client, TopMenuPosition:position);
|
native bool:DisplayTopMenu(Handle:topmenu, client, TopMenuPosition:position);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Finds a category's object ID in a TopMenu.
|
* Finds a category's object ID in a TopMenu.
|
||||||
*
|
*
|
||||||
* @param topmenu TopMenu Handle.
|
* @param topmenu TopMenu Handle.
|
||||||
* @param name Object's unique name.
|
* @param name Object's unique name.
|
||||||
* @return TopMenuObject ID on success, or
|
* @return TopMenuObject ID on success, or
|
||||||
* INVALID_TOPMENUOBJECT on failure.
|
* INVALID_TOPMENUOBJECT on failure.
|
||||||
* @error Invalid TopMenu Handle.
|
* @error Invalid TopMenu Handle.
|
||||||
*/
|
*/
|
||||||
native TopMenuObject:FindTopMenuCategory(Handle:topmenu, const String:name[]);
|
native TopMenuObject:FindTopMenuCategory(Handle:topmenu, const String:name[]);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Do not edit below this line!
|
* Do not edit below this line!
|
||||||
*/
|
*/
|
||||||
public Extension:__ext_topmenus =
|
public Extension:__ext_topmenus =
|
||||||
{
|
{
|
||||||
name = "TopMenus",
|
name = "TopMenus",
|
||||||
file = "topmenus.ext",
|
file = "topmenus.ext",
|
||||||
#if defined AUTOLOAD_EXTENSIONS
|
#if defined AUTOLOAD_EXTENSIONS
|
||||||
autoload = 1,
|
autoload = 1,
|
||||||
#else
|
#else
|
||||||
autoload = 0,
|
autoload = 0,
|
||||||
#endif
|
#endif
|
||||||
#if defined REQUIRE_EXTENSIONS
|
#if defined REQUIRE_EXTENSIONS
|
||||||
required = 1,
|
required = 1,
|
||||||
#else
|
#else
|
||||||
required = 0,
|
required = 0,
|
||||||
#endif
|
#endif
|
||||||
};
|
};
|
||||||
|
|
||||||
#if !defined REQUIRE_EXTENSIONS
|
#if !defined REQUIRE_EXTENSIONS
|
||||||
public __ext_topmenus_SetNTVOptional()
|
public __ext_topmenus_SetNTVOptional()
|
||||||
{
|
{
|
||||||
MarkNativeAsOptional("CreateTopMenu");
|
MarkNativeAsOptional("CreateTopMenu");
|
||||||
MarkNativeAsOptional("LoadTopMenuConfig");
|
MarkNativeAsOptional("LoadTopMenuConfig");
|
||||||
MarkNativeAsOptional("AddToTopMenu");
|
MarkNativeAsOptional("AddToTopMenu");
|
||||||
MarkNativeAsOptional("RemoveFromTopMenu");
|
MarkNativeAsOptional("RemoveFromTopMenu");
|
||||||
MarkNativeAsOptional("DisplayTopMenu");
|
MarkNativeAsOptional("DisplayTopMenu");
|
||||||
MarkNativeAsOptional("FindTopMenuCategory");
|
MarkNativeAsOptional("FindTopMenuCategory");
|
||||||
}
|
}
|
||||||
#endif
|
#endif
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This file is part of the SourceMod/SourcePawn SDK.
|
* This file is part of the SourceMod/SourcePawn SDK.
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/**
|
/**
|
||||||
* vim: set ts=4 :
|
* vim: set ts=4 :
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
* SourceMod (C)2004-2007 AlliedModders LLC. All rights reserved.
|
* SourceMod (C)2004-2008 AlliedModders LLC. All rights reserved.
|
||||||
* =============================================================================
|
* =============================================================================
|
||||||
*
|
*
|
||||||
* This file is part of the SourceMod/SourcePawn SDK.
|
* This file is part of the SourceMod/SourcePawn SDK.
|
||||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user