Compare commits
41
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
5abec70579 | ||
|
|
8800d5311c | ||
|
|
3705210879 | ||
|
|
5f4befcb6a | ||
|
|
314011f118 | ||
|
|
a9b7a5dc5c | ||
|
|
9b78c68b1b | ||
|
|
328109be1f | ||
|
|
aba0f29666 | ||
|
|
bdefb58e5f | ||
|
|
7ad3a57c47 | ||
|
|
5a2f3cf433 | ||
|
|
fffc27a348 | ||
|
|
cecb7cb6a2 | ||
|
|
f5cc5eb757 | ||
|
|
689406744b | ||
|
|
603da899b7 | ||
|
|
9b4d1f6972 | ||
|
|
d56b222637 | ||
|
|
dfefda81e1 | ||
|
|
0c463b1f86 | ||
|
|
bf345eea8c | ||
|
|
5328447b74 | ||
|
|
db6881b7e3 | ||
|
|
3e96b1617a | ||
|
|
7ef8b415bb | ||
|
|
9a5d6957b9 | ||
|
|
b5a2ec7a5e | ||
|
|
373136af4e | ||
|
|
8673c11341 | ||
|
|
8c082de148 | ||
|
|
e62d47a85e | ||
|
|
2d32c587ba | ||
|
|
31e29ee94c | ||
|
|
e95e453258 | ||
|
|
48b0f61551 | ||
|
|
ef88fc21a1 | ||
|
|
558c8c9745 | ||
|
|
2f60680cfb | ||
|
|
1ffcf7a664 | ||
|
|
c00b688ab7 |
@@ -4,3 +4,4 @@ e877885fac80be71822641f7a9122cebc9812521 sourcemod-1.1.1
|
||||
b3ffa8a4511c4eadaf533fc790aa6b14f7f0c6ea sourcemod-1.1.2
|
||||
3a73bbf60f34befa9b66be03fa5974b394bb3411 sourcemod-1.2.0
|
||||
a71318396392e3c6d0ff31e069a60fbde59e0cea sourcemod-1.3.0
|
||||
3f33d01fcc28b509bed30f7be07ed215cc000538 sourcemod-1.3.1
|
||||
|
||||
+5
-5
@@ -200,8 +200,8 @@ class SM:
|
||||
else:
|
||||
staticLibs = os.path.join(sdkPath, 'lib', 'linux')
|
||||
workFolder = os.path.join(AMBuild.outputFolder, job.workFolder)
|
||||
if sdk == 'l4d2':
|
||||
for i in ['tier1_i486.a', 'mathlib_i486.a', 'vstdlib_linux.so', 'tier0_linux.so']:
|
||||
if sdk == 'ep2v' or sdk == 'l4d2':
|
||||
for i in ['tier1_i486.a', 'mathlib_i486.a', 'libvstdlib.so', 'libtier0.so']:
|
||||
link = os.path.join(workFolder, i)
|
||||
target = os.path.join(staticLibs, i)
|
||||
try:
|
||||
@@ -268,9 +268,9 @@ class SM:
|
||||
if not noLink:
|
||||
if AMBuild.target['platform'] == 'linux':
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['-lm']
|
||||
if sdk == 'l4d2':
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['tier0_linux.so']
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['vstdlib_linux.so']
|
||||
if sdk == 'ep2v' or sdk == 'l4d2':
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['libtier0.so']
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['libvstdlib.so']
|
||||
else:
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['tier0_i486.so']
|
||||
compiler['POSTLINKFLAGS'][0:0] = ['vstdlib_i486.so']
|
||||
|
||||
@@ -2,6 +2,23 @@ SourceMod Changelog
|
||||
|
||||
----------------------------
|
||||
|
||||
SourceMod 1.3.2 [2010-05-02]
|
||||
|
||||
URL: http://wiki.alliedmods.net/SourceMod_1.3.2_Release_Notes
|
||||
|
||||
User Changes:
|
||||
|
||||
- Support for recent TF, DoD, and L4D2 updates (bug 4356, bug 4361, bug 4371, bug 4374, bug 4375).
|
||||
- Fixed rare crash when replicating cvars to clients (bug 4315).
|
||||
- Lots of extra game support for Insurgency, ZPS, CSProMod, PVKII, and FortressForever (thanks
|
||||
Nicholas "psychonic" hastings).
|
||||
|
||||
Developer Changes:
|
||||
|
||||
- Added TF functions for stunning, conditions, regeneration, and power play (bug 4166, bug 4331).
|
||||
|
||||
----------------------------
|
||||
|
||||
SourceMod 1.3.1 [2010-02-09]
|
||||
|
||||
URL: http://wiki.alliedmods.net/SourceMod_1.3.1_Release_Notes
|
||||
|
||||
@@ -80,21 +80,21 @@ sm_reserve_type 0
|
||||
sm_reserved_slots 0
|
||||
|
||||
// Specifies whether or not reserved slots will be hidden (subtracted from max
|
||||
// slot count). Valid values are 0 (visible) or 1 (hidden).
|
||||
// slot count). Valid values are 0 (Visible) or 1 (Hidden).
|
||||
// --
|
||||
// Requires: reservedslots.smx
|
||||
// Default: 0
|
||||
sm_hide_slots 0
|
||||
|
||||
// Specifies whether or not non-admins can send messages to admins using
|
||||
// say_team @<message>. Valid values are 0 (disabled) or 1 (enabled)
|
||||
// say_team @<message>. Valid values are 0 (Disabled) or 1 (Enabled)
|
||||
// --
|
||||
// Requires: basechat.smx
|
||||
// Default: 1
|
||||
sm_chat_mode 1
|
||||
|
||||
// Specifies whether or not "timeleft" will automaticly be triggered every
|
||||
// x seconds. Valid values are 0 (disabled) to 1800 seconds.
|
||||
// x seconds. Valid values are 0 (Disabled) to 1800 seconds.
|
||||
// --
|
||||
// Requires: basetriggers.smx
|
||||
// Default: 0
|
||||
@@ -107,3 +107,28 @@ sm_timeleft_interval 0
|
||||
// Requires: basetriggers.smx
|
||||
// Default: 1
|
||||
sm_trigger_show 1
|
||||
|
||||
// Specifies whether or not to display vote progress to clients in the
|
||||
// "hint" box (near the bottom of the screen in most games).
|
||||
// Valid values are 0 (Disabled) or 1 (Enabled).
|
||||
// --
|
||||
// Default: 0
|
||||
sm_vote_progress_hintbox 0
|
||||
|
||||
// Specifies whether or not to display vote progress to clients in the
|
||||
// chat area. Valid values are 0 (Disabled) or 1 (Enabled).
|
||||
// --
|
||||
// Default: 0
|
||||
sm_vote_progress_chat 0
|
||||
|
||||
// Specifies whether or not to display vote progress in the server console.
|
||||
// Valid values are 0 (Disabled) or 1 (Enabled).
|
||||
// --
|
||||
// Default: 0
|
||||
sm_vote_progress_console 0
|
||||
|
||||
// Specifies whether or not to display vote progress to clients in the
|
||||
// client console. Valid values are 0 (Disabled) or 1 (Enabled).
|
||||
// --
|
||||
// Default: 0
|
||||
sm_vote_progress_client_console 0
|
||||
|
||||
@@ -504,7 +504,7 @@ SMCResult CGameConfig::ReadSMC_LeavingSection(const SMCStates *states)
|
||||
void *handle = dlopen(info.dli_fname, RTLD_NOW);
|
||||
if (handle)
|
||||
{
|
||||
#if SOURCE_ENGINE == SE_LEFT4DEAD2
|
||||
#if (SOURCE_ENGINE == SE_ORANGEBOXVALVE) || (SOURCE_ENGINE == SE_LEFT4DEAD2)
|
||||
final_addr = g_MemUtils.ResolveSymbol(handle, &s_TempSig.sig[1]);
|
||||
#else
|
||||
final_addr = dlsym(handle, &s_TempSig.sig[1]);
|
||||
|
||||
+5
-5
@@ -100,7 +100,7 @@ ifeq "$(ENGINE)" "left4dead2"
|
||||
CFLAGS += -DSOURCE_ENGINE=6
|
||||
METAMOD = $(MMSOURCE17)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2_demo
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2
|
||||
BINARY = sourcemod.2.l4d2.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
@@ -108,8 +108,8 @@ endif
|
||||
CFLAGS += -DSE_EPISODEONE=1 -DSE_DARKMESSIAH=2 -DSE_ORANGEBOX=3 -DSE_ORANGEBOXVALVE=4 -DSE_LEFT4DEAD=5 -DSE_LEFT4DEAD2=6
|
||||
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
LINK += $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a vstdlib_linux.so \
|
||||
tier0_linux.so -static-libgcc
|
||||
LINK += $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a libvstdlib.so \
|
||||
libtier0.so -static-libgcc
|
||||
else
|
||||
LINK += $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a vstdlib_i486.so \
|
||||
tier0_i486.so -static-libgcc
|
||||
@@ -154,8 +154,8 @@ $(BIN_DIR)/%.o: %.c
|
||||
all: check
|
||||
mkdir -p $(BIN_DIR)
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
ln -sf $(SRCDS)/bin/vstdlib_linux.so vstdlib_linux.so;
|
||||
ln -sf $(SRCDS)/bin/tier0_linux.so tier0_linux.so;
|
||||
ln -sf $(SRCDS)/bin/libvstdlib.so libvstdlib.so;
|
||||
ln -sf $(SRCDS)/bin/libtier0.so libtier0.so;
|
||||
else
|
||||
ln -sf $(SRCDS)/bin/vstdlib_i486.so vstdlib_i486.so;
|
||||
ln -sf $(SRCDS)/bin/tier0_i486.so tier0_i486.so;
|
||||
|
||||
+17
-2
@@ -1441,6 +1441,7 @@ CPlayer::CPlayer()
|
||||
m_TempAdmin = false;
|
||||
m_Info = NULL;
|
||||
m_bAdminCheckSignalled = false;
|
||||
m_UserId = -1;
|
||||
m_bIsInKickQueue = false;
|
||||
m_LastPassword.clear();
|
||||
m_LangId = SOURCEMOD_LANGUAGE_ENGLISH;
|
||||
@@ -1618,8 +1619,22 @@ void CPlayer::Kick(const char *str)
|
||||
{
|
||||
MarkAsBeingKicked();
|
||||
INetChannel *pNetChan = static_cast<INetChannel *>(engine->GetPlayerNetInfo(m_iIndex));
|
||||
IClient *pClient = static_cast<IClient *>(pNetChan->GetMsgHandler());
|
||||
pClient->Disconnect("%s", str);
|
||||
if (pNetChan == NULL)
|
||||
{
|
||||
/* What does this even mean? Hell if I know. */
|
||||
int userid = GetUserId();
|
||||
if (userid > 0)
|
||||
{
|
||||
char buffer[255];
|
||||
UTIL_Format(buffer, sizeof(buffer), "kickid %d %s\n", userid, str);
|
||||
engine->ServerCommand(buffer);
|
||||
}
|
||||
}
|
||||
else
|
||||
{
|
||||
IClient *pClient = static_cast<IClient *>(pNetChan->GetMsgHandler());
|
||||
pClient->Disconnect("%s", str);
|
||||
}
|
||||
}
|
||||
|
||||
void CPlayer::Authorize_Post()
|
||||
|
||||
@@ -200,8 +200,8 @@ static void ReplicateConVar(ConVar *pConVar)
|
||||
|
||||
if (pPlayer && pPlayer->IsInGame() && !pPlayer->IsFakeClient())
|
||||
{
|
||||
INetChannel *netchan = static_cast<INetChannel *>(engine->GetPlayerNetInfo(i));
|
||||
netchan->SendData(buffer);
|
||||
if (INetChannel *netchan = static_cast<INetChannel *>(engine->GetPlayerNetInfo(i)))
|
||||
netchan->SendData(buffer);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1322,6 +1322,11 @@ static cell_t SendConVarValue(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannel *netchan = static_cast<INetChannel *>(engine->GetPlayerNetInfo(params[1]));
|
||||
if (netchan == NULL)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
netchan->SendData(buffer);
|
||||
|
||||
return 1;
|
||||
|
||||
@@ -720,6 +720,10 @@ static cell_t GetTimeConnected(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
return sp_ftoc(pInfo->GetTimeConnected());
|
||||
}
|
||||
@@ -739,6 +743,10 @@ static cell_t GetDataRate(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
return pInfo->GetDataRate();
|
||||
}
|
||||
@@ -758,6 +766,10 @@ static cell_t IsTimingOut(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return 1;
|
||||
}
|
||||
|
||||
return pInfo->IsTimingOut() ? 1 : 0;
|
||||
}
|
||||
@@ -782,6 +794,10 @@ static cell_t GetLatency(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return sp_ftoc(-1);
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
@@ -815,6 +831,10 @@ static cell_t GetAvgLatency(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return sp_ftoc(-1);
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
@@ -848,6 +868,10 @@ static cell_t GetAvgLoss(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return sp_ftoc(-1);
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
@@ -881,6 +905,10 @@ static cell_t GetAvgChoke(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return sp_ftoc(-1);
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
@@ -914,6 +942,10 @@ static cell_t GetAvgData(IPluginContext *pContext, const cell_t *params)
|
||||
}
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
@@ -948,6 +980,11 @@ static cell_t GetAvgPackets(IPluginContext *pContext, const cell_t *params)
|
||||
|
||||
INetChannelInfo *pInfo = engine->GetPlayerNetInfo(client);
|
||||
|
||||
if (pInfo == NULL)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
if (params[2] == MAX_FLOWS)
|
||||
{
|
||||
value = pInfo->GetAvgPackets(FLOW_INCOMING) + pInfo->GetAvgPackets(FLOW_OUTGOING);
|
||||
|
||||
@@ -86,13 +86,13 @@ ifeq "$(ENGINE)" "left4dead2"
|
||||
CFLAGS += -DSOURCE_ENGINE=6
|
||||
METAMOD = $(MMSOURCE17)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server -I$(HL2SDK)/common -I$(HL2SDK)/game/shared
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2_demo
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2
|
||||
GAMEFIX = 2.l4d2
|
||||
override ENGSET = true
|
||||
endif
|
||||
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
LINK_HL2 = $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a vstdlib_linux.so tier0_linux.so
|
||||
LINK_HL2 = $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a libvstdlib.so libtier0.so
|
||||
else
|
||||
LINK_HL2 = $(HL2LIB)/tier1_i486.a $(HL2LIB)/mathlib_i486.a vstdlib_i486.so tier0_i486.so
|
||||
endif
|
||||
@@ -150,8 +150,8 @@ $(BIN_DIR)/%.o: %.cpp
|
||||
all: check
|
||||
mkdir -p $(BIN_DIR)/sdk
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
ln -sf $(SRCDS)/bin/vstdlib_linux.so vstdlib_linux.so;
|
||||
ln -sf $(SRCDS)/bin/tier0_linux.so tier0_linux.so;
|
||||
ln -sf $(SRCDS)/bin/libvstdlib.so libvstdlib.so;
|
||||
ln -sf $(SRCDS)/bin/libtier0.so libtier0.so;
|
||||
else
|
||||
ln -sf $(SRCDS)/bin/vstdlib_i486.so vstdlib_i486.so;
|
||||
ln -sf $(SRCDS)/bin/tier0_i486.so tier0_i486.so;
|
||||
|
||||
@@ -199,6 +199,11 @@ void EntityOutputManager::ShutdownFireEventDetour()
|
||||
|
||||
void EntityOutputManager::FireEventDetour(void *pOutput, CBaseEntity *pActivator, CBaseEntity *pCaller, float fDelay)
|
||||
{
|
||||
if (!pCaller)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
char sOutput[20];
|
||||
Q_snprintf(sOutput, sizeof(sOutput), "%x", pOutput);
|
||||
|
||||
|
||||
@@ -129,7 +129,7 @@ static cell_t PrepSDKCall_SetSignature(IPluginContext *pContext, const cell_t *p
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
#if SOURCE_ENGINE == SE_LEFT4DEAD2
|
||||
#if (SOURCE_ENGINE == SE_ORANGEBOXVALVE) || (SOURCE_ENGINE == SE_LEFT4DEAD2)
|
||||
s_call_addr = memutils->ResolveSymbol(handle, &sig[1]);
|
||||
#else
|
||||
s_call_addr = dlsym(handle, &sig[1]);
|
||||
|
||||
@@ -159,6 +159,177 @@ cell_t TF2_RemoveDisguise(IPluginContext *pContext, const cell_t *params)
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_AddCondition(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
// CTFPlayerShared::AddCond(int, float)
|
||||
if (!pWrapper)
|
||||
{
|
||||
REGISTER_NATIVE_ADDR("AddCondition",
|
||||
PassInfo pass[2]; \
|
||||
pass[0].flags = PASSFLAG_BYVAL; \
|
||||
pass[0].size = sizeof(int); \
|
||||
pass[0].type = PassType_Basic; \
|
||||
pass[1].flags = PASSFLAG_BYVAL; \
|
||||
pass[1].size = sizeof(float); \
|
||||
pass[1].type = PassType_Basic; \
|
||||
pWrapper = g_pBinTools->CreateCall(addr, CallConv_ThisCall, NULL, pass, 2))
|
||||
}
|
||||
|
||||
CBaseEntity *pEntity;
|
||||
if (!(pEntity = UTIL_GetCBaseEntity(params[1], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Client index %d is not valid", params[1]);
|
||||
}
|
||||
|
||||
void *obj = (void *)((uint8_t *)pEntity + playerSharedOffset->actual_offset);
|
||||
|
||||
unsigned char vstk[sizeof(void *) + sizeof(int) + sizeof(float)];
|
||||
unsigned char *vptr = vstk;
|
||||
|
||||
*(void **)vptr = obj;
|
||||
vptr += sizeof(void *);
|
||||
*(int *)vptr = params[2];
|
||||
vptr += sizeof(int);
|
||||
*(float *)vptr = *(float *)¶ms[3];
|
||||
|
||||
pWrapper->Execute(vstk, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_RemoveCondition(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
// CTFPlayerShared::RemoveCond(int)
|
||||
if (!pWrapper)
|
||||
{
|
||||
REGISTER_NATIVE_ADDR("RemoveCondition",
|
||||
PassInfo pass[1]; \
|
||||
pass[0].flags = PASSFLAG_BYVAL; \
|
||||
pass[0].size = sizeof(int); \
|
||||
pass[0].type = PassType_Basic; \
|
||||
pWrapper = g_pBinTools->CreateCall(addr, CallConv_ThisCall, NULL, pass, 1))
|
||||
}
|
||||
|
||||
CBaseEntity *pEntity;
|
||||
if (!(pEntity = UTIL_GetCBaseEntity(params[1], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Client index %d is not valid", params[1]);
|
||||
}
|
||||
|
||||
void *obj = (void *)((uint8_t *)pEntity + playerSharedOffset->actual_offset);
|
||||
|
||||
unsigned char vstk[sizeof(void *) + sizeof(int)];
|
||||
unsigned char *vptr = vstk;
|
||||
|
||||
*(void **)vptr = obj;
|
||||
vptr += sizeof(void *);
|
||||
*(int *)vptr = params[2];
|
||||
|
||||
pWrapper->Execute(vstk, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_StunPlayer(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
// CTFPlayerShared::StunPlayer(float, float, int, CTFPlayer *)
|
||||
if (!pWrapper)
|
||||
{
|
||||
REGISTER_NATIVE_ADDR("StunPlayer",
|
||||
PassInfo pass[4]; \
|
||||
pass[0].flags = PASSFLAG_BYVAL; \
|
||||
pass[0].size = sizeof(float); \
|
||||
pass[0].type = PassType_Basic; \
|
||||
pass[1].flags = PASSFLAG_BYVAL; \
|
||||
pass[1].size = sizeof(float); \
|
||||
pass[1].type = PassType_Basic; \
|
||||
pass[2].flags = PASSFLAG_BYVAL; \
|
||||
pass[2].size = sizeof(int); \
|
||||
pass[2].type = PassType_Basic; \
|
||||
pass[3].flags = PASSFLAG_BYVAL; \
|
||||
pass[3].size = sizeof(CBaseEntity *); \
|
||||
pass[3].type = PassType_Basic; \
|
||||
pWrapper = g_pBinTools->CreateCall(addr, CallConv_ThisCall, NULL, pass, 4))
|
||||
}
|
||||
|
||||
CBaseEntity *pEntity;
|
||||
if (!(pEntity = UTIL_GetCBaseEntity(params[1], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Client index %d is not valid", params[1]);
|
||||
}
|
||||
|
||||
bool bByPlayer = (params[5] != 0);
|
||||
CBaseEntity *pAttacker = NULL;
|
||||
if (bByPlayer && !(pAttacker = UTIL_GetCBaseEntity(params[5], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Attacker index %d is not valid", params[5]);
|
||||
}
|
||||
|
||||
void *obj = (void *)((uint8_t *)pEntity + playerSharedOffset->actual_offset);
|
||||
|
||||
unsigned char vstk[sizeof(void *) + 2*sizeof(float) + sizeof(int) + sizeof(CBaseEntity *)];
|
||||
unsigned char *vptr = vstk;
|
||||
|
||||
*(void **)vptr = obj;
|
||||
vptr += sizeof(void *);
|
||||
*(float *)vptr = sp_ctof(params[2]);
|
||||
vptr += sizeof(float);
|
||||
*(float *)vptr = sp_ctof(params[3]);
|
||||
vptr += sizeof(float);
|
||||
*(int *)vptr = params[4];
|
||||
vptr += sizeof(int);
|
||||
*(CBaseEntity **)vptr = pAttacker;
|
||||
|
||||
pWrapper->Execute(vstk, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_SetPowerplayEnabled(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
// CTFPlayer::SetPowerPlayEnabled(bool)
|
||||
if (!pWrapper)
|
||||
{
|
||||
REGISTER_NATIVE_ADDR("SetPowerplayEnabled",
|
||||
PassInfo pass[1]; \
|
||||
pass[0].flags = PASSFLAG_BYVAL; \
|
||||
pass[0].size = sizeof(bool); \
|
||||
pass[0].type = PassType_Basic; \
|
||||
pWrapper = g_pBinTools->CreateCall(addr, CallConv_ThisCall, NULL, pass, 1))
|
||||
}
|
||||
|
||||
CBaseEntity *pEntity;
|
||||
if (!(pEntity = UTIL_GetCBaseEntity(params[1], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Client index %d is not valid", params[1]);
|
||||
}
|
||||
|
||||
bool bEnablePP = false;
|
||||
if (params[2] != 0)
|
||||
{
|
||||
bEnablePP = true;
|
||||
}
|
||||
|
||||
unsigned char vstk[sizeof(void *) + sizeof(bool)];
|
||||
unsigned char *vptr = vstk;
|
||||
|
||||
*(void **)vptr = (void *)pEntity;
|
||||
vptr += sizeof(void *);
|
||||
*(bool *)vptr = bEnablePP;
|
||||
|
||||
pWrapper->Execute(vstk, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_Respawn(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
@@ -201,6 +372,28 @@ cell_t TF2_Respawn(IPluginContext *pContext, const cell_t *params)
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_Regenerate(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
static ICallWrapper *pWrapper = NULL;
|
||||
|
||||
//CTFPlayer::Regenerate()
|
||||
|
||||
if (!pWrapper)
|
||||
{
|
||||
REGISTER_NATIVE_ADDR("Regenerate",
|
||||
pWrapper = g_pBinTools->CreateCall(addr, CallConv_ThisCall, NULL, NULL, 0));
|
||||
}
|
||||
|
||||
CBaseEntity *pEntity;
|
||||
if (!(pEntity = UTIL_GetCBaseEntity(params[1], true)))
|
||||
{
|
||||
return pContext->ThrowNativeError("Client index %d is not valid", params[1]);
|
||||
}
|
||||
pWrapper->Execute(&pEntity, NULL);
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
cell_t TF2_GetResourceEntity(IPluginContext *pContext, const cell_t *params)
|
||||
{
|
||||
return g_resourceEntity;
|
||||
@@ -223,5 +416,10 @@ sp_nativeinfo_t g_TFNatives[] =
|
||||
{"TF2_RemovePlayerDisguise", TF2_RemoveDisguise},
|
||||
{"TF2_GetResourceEntity", TF2_GetResourceEntity},
|
||||
{"TF2_GetClass", TF2_GetClass},
|
||||
{"TF2_RegeneratePlayer", TF2_Regenerate},
|
||||
{"TF2_AddCondition", TF2_AddCondition},
|
||||
{"TF2_RemoveCondition", TF2_RemoveCondition},
|
||||
{"TF2_SetPlayerPowerPlay", TF2_SetPowerplayEnabled},
|
||||
{"TF2_StunPlayer", TF2_StunPlayer},
|
||||
{NULL, NULL}
|
||||
};
|
||||
|
||||
@@ -136,6 +136,9 @@
|
||||
"game" "NeotokyoSource"
|
||||
"game" "bg2"
|
||||
"game" "cspromod"
|
||||
"game" "FortressForever"
|
||||
"game" "zps"
|
||||
"game" "gesource"
|
||||
}
|
||||
|
||||
"Keys"
|
||||
@@ -156,6 +159,11 @@
|
||||
"game" "NeotokyoSource"
|
||||
"game" "bg2"
|
||||
"game" "cspromod"
|
||||
"game" "pvkii"
|
||||
"game" "FortressForever"
|
||||
"game" "zps"
|
||||
"game" "gesource"
|
||||
"game" "obsidian"
|
||||
}
|
||||
|
||||
"Keys"
|
||||
@@ -180,6 +188,9 @@
|
||||
"game" "bg2"
|
||||
"game" "insurgency"
|
||||
"game" "cspromod"
|
||||
"game" "pvkii"
|
||||
"game" "zps"
|
||||
"game" "gesource"
|
||||
}
|
||||
|
||||
"Keys"
|
||||
|
||||
@@ -20,7 +20,6 @@
|
||||
"game" "hl2mp"
|
||||
"game" "ship"
|
||||
"game" "insurgency"
|
||||
"game" "pvkii"
|
||||
"game" "sourceforts"
|
||||
"game" "FortressForever"
|
||||
"game" "empires"
|
||||
|
||||
@@ -20,6 +20,8 @@
|
||||
"game" "zps"
|
||||
"game" "bg2"
|
||||
"game" "garrysmod"
|
||||
"game" "pvkii"
|
||||
"game" "gesource"
|
||||
}
|
||||
|
||||
"Offsets"
|
||||
|
||||
@@ -21,7 +21,6 @@
|
||||
"game" "ship"
|
||||
"game" "!Dystopia"
|
||||
"game" "insurgency"
|
||||
"game" "pvkii"
|
||||
"game" "sourceforts"
|
||||
"game" "FortressForever"
|
||||
"game" "synergy"
|
||||
@@ -80,7 +79,6 @@
|
||||
"game" "hl2mp"
|
||||
"game" "ship"
|
||||
"game" "!Dystopia"
|
||||
"game" "pvkii"
|
||||
"game" "sourceforts"
|
||||
"game" "FortressForever"
|
||||
"game" "synergy"
|
||||
@@ -129,8 +127,6 @@
|
||||
"game" "garrysmod"
|
||||
"game" "hl2mp"
|
||||
"game" "ship"
|
||||
"game" "insurgency"
|
||||
"game" "pvkii"
|
||||
"game" "sourceforts"
|
||||
"game" "FortressForever"
|
||||
"game" "synergy"
|
||||
@@ -158,7 +154,6 @@
|
||||
{
|
||||
"game" "cstrike"
|
||||
"game" "hl2mp"
|
||||
"game" "pvkii"
|
||||
"game" "sourceforts"
|
||||
"game" "synergy"
|
||||
"game" "hidden"
|
||||
|
||||
@@ -22,6 +22,9 @@
|
||||
"game" "synergy"
|
||||
"game" "bg2"
|
||||
"game" "garrysmod"
|
||||
"game" "pvkii"
|
||||
"game" "gesource"
|
||||
"game" "obsidian"
|
||||
}
|
||||
|
||||
"Offsets"
|
||||
@@ -70,7 +73,7 @@
|
||||
{
|
||||
"game" "ageofchivalry"
|
||||
"game" "zps"
|
||||
"game" "empires"
|
||||
"game" "pvkii"
|
||||
}
|
||||
|
||||
"Signatures"
|
||||
@@ -97,7 +100,7 @@
|
||||
{
|
||||
"game" "ageofchivalry"
|
||||
"game" "zps"
|
||||
"game" "empires"
|
||||
"game" "pvkii"
|
||||
}
|
||||
|
||||
"Signatures"
|
||||
@@ -123,6 +126,8 @@
|
||||
"game" "synergy"
|
||||
"game" "bg2"
|
||||
"game" "garrysmod"
|
||||
"game" "pvkii"
|
||||
"game" "gesource"
|
||||
}
|
||||
|
||||
"Offsets"
|
||||
|
||||
@@ -219,7 +219,7 @@
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "10"
|
||||
"linux" "12"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -238,7 +238,7 @@
|
||||
"SetUserCvar"
|
||||
{
|
||||
"windows" "17"
|
||||
"linux" "55"
|
||||
"linux" "56"
|
||||
}
|
||||
/**
|
||||
* Offset into CBaseClient - Used by CBaseServer::UpdateUserSettings to determine when changes have been made.
|
||||
|
||||
@@ -225,7 +225,7 @@
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "10"
|
||||
"linux" "12"
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -244,7 +244,7 @@
|
||||
"SetUserCvar"
|
||||
{
|
||||
/* Not 100% sure on this, why would windows change and not linux - TEST ME */
|
||||
"windows" "18"
|
||||
"windows" "17"
|
||||
"linux" "63"
|
||||
}
|
||||
/**
|
||||
@@ -270,8 +270,8 @@
|
||||
{
|
||||
"GiveNamedItem"
|
||||
{
|
||||
"windows" "505"
|
||||
"linux" "506"
|
||||
"windows" "506"
|
||||
"linux" "507"
|
||||
}
|
||||
"RemovePlayerItem"
|
||||
{
|
||||
@@ -300,8 +300,8 @@
|
||||
}
|
||||
"CommitSuicide"
|
||||
{
|
||||
"windows" "473"
|
||||
"linux" "473"
|
||||
"windows" "474"
|
||||
"linux" "474"
|
||||
}
|
||||
"GetVelocity"
|
||||
{
|
||||
@@ -350,8 +350,8 @@
|
||||
}
|
||||
"PlayerRunCmd"
|
||||
{
|
||||
"windows" "451"
|
||||
"linux" "452"
|
||||
"windows" "452"
|
||||
"linux" "453"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -95,6 +95,10 @@
|
||||
"windows" "6"
|
||||
"linux" "6"
|
||||
}
|
||||
"g_pGameRules"
|
||||
{
|
||||
"windows" "2"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
@@ -122,6 +126,16 @@
|
||||
"windows" "\x53\x55\x56\x8B\xF1\x8B\x4C\x24\x2A\x85\xC9\x57\x74\x2A\x8B\x01\x8B\x50\x2A\xFF\xD2\x8B\x00\x25\xFF\x2A\x2A\x2A\x83\xC0\x2A\xC1\xE0\x2A\x8B\x3C\x30\xEB\x2A\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x2A\x8B\x5C\x2A\x2A\x8B\x2D\x2A\x2A\x2A\x2A\xEB\x2A\x8D\x2A\x2A\x8B\x37\x85\xF6\x75\x2A\x68\x2A\x2A\x2A\x2A\xFF\x2A\x83\xC4\x2A\xEB\x11\x39"
|
||||
"linux" "@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
|
||||
}
|
||||
"CreateGameRulesObject"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x8B\x0D\x2A\x2A\x2A\x2A\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\x6A\x01\xFF\xD2"
|
||||
}
|
||||
"g_pGameRules"
|
||||
{
|
||||
"library" "server"
|
||||
"linux" "@g_pGameRules"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -23,23 +23,23 @@
|
||||
}
|
||||
"RemovePlayerItem"
|
||||
{
|
||||
"windows" "258"
|
||||
"linux" "259"
|
||||
"windows" "259"
|
||||
"linux" "260"
|
||||
}
|
||||
"Weapon_GetSlot"
|
||||
{
|
||||
"windows" "256"
|
||||
"linux" "257"
|
||||
"windows" "257"
|
||||
"linux" "258"
|
||||
}
|
||||
"Ignite"
|
||||
{
|
||||
"windows" "201"
|
||||
"linux" "202"
|
||||
"windows" "202"
|
||||
"linux" "203"
|
||||
}
|
||||
"Extinguish"
|
||||
{
|
||||
"windows" "205"
|
||||
"linux" "206"
|
||||
"windows" "206"
|
||||
"linux" "207"
|
||||
}
|
||||
"Teleport"
|
||||
{
|
||||
@@ -53,13 +53,13 @@
|
||||
}
|
||||
"GetVelocity"
|
||||
{
|
||||
"windows" "136"
|
||||
"linux" "137"
|
||||
"windows" "137"
|
||||
"linux" "138"
|
||||
}
|
||||
"EyeAngles"
|
||||
{
|
||||
"windows" "127"
|
||||
"linux" "128"
|
||||
"windows" "128"
|
||||
"linux" "129"
|
||||
}
|
||||
"AcceptInput"
|
||||
{
|
||||
@@ -88,8 +88,8 @@
|
||||
}
|
||||
"WeaponEquip"
|
||||
{
|
||||
"windows" "249"
|
||||
"linux" "250"
|
||||
"windows" "250"
|
||||
"linux" "251"
|
||||
}
|
||||
"Activate"
|
||||
{
|
||||
|
||||
@@ -11,7 +11,7 @@
|
||||
|
||||
"Games"
|
||||
{
|
||||
/* Empires 2.24 */
|
||||
/* Empires 2.25 */
|
||||
"empires"
|
||||
{
|
||||
|
||||
@@ -102,6 +102,43 @@
|
||||
"windows" "23"
|
||||
"linux" "24"
|
||||
}
|
||||
"PlayerRunCmd"
|
||||
{
|
||||
"windows" "373"
|
||||
"linux" "374"
|
||||
}
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "10"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
"DispatchSpawn"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x53\x55\x56\x8B\x74\x24\x10\x57\x85\xF6\x0F\x84\x2A\x2A\x2A\x2A\x8B\x1D\x2A\x2A\x2A\x2A\x8B\x03\x8B\x50\x64\x8B\xCB"
|
||||
"linux" "@_Z13DispatchSpawnP11CBaseEntity"
|
||||
}
|
||||
"CreateEntityByName"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x56\x8B\x74\x24\x0C\x57\x8B\x7C\x24\x0C\x83\xFE\xFF\x74\x27\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x50\x54\x56\xFF\xD2"
|
||||
"linux" "@_Z18CreateEntityByNamePKci"
|
||||
}
|
||||
"FindEntityByClassname"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x53\x55\x56\x8B\xF1\x8B\x4C\x24\x10\x57\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x08\xFF\xD2\x8B\x00\x25\xFF\x0F\x00\x00\x40\xC1\xE0\x04\x8B\x3C\x30\xEB\x06\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x2A\x8B\x5C\x24\x18\x8B\x2D\x2A\x2A\x2A\x2A\x8D\xA4\x24\x00\x00\x00\x00\x8B\x37\x85\xF6\x75\x2A\x68\x2A\x2A\x2A\x2A\xFF\x2A\x83\xC4\x04\xEB\x2A\x39\x2A\x2A\x74\x2A\x53"
|
||||
"linux" "@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
|
||||
}
|
||||
"FireOutput"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x55\x8B\xEC\x83\x2A\x2A\x81\xEC\x2A\x2A\x2A\x2A\x53\x56\x8B\x71\x2A\x57\x89"
|
||||
"linux" "@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -96,6 +96,11 @@
|
||||
"windows" "36"
|
||||
"linux" "37"
|
||||
}
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "6"
|
||||
}
|
||||
}
|
||||
|
||||
"Signatures"
|
||||
@@ -120,6 +125,12 @@
|
||||
"library" "server"
|
||||
"windows" "\x56\x8B\x74\x24\x0C\x83\xFE\xFF\x57\x8B\x7C\x24\x0C\x74\x27\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x50\x54\x56\xFF\xD2"
|
||||
}
|
||||
"FireOutput"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x81\xEC\x2A\x2A\x2A\x2A\x53\x55\x56\x8B\x2A\x2A\x85\xF6\x57"
|
||||
"linux" "@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,126 @@
|
||||
"Games"
|
||||
{
|
||||
"gesource"
|
||||
{
|
||||
"Offsets"
|
||||
{
|
||||
"GiveNamedItem"
|
||||
{
|
||||
"windows" "351"
|
||||
"linux" "352"
|
||||
}
|
||||
"RemovePlayerItem"
|
||||
{
|
||||
"windows" "239"
|
||||
"linux" "240"
|
||||
}
|
||||
"Weapon_GetSlot"
|
||||
{
|
||||
"windows" "237"
|
||||
"linux" "238"
|
||||
}
|
||||
"Ignite"
|
||||
{
|
||||
"windows" "194"
|
||||
"linux" "195"
|
||||
}
|
||||
"Extinguish"
|
||||
{
|
||||
"windows" "198"
|
||||
"linux" "199"
|
||||
}
|
||||
"Teleport"
|
||||
{
|
||||
"windows" "100"
|
||||
"linux" "101"
|
||||
}
|
||||
"CommitSuicide"
|
||||
{
|
||||
"windows" "392"
|
||||
"linux" "392"
|
||||
}
|
||||
"GetVelocity"
|
||||
{
|
||||
"windows" "130"
|
||||
"linux" "131"
|
||||
}
|
||||
"EyeAngles"
|
||||
{
|
||||
"windows" "122"
|
||||
"linux" "123"
|
||||
}
|
||||
"AcceptInput"
|
||||
{
|
||||
"windows" "34"
|
||||
"linux" "35"
|
||||
}
|
||||
"DispatchKeyValue"
|
||||
{
|
||||
"windows" "29"
|
||||
"linux" "28"
|
||||
}
|
||||
"DispatchKeyValueFloat"
|
||||
{
|
||||
"windows" "28"
|
||||
"linux" "29"
|
||||
}
|
||||
"DispatchKeyValueVector"
|
||||
{
|
||||
"windows" "27"
|
||||
"linux" "30"
|
||||
}
|
||||
"SetEntityModel"
|
||||
{
|
||||
"windows" "23"
|
||||
"linux" "24"
|
||||
}
|
||||
"WeaponEquip"
|
||||
{
|
||||
"windows" "230"
|
||||
"linux" "231"
|
||||
}
|
||||
"Activate"
|
||||
{
|
||||
"windows" "31"
|
||||
"linux" "32"
|
||||
}
|
||||
"PlayerRunCmd"
|
||||
{
|
||||
"windows" "371"
|
||||
"linux" "372"
|
||||
}
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "10"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
"FindEntityByClassname"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x53\x55\x56\x8B\xF1\x8B\x4C\x2A\x2A\x57\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\xFF\xD2\x8B\x00\x25\x2A\x2A\x2A\x2A\x40\xC1\xE0\x2A\x8B\x3C\x30\xEB\x2A\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x2A\x8B\x5C\x2A\x2A\x8B\x2D\x2A\x2A\x2A\x2A\x8D\xA4\x2A\x2A\x2A\x2A\x2A\x8B\x37\x85\xF6\x75\x2A\x68\x2A\x2A\x2A\x2A\xFF\x2A\x83\xC4\x2A\xEB\x2A\x39"
|
||||
"linux" "@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
|
||||
}
|
||||
"CreateEntityByName"
|
||||
{
|
||||
"library" "server"
|
||||
"linux" "@_Z18CreateEntityByNamePKci"
|
||||
"windows" "\x56\x8B\x74\x24\x2A\x57\x8B\x7C\x24\x2A\x83\xFE\xFF\x74\x2A\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x50\x2A\x56\xFF\xD2"
|
||||
}
|
||||
"DispatchSpawn"
|
||||
{
|
||||
"library" "server"
|
||||
"linux" "@_Z13DispatchSpawnP11CBaseEntity"
|
||||
"windows" "\x53\x55\x56\x8B\x74\x2A\x2A\x57\x85\xF6\x0F\x2A\x2A\x2A\x2A\x2A\x8B\x2A\x2A\x2A\x2A\x2A\x8B\x03\x8B\x50\x2A\x8B\xCB"
|
||||
}
|
||||
"FireOutput"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x81\xEC\x1C\x01\x00\x00\x53\x55\x56\x8B\x71\x14\x57\x89"
|
||||
"linux" "@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -11,7 +11,6 @@
|
||||
|
||||
"Games"
|
||||
{
|
||||
/* Insurgency (2009-07-10) */
|
||||
"insurgency"
|
||||
{
|
||||
"Offsets"
|
||||
@@ -82,22 +81,21 @@
|
||||
"windows" "288"
|
||||
"linux" "289"
|
||||
}
|
||||
"PlayerRunCmd"
|
||||
{
|
||||
"windows" "274"
|
||||
"linux" "275"
|
||||
}
|
||||
"g_pGameRules"
|
||||
{
|
||||
"windows" "2"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
"Offsets"
|
||||
{
|
||||
/* Offset into CreateGameRulesObject */
|
||||
"g_pGameRules"
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "2"
|
||||
}
|
||||
"windows" "6"
|
||||
"linux" "6"
|
||||
}
|
||||
}
|
||||
|
||||
"Signatures"
|
||||
{
|
||||
"CreateGameRulesObject"
|
||||
@@ -125,9 +123,15 @@
|
||||
"CreateEntityByName"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x56\x8B\x74\x24\x0C\x57\x8B\x7C\x24\x0C\x83\x2A\x2A\x74\x27\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x2A\x2A\x56\xFF\xD2\xA3\xCC"
|
||||
"windows" "\x56\x8B\x74\x24\x0C\x57\x8B\x7C\x24\x0C\x83\x2A\x2A\x74\x27\x8B\x0D\x2A\x2A\x2A\x2A\x8B\x01\x8B\x2A\x2A\x56\xFF\xD2\xA3"
|
||||
"linux" "@_Z18CreateEntityByNamePKci"
|
||||
}
|
||||
"FindEntityByClassname"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x53\x55\x56\x8B\xF1\x8B\x4C\x2A\x2A\x57\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2A\xFF\xD2\x8B\x00\x25\x2A\x2A\x2A\x2A\x40\xC1\xE0\x2A\x8B\x3C\x30\xEB\x2A\x8B\xBE\x2A\x2A\x2A\x2A\x85\xFF\x74\x2A\x8B\x5C\x2A\x2A\x8B\x2D\x2A\x2A\x2A\x2A\x8D\xA4\x24\x2A\x2A\x2A\x2A\x8B\x37\x85\xF6\x75\x2A\x68\x2A\x2A\x2A\x2A\xFF\x2A\x83\xC4\x2A\xEB\x2A\x39"
|
||||
"linux" "@_ZN17CGlobalEntityList21FindEntityByClassnameEP11CBaseEntityPKc"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -19,48 +19,48 @@
|
||||
/* CBasePlayer */
|
||||
"GiveNamedItem"
|
||||
{
|
||||
"windows" "328"
|
||||
"linux" "329"
|
||||
"windows" "352"
|
||||
"linux" "353"
|
||||
}
|
||||
"RemovePlayerItem"
|
||||
{
|
||||
"windows" "226"
|
||||
"linux" "227"
|
||||
"windows" "239"
|
||||
"linux" "240"
|
||||
}
|
||||
"Weapon_GetSlot"
|
||||
{
|
||||
"windows" "224"
|
||||
"linux" "225"
|
||||
"windows" "237"
|
||||
"linux" "238"
|
||||
}
|
||||
"Ignite"
|
||||
{
|
||||
"windows" "188"
|
||||
"linux" "189"
|
||||
"windows" "194"
|
||||
"linux" "195"
|
||||
}
|
||||
"Extinguish"
|
||||
{
|
||||
"windows" "189"
|
||||
"linux" "190"
|
||||
"windows" "198"
|
||||
"linux" "199"
|
||||
}
|
||||
"Teleport"
|
||||
{
|
||||
"windows" "98"
|
||||
"linux" "99"
|
||||
"windows" "101"
|
||||
"linux" "102"
|
||||
}
|
||||
"CommitSuicide"
|
||||
{
|
||||
"windows" "356"
|
||||
"linux" "357"
|
||||
"windows" "393"
|
||||
"linux" "393"
|
||||
}
|
||||
"GetVelocity"
|
||||
{
|
||||
"windows" "126"
|
||||
"linux" "127"
|
||||
"windows" "131"
|
||||
"linux" "132"
|
||||
}
|
||||
"EyeAngles"
|
||||
{
|
||||
"windows" "118"
|
||||
"linux" "119"
|
||||
"windows" "123"
|
||||
"linux" "124"
|
||||
}
|
||||
"AcceptInput"
|
||||
{
|
||||
@@ -69,34 +69,53 @@
|
||||
}
|
||||
"DispatchKeyValue"
|
||||
{
|
||||
"windows" "31"
|
||||
"linux" "30"
|
||||
"windows" "29"
|
||||
"linux" "28"
|
||||
}
|
||||
"DispatchKeyValueFloat"
|
||||
{
|
||||
"windows" "30"
|
||||
"linux" "31"
|
||||
"windows" "28"
|
||||
"linux" "29"
|
||||
}
|
||||
"DispatchKeyValueVector"
|
||||
{
|
||||
"windows" "29"
|
||||
"linux" "32"
|
||||
"windows" "27"
|
||||
"linux" "30"
|
||||
}
|
||||
"SetEntityModel"
|
||||
{
|
||||
"windows" "25"
|
||||
"linux" "26"
|
||||
"windows" "24"
|
||||
"linux" "25"
|
||||
}
|
||||
"WeaponEquip"
|
||||
{
|
||||
"windows" "217"
|
||||
"linux" "218"
|
||||
"windows" "230"
|
||||
"linux" "231"
|
||||
}
|
||||
"Activate"
|
||||
{
|
||||
"windows" "32"
|
||||
"linux" "33"
|
||||
}
|
||||
"PlayerRunCmd"
|
||||
{
|
||||
"windows" "372"
|
||||
"linux" "373"
|
||||
}
|
||||
"FireOutputBackup"
|
||||
{
|
||||
"windows" "6"
|
||||
"linux" "10"
|
||||
}
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
"FireOutput"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x81\xEC\x2A\x2A\x2A\x2A\x53\x55\x56\x8B\x71\x2A\x85\xF6\x57"
|
||||
"linux" "@_ZN17CBaseEntityOutput10FireOutputE9variant_tP11CBaseEntityS2_f"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -28,18 +28,18 @@
|
||||
}
|
||||
"Weapon_GetSlot"
|
||||
{
|
||||
"windows" "256"
|
||||
"linux" "257"
|
||||
"windows" "257"
|
||||
"linux" "258"
|
||||
}
|
||||
"Ignite"
|
||||
{
|
||||
"windows" "201"
|
||||
"linux" "202"
|
||||
"windows" "202"
|
||||
"linux" "203"
|
||||
}
|
||||
"Extinguish"
|
||||
{
|
||||
"windows" "205"
|
||||
"linux" "206"
|
||||
"windows" "206"
|
||||
"linux" "207"
|
||||
}
|
||||
"Teleport"
|
||||
{
|
||||
@@ -53,13 +53,13 @@
|
||||
}
|
||||
"GetVelocity"
|
||||
{
|
||||
"windows" "136"
|
||||
"linux" "137"
|
||||
"windows" "137"
|
||||
"linux" "138"
|
||||
}
|
||||
"EyeAngles"
|
||||
{
|
||||
"windows" "127"
|
||||
"linux" "128"
|
||||
"windows" "128"
|
||||
"linux" "129"
|
||||
}
|
||||
"DispatchKeyValue"
|
||||
{
|
||||
@@ -88,8 +88,8 @@
|
||||
}
|
||||
"WeaponEquip"
|
||||
{
|
||||
"windows" "249"
|
||||
"linux" "250"
|
||||
"windows" "250"
|
||||
"linux" "251"
|
||||
}
|
||||
"Activate"
|
||||
{
|
||||
|
||||
@@ -99,11 +99,6 @@
|
||||
}
|
||||
"Signatures"
|
||||
{
|
||||
"CreateGameRulesObject"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x8B\x0D\x2A\x2A\x2A\x2A\x85\xC9\x74\x2A\x8B\x01\x8B\x50\x2C\x6A\x01"
|
||||
}
|
||||
"FindEntityByClassname"
|
||||
{
|
||||
"library" "server"
|
||||
@@ -120,7 +115,7 @@
|
||||
{
|
||||
"library" "server"
|
||||
"linux" "@_Z13DispatchSpawnP11CBaseEntity"
|
||||
"windows" "\x53\x55\x56\x8B\x74\x24\x10\x2A\x85\xF6\x0F\x84\x2A\x2A\x2A\x2A\x8B\x1D\x2A\x2A\x2A\x2A\x8B\x03\x8B\x50\x60\x8B\xCB"
|
||||
"windows" "\x53\x55\x56\x8B\x74\x2A\x2A\x57\x85\xF6\x0F\x2A\x2A\x2A\x2A\x2A\x8B\x2A\x2A\x2A\x2A\x2A\x8B\x03\x8B\x50\x2A\x8B\xCB"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -142,4 +142,12 @@
|
||||
{
|
||||
"game" "bg2"
|
||||
}
|
||||
"game.cspromod.txt"
|
||||
{
|
||||
"game" "cspromod"
|
||||
}
|
||||
"game.gesource.txt"
|
||||
{
|
||||
"game" "gesource"
|
||||
}
|
||||
}
|
||||
|
||||
@@ -51,13 +51,43 @@
|
||||
"linux" "@_ZN14CTFCompoundBow26CalcIsAttackCriticalHelperEv"
|
||||
"windows" "\xE8\x2A\x2A\x2A\x2A\x85\xC0\x74\x14\x6A\x0B"
|
||||
}
|
||||
"Regenerate"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x83\xEC\x08\xD9\xE8\x53\x55\xD9\x2A\x2A\x2A\x56\x8B\xF1\x8B\x06\x8B\x90"
|
||||
"linux" "@_ZN9CTFPlayer10RegenerateEv"
|
||||
}
|
||||
"AddCondition"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x56\x57\x8B\x7C\x2A\x2A\x8B\xF1\x8B\xCF\xBA\x01\x00\x00\x00\xD3\xE2\x8D\x46\x2A\x8D\x4C\x2A\x2A\x51\x0B\x10"
|
||||
"linux" "@_ZN15CTFPlayerShared7AddCondEif"
|
||||
}
|
||||
"RemoveCondition"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x56\x57\x8B\x7C\x2A\x2A\x8B\xF1\x8B\xCF\xBA\x01\x00\x00\x00\xD3\xE2\x8D\x46\x2A\x8D\x4C\x2A\x2A\x51\xF7\xD2"
|
||||
"linux" "@_ZN15CTFPlayerShared10RemoveCondEi"
|
||||
}
|
||||
"SetPowerplayEnabled"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x80\x7C\x2A\x2A\x2A\x56\x8B\xF1\x74\x2A\xA1\x2A\x2A\x2A\x2A\xD9\x2A\x2A\x57"
|
||||
"linux" "@_ZN9CTFPlayer19SetPowerplayEnabledEb"
|
||||
}
|
||||
"StunPlayer"
|
||||
{
|
||||
"library" "server"
|
||||
"windows" "\x51\xD9\x2A\x2A\x2A\x2A\x2A\x56\x83\xEC\x2A\xD9\x2A\x2A\x2A\x8B\xF1\xD9\xEE\xD9\x2A\x2A\x2A\xD9\xE8"
|
||||
"linux" "@_ZN15CTFPlayerShared10StunPlayerEffiP9CTFPlayer"
|
||||
}
|
||||
}
|
||||
"Offsets"
|
||||
{
|
||||
"ForceRespawn"
|
||||
{
|
||||
"windows" "312"
|
||||
"linux" "313"
|
||||
"windows" "313"
|
||||
"linux" "314"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
+1
-1
@@ -60,7 +60,7 @@ public OnPluginStart()
|
||||
LoadTranslations("basebans.phrases");
|
||||
|
||||
RegAdminCmd("sm_ban", Command_Ban, ADMFLAG_BAN, "sm_ban <#userid|name> <minutes|0> [reason]");
|
||||
RegAdminCmd("sm_unban", Command_Unban, ADMFLAG_UNBAN, "sm_unban <steamid>");
|
||||
RegAdminCmd("sm_unban", Command_Unban, ADMFLAG_UNBAN, "sm_unban <steamid|ip>");
|
||||
RegAdminCmd("sm_addban", Command_AddBan, ADMFLAG_RCON, "sm_addban <time> <steamid> [reason]");
|
||||
RegAdminCmd("sm_banip", Command_BanIp, ADMFLAG_BAN, "sm_banip <ip|#userid|name> <time> [reason]");
|
||||
|
||||
|
||||
@@ -601,7 +601,7 @@ native Float:GetClientTime(client);
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param flow Traffic flowing direction.
|
||||
* @return Latency.
|
||||
* @return Latency, or -1 if network info is not available.
|
||||
* @error Invalid client index, client not in game, or fake client.
|
||||
*/
|
||||
native Float:GetClientLatency(client, NetFlow:flow);
|
||||
@@ -611,7 +611,7 @@ native Float:GetClientLatency(client, NetFlow:flow);
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param flow Traffic flowing direction.
|
||||
* @return Average latency.
|
||||
* @return Latency, or -1 if network info is not available.
|
||||
* @error Invalid client index, client not in game, or fake client.
|
||||
*/
|
||||
native Float:GetClientAvgLatency(client, NetFlow:flow);
|
||||
@@ -621,7 +621,7 @@ native Float:GetClientAvgLatency(client, NetFlow:flow);
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param flow Traffic flowing direction.
|
||||
* @return Average packet loss.
|
||||
* @return Average packet loss, or -1 if network info is not available.
|
||||
* @error Invalid client index, client not in game, or fake client.
|
||||
*/
|
||||
native Float:GetClientAvgLoss(client, NetFlow:flow);
|
||||
@@ -631,7 +631,7 @@ native Float:GetClientAvgLoss(client, NetFlow:flow);
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param flow Traffic flowing direction.
|
||||
* @return Average packet choke.
|
||||
* @return Average packet loss, or -1 if network info is not available.
|
||||
* @error Invalid client index, client not in game, or fake client.
|
||||
*/
|
||||
native Float:GetClientAvgChoke(client, NetFlow:flow);
|
||||
|
||||
@@ -30,6 +30,11 @@
|
||||
* Version: $Id$
|
||||
*/
|
||||
|
||||
#if defined _functions_included
|
||||
#endinput
|
||||
#endif
|
||||
#define _functions_included
|
||||
|
||||
#define SP_PARAMFLAG_BYREF (1<<0) /**< Internal use only. */
|
||||
|
||||
/**
|
||||
|
||||
@@ -403,7 +403,7 @@ stock EmitSoundToAll(const String:sample[],
|
||||
bool:updatePos = true,
|
||||
Float:soundtime = 0.0)
|
||||
{
|
||||
new clients[maxClients];
|
||||
new clients[MaxClients];
|
||||
new total = 0;
|
||||
|
||||
for (new i=1; i<=MaxClients; i++)
|
||||
|
||||
@@ -35,6 +35,20 @@
|
||||
#endif
|
||||
#define _tf2_included
|
||||
|
||||
#define TF_STUNFLAG_SLOWDOWN (1 << 0) // activates slowdown modifier
|
||||
#define TF_STUNFLAG_BONKSTUCK (1 << 1) // bonk sound, stuck
|
||||
#define TF_STUNFLAG_LIMITMOVEMENT (1 << 2) // disable forward/backward movement
|
||||
#define TF_STUNFLAG_CHEERSOUND (1 << 3) // cheering sound
|
||||
#define TF_STUNFLAG_NOSOUNDOREFFECT (1 << 5) // no sound or particle
|
||||
#define TF_STUNFLAG_THIRDPERSON (1 << 6) // panic animation
|
||||
#define TF_STUNFLAG_GHOSTEFFECT (1 << 7) // ghost particles
|
||||
|
||||
#define TF_STUNFLAGS_LOSERSTATE TF_STUNFLAG_SLOWDOWN|TF_STUNFLAG_NOSOUNDOREFFECT|TF_STUNFLAG_THIRDPERSON
|
||||
#define TF_STUNFLAGS_GHOSTSCARE TF_STUNFLAG_GHOSTEFFECT|TF_STUNFLAG_THIRDPERSON
|
||||
#define TF_STUNFLAGS_SMALLBONK TF_STUNFLAG_THIRDPERSON|TF_STUNFLAG_SLOWDOWN
|
||||
#define TF_STUNFLAGS_NORMALBONK TF_STUNFLAG_BONKSTUCK
|
||||
#define TF_STUNFLAGS_BIGBONK TF_STUNFLAG_CHEERSOUND|TF_STUNFLAG_BONKSTUCK
|
||||
|
||||
enum TFClassType
|
||||
{
|
||||
TFClass_Unknown = 0,
|
||||
@@ -57,6 +71,33 @@ enum TFTeam
|
||||
TFTeam_Blue = 3
|
||||
};
|
||||
|
||||
enum TFCond
|
||||
{
|
||||
TFCond_Slowed = 0,
|
||||
TFCond_Zoomed,
|
||||
TFCond_Disguising,
|
||||
TFCond_Disguised,
|
||||
TFCond_Cloaked,
|
||||
TFCond_Ubercharged,
|
||||
TFCond_TeleportedGlow,
|
||||
TFCond_Taunting,
|
||||
TFCond_UberchargeFading,
|
||||
TFCond_Unknown1,
|
||||
TFCond_Teleporting,
|
||||
TFCond_Kritzkrieged,
|
||||
TFCond_Unknown2,
|
||||
TFCond_DeadRingered,
|
||||
TFCond_Bonked,
|
||||
TFCond_Dazed,
|
||||
TFCond_Buffed,
|
||||
TFCond_Charging,
|
||||
TFCond_DemoBuff,
|
||||
TFCond_Healing,
|
||||
TFCond_OnFire,
|
||||
TFCond_Overhealed,
|
||||
TFCond_Jarated
|
||||
}
|
||||
|
||||
/**
|
||||
* Sets a client on fire for 10 seconds.
|
||||
*
|
||||
@@ -75,6 +116,46 @@ native TF2_IgnitePlayer(client, target);
|
||||
*/
|
||||
native TF2_RespawnPlayer(client);
|
||||
|
||||
/**
|
||||
* Regenerates a client's health and ammunition
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @noreturn
|
||||
* @error Invalid client index, client not in game, or no mod support.
|
||||
*/
|
||||
native TF2_RegeneratePlayer(client);
|
||||
|
||||
/**
|
||||
* Adds a condition to a player
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param condition Integer identifier of condition to apply.
|
||||
* @param duration Duration of condition (does not apply to all conditions).
|
||||
* @noreturn
|
||||
* @error Invalid client index, client not in game, or no mod support.
|
||||
*/
|
||||
native TF2_AddCondition(client, TFCond:condition, Float:duration);
|
||||
|
||||
/**
|
||||
* Removes a condition from a player
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param condition Integer identifier of condition to remove.
|
||||
* @noreturn
|
||||
* @error Invalid client index, client not in game, or no mod support.
|
||||
*/
|
||||
native TF2_RemoveCondition(client, TFCond:condition);
|
||||
|
||||
/**
|
||||
* Enables/disables PowerPlay mode on a player.
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param enabled Whether to enable or disable PowerPlay on player.
|
||||
* @noreturn
|
||||
* @error Invalid client index, client not in game, or no mod support.
|
||||
*/
|
||||
native TF2_SetPlayerPowerPlay(client, bool:enabled);
|
||||
|
||||
/**
|
||||
* Disguises a client to the given model and team. Only has an effect on spies.
|
||||
*
|
||||
@@ -97,6 +178,19 @@ native TF2_DisguisePlayer(client, TFTeam:team, TFClassType:class);
|
||||
*/
|
||||
native TF2_RemovePlayerDisguise(client);
|
||||
|
||||
/**
|
||||
* Stuns a client
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @param float Duration of stun.
|
||||
* @param float Slowdown percent (as decimal, 0.00-1.00)
|
||||
* (ignored if TF_STUNFLAG_SLOWDOWN is not set.
|
||||
* @param int Stun flags.
|
||||
* @param attacker Attacker's index (0 is allowed for world).
|
||||
* @noreturn
|
||||
*/
|
||||
native TF2_StunPlayer(client, Float:duration, Float:slowdown=0.0, stunflags, attacker=0);
|
||||
|
||||
/**
|
||||
* Retrieves the entity index of the CPlayerResource entity
|
||||
*
|
||||
|
||||
@@ -38,6 +38,36 @@
|
||||
#include <tf2>
|
||||
#include <sdktools>
|
||||
|
||||
#define TF_CONDFLAG_NONE 0
|
||||
#define TF_CONDFLAG_SLOWED (1 << 0)
|
||||
#define TF_CONDFLAG_ZOOMED (1 << 1)
|
||||
#define TF_CONDFLAG_DISGUISING (1 << 2)
|
||||
#define TF_CONDFLAG_DISGUISED (1 << 3)
|
||||
#define TF_CONDFLAG_CLOAKED (1 << 4)
|
||||
#define TF_CONDFLAG_UBERCHARGED (1 << 5)
|
||||
#define TF_CONDFLAG_TELEPORTGLOW (1 << 6)
|
||||
#define TF_CONDFLAG_TAUNTING (1 << 7)
|
||||
#define TF_CONDFLAG_UBERCHARGEFADE (1 << 8)
|
||||
#define TF_CONDFLAG_TELEPORTING (1 << 10)
|
||||
#define TF_CONDFLAG_KRITZKRIEGED (1 << 11)
|
||||
#define TF_CONDFLAG_DEADRINGERED (1 << 13)
|
||||
#define TF_CONDFLAG_BONKED (1 << 14)
|
||||
#define TF_CONDFLAG_DAZED (1 << 15)
|
||||
#define TF_CONDFLAG_BUFFED (1 << 16)
|
||||
#define TF_CONDFLAG_CHARGING (1 << 17)
|
||||
#define TF_CONDFLAG_DEMOBUFF (1 << 18)
|
||||
#define TF_CONDFLAG_HEALING (1 << 19)
|
||||
#define TF_CONDFLAG_ONFIRE (1 << 20)
|
||||
#define TF_CONDFLAG_OVERHEALED (1 << 21)
|
||||
#define TF_CONDFLAG_JARATED (1 << 22)
|
||||
|
||||
#define TF_DEATHFLAG_KILLERDOMINATION (1 << 0)
|
||||
#define TF_DEATHFLAG_ASSISTERDOMINATION (1 << 1)
|
||||
#define TF_DEATHFLAG_KILLERREVENGE (1 << 2)
|
||||
#define TF_DEATHFLAG_ASSISTERREVENGE (1 << 3)
|
||||
#define TF_DEATHFLAG_FIRSTBLOOD (1 << 4)
|
||||
#define TF_DEATHFLAG_DEADRINGER (1 << 5)
|
||||
|
||||
enum TFResourceType
|
||||
{
|
||||
TFResource_Ping,
|
||||
@@ -217,3 +247,13 @@ stock TF2_RemoveAllWeapons(client)
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Gets a player's condition bits
|
||||
*
|
||||
* @param client Player's index.
|
||||
* @return Player's condition bits
|
||||
*/
|
||||
stock TF2_GetPlayerConditionFlags(client)
|
||||
{
|
||||
return GetEntProp(client, Prop_Send, "m_nPlayerCond");
|
||||
}
|
||||
|
||||
@@ -37,6 +37,6 @@
|
||||
|
||||
#define SOURCEMOD_V_MAJOR 1 /**< SourceMod Major version */
|
||||
#define SOURCEMOD_V_MINOR 3 /**< SourceMod Minor version */
|
||||
#define SOURCEMOD_V_RELEASE 1 /**< SourceMod Release version */
|
||||
#define SOURCEMOD_V_RELEASE 2 /**< SourceMod Release version */
|
||||
|
||||
#define SOURCEMOD_VERSION "1.3.1" /**< SourceMod version string (major.minor.release.build) */
|
||||
#define SOURCEMOD_VERSION "1.3.2" /**< SourceMod version string (major.minor.release.build) */
|
||||
|
||||
+111
-30
@@ -15,25 +15,24 @@ public Plugin:myinfo =
|
||||
public OnPluginStart()
|
||||
{
|
||||
RegConsoleCmd("sm_burnme", Command_Burn);
|
||||
RegConsoleCmd("sm_invuln", Command_Invuln);
|
||||
RegConsoleCmd("sm_respawn", Command_Respawn);
|
||||
RegConsoleCmd("sm_disguise", Command_Disguise);
|
||||
RegConsoleCmd("sm_remdisguise", Command_RemDisguise);
|
||||
RegConsoleCmd("sm_class", Command_Class);
|
||||
RegConsoleCmd("sm_remove", Command_Remove);
|
||||
RegConsoleCmd("sm_changeclass", Command_ChangeClass);
|
||||
RegConsoleCmd("sm_regenerate", Command_Regenerate);
|
||||
RegConsoleCmd("sm_uberme", Command_UberMe);
|
||||
RegConsoleCmd("sm_unuberme", Command_UnUberMe);
|
||||
RegConsoleCmd("sm_setpowerplay", Command_SetPowerPlay);
|
||||
RegConsoleCmd("sm_panic", Command_Panic);
|
||||
RegConsoleCmd("sm_bighit", Command_BigHit);
|
||||
RegConsoleCmd("sm_frighten", Command_Frighten);
|
||||
}
|
||||
|
||||
public Action:Command_Class(client, args)
|
||||
{
|
||||
TF2_RemoveAllWeapons(client);
|
||||
|
||||
decl String:text[10];
|
||||
GetCmdArg(1, text, sizeof(text));
|
||||
|
||||
new one = StringToInt(text);
|
||||
|
||||
TF2_EquipPlayerClassWeapons(client, TFClassType:one);
|
||||
|
||||
PrintToChat(client, "Test: sniper's classnum is %i (should be %i)", TF2_GetClass("sniper"), TFClass_Sniper);
|
||||
|
||||
@@ -93,28 +92,6 @@ public Action:Command_Burn(client, args)
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_Invuln(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
if (args < 1)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
decl String:text[10];
|
||||
GetCmdArg(1, text, sizeof(text));
|
||||
|
||||
new bool:one = !!StringToInt(text);
|
||||
|
||||
TF2_SetPlayerInvuln(client, one)
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_Disguise(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
@@ -165,3 +142,107 @@ public Action:Command_Respawn(client, args)
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_Regenerate(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
TF2_RegeneratePlayer(client);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_UberMe(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
if (args < 1)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
decl String:text[10];
|
||||
GetCmdArg(1, text, sizeof(text));
|
||||
|
||||
new Float:one = StringToFloat(text);
|
||||
|
||||
TF2_AddCondition(client, TFCond_Ubercharged, one);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_UnUberMe(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
TF2_RemoveCondition(client, TFCond_Ubercharged);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_SetPowerPlay(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
if (args < 1)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
decl String:text[10];
|
||||
GetCmdArg(1, text, sizeof(text));
|
||||
|
||||
new bool:one = bool:StringToInt(text);
|
||||
|
||||
TF2_SetPlayerPowerPlay(client, one);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_Panic(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
TF2_StunPlayer(client, 15.0, 0.25, TF_STUNFLAGS_LOSERSTATE);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_BigHit(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
TF2_StunPlayer(client, 5.0, _, TF_STUNFLAGS_BIGBONK, client);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
public Action:Command_Frighten(client, args)
|
||||
{
|
||||
if (client == 0)
|
||||
{
|
||||
return Plugin_Handled;
|
||||
}
|
||||
|
||||
TF2_StunPlayer(client, 5.0, _, TF_STUNFLAGS_GHOSTSCARE);
|
||||
|
||||
return Plugin_Handled;
|
||||
}
|
||||
+1
-1
@@ -1 +1 @@
|
||||
1.3.1
|
||||
1.3.2
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# (C)2004-2009 SourceMod Development Team
|
||||
# (C)2004-2010 SourceMod Development Team
|
||||
# Makefile written by David "BAILOPAN" Anderson
|
||||
|
||||
SMSDK = ..
|
||||
@@ -37,7 +37,7 @@ ifeq "$(ENGINE)" "original"
|
||||
METAMOD = $(MMSOURCE18)/core-legacy
|
||||
INCLUDE += -I$(HL2SDK)/public/dlls
|
||||
SRCDS = $(SRCDS_BASE)
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "orangebox"
|
||||
@@ -48,7 +48,7 @@ ifeq "$(ENGINE)" "orangebox"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/orangebox
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "orangeboxvalve"
|
||||
@@ -59,7 +59,8 @@ ifeq "$(ENGINE)" "orangeboxvalve"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/orangebox
|
||||
LIB_SUFFIX = i486
|
||||
LIB_PREFIX = lib
|
||||
LIB_SUFFIX = .so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "left4dead"
|
||||
@@ -70,7 +71,7 @@ ifeq "$(ENGINE)" "left4dead"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/l4d
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
@@ -81,14 +82,15 @@ ifeq "$(ENGINE)" "left4dead2"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2
|
||||
LIB_SUFFIX = linux
|
||||
LIB_PREFIX = lib
|
||||
LIB_SUFFIX = .so
|
||||
override ENGSET = true
|
||||
endif
|
||||
|
||||
CFLAGS += -DSE_EPISODEONE=1 -DSE_DARKMESSIAH=2 -DSE_ORANGEBOX=3 -DSE_ORANGEBOXVALVE=4 \
|
||||
-DSE_LEFT4DEAD=5 -DSE_LEFT4DEAD2=6
|
||||
|
||||
LINK = vstdlib_$(LIB_SUFFIX).so tier0_$(LIB_SUFFIX).so -m32 -ldl -lm
|
||||
LINK = $(LIB_PREFIX)vstdlib$(LIB_SUFFIX) $(LIB_PREFIX)tier0$(LIB_SUFFIX) -m32 -ldl -lm
|
||||
|
||||
INCLUDE += -I. -I.. -I$(HL2PUB) -I$(HL2PUB)/engine -I$(HL2PUB)/tier0 -I$(HL2PUB)/tier1 \
|
||||
-I$(METAMOD) -I$(METAMOD)/sourcehook -I$(SMSDK) -I$(SMSDK)/jit -I$(SMSDK)/jit/x86 \
|
||||
@@ -133,8 +135,8 @@ $(BIN_DIR)/%.o: %.cpp
|
||||
|
||||
all: check
|
||||
mkdir -p $(BIN_DIR)
|
||||
ln -sf $(HL2LIB)/vstdlib_$(LIB_SUFFIX).so
|
||||
ln -sf $(HL2LIB)/tier0_$(LIB_SUFFIX).so
|
||||
ln -sf $(HL2LIB)/$(LIB_PREFIX)vstdlib$(LIB_SUFFIX)
|
||||
ln -sf $(HL2LIB)/$(LIB_PREFIX)tier0$(LIB_SUFFIX)
|
||||
$(MAKE) -f Makefile mms_ext
|
||||
|
||||
check:
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
# (C)2004-2009 SourceMod Development Team
|
||||
# (C)2004-2010 SourceMod Development Team
|
||||
# Makefile written by David "BAILOPAN" Anderson
|
||||
|
||||
SMSDK = ../..
|
||||
@@ -40,7 +40,7 @@ ifeq "$(ENGINE)" "original"
|
||||
METAMOD = $(MMSOURCE18)/core-legacy
|
||||
INCLUDE += -I$(HL2SDK)/public/dlls
|
||||
SRCDS = $(SRCDS_BASE)
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "orangebox"
|
||||
@@ -51,7 +51,7 @@ ifeq "$(ENGINE)" "orangebox"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/orangebox
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "orangeboxvalve"
|
||||
@@ -62,7 +62,8 @@ ifeq "$(ENGINE)" "orangeboxvalve"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/orangebox
|
||||
LIB_SUFFIX = i486
|
||||
LIB_PREFIX = lib
|
||||
LIB_SUFFIX = .so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "left4dead"
|
||||
@@ -73,7 +74,7 @@ ifeq "$(ENGINE)" "left4dead"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/l4d
|
||||
LIB_SUFFIX = i486
|
||||
LIB_SUFFIX = _i486.so
|
||||
override ENGSET = true
|
||||
endif
|
||||
ifeq "$(ENGINE)" "left4dead2"
|
||||
@@ -84,12 +85,13 @@ ifeq "$(ENGINE)" "left4dead2"
|
||||
METAMOD = $(MMSOURCE18)/core
|
||||
INCLUDE += -I$(HL2SDK)/public/game/server
|
||||
SRCDS = $(SRCDS_BASE)/left4dead2
|
||||
LIB_SUFFIX = linux
|
||||
LIB_PREFIX = lib
|
||||
LIB_SUFFIX = .so
|
||||
override ENGSET = true
|
||||
endif
|
||||
|
||||
ifeq "$(USEMETA)" "true"
|
||||
LINK_HL2 = $(HL2LIB)/tier1_i486.a vstdlib_$(LIB_SUFFIX).so tier0_$(LIB_SUFFIX).so
|
||||
LINK_HL2 = $(HL2LIB)/tier1_i486.a $(LIB_PREFIX)vstdlib$(LIB_SUFFIX) $(LIB_PREFIX)tier0$(LIB_SUFFIX)
|
||||
|
||||
LINK += $(LINK_HL2)
|
||||
|
||||
@@ -147,8 +149,8 @@ $(BIN_DIR)/%.o: %.cpp
|
||||
all: check
|
||||
mkdir -p $(BIN_DIR)/sdk
|
||||
if [ "$(USEMETA)" = "true" ]; then \
|
||||
ln -sf $(HL2LIB)/vstdlib_$(LIB_SUFFIX).so; \
|
||||
ln -sf $(HL2LIB)/tier0_$(LIB_SUFFIX).so; \
|
||||
ln -sf $(HL2LIB)/$(LIB_PREFIX)vstdlib$(LIB_SUFFIX); \
|
||||
ln -sf $(HL2LIB)/$(LIB_PREFIX)tier0$(LIB_SUFFIX); \
|
||||
fi
|
||||
$(MAKE) -f Makefile extension
|
||||
|
||||
|
||||
+1
-1
@@ -2,7 +2,7 @@ a billion and nanas
|
||||
joys of buildbot, part 2: buildbot and the very lonely square-shaped duck
|
||||
joys of buildbot, part 3: an accidental event proves troublesome for a psychic fish
|
||||
joys of buildbot, part 4: a transient mummy is perplexed by a broken wand
|
||||
buildbot has horrible bugs
|
||||
buildbot has horrible blugs
|
||||
i am the very model of a modern major general
|
||||
|
||||
It's no wonder the build always falls over when we call it pushing.
|
||||
|
||||
Reference in New Issue
Block a user