Update from SDK 2013

This commit is contained in:
Kenzzer authored and Nicholas Hastings committed 2025-02-19 18:36:16 -05:00
1 parent e0e01948b8
commit ebd971b421
7471 files changed
+2595606 -1256665

No files matched your search

+383 -383
View File
@@ -1,383 +1,383 @@
//========= Copyright © 1996-2005, Valve Corporation, All rights reserved. ============//
//
// Purpose: Basic BOT handling.
//
// $Workfile: $
// $Date: $
//
//-----------------------------------------------------------------------------
// $Log: $
//
// $NoKeywords: $
//=============================================================================//
#include "interface.h"
#include "filesystem.h"
#undef VECTOR_NO_SLOW_OPERATIONS
#include "mathlib/vector.h"
#include "eiface.h"
#include "edict.h"
#include "game/server/iplayerinfo.h"
#include "igameevents.h"
#include "convar.h"
#include "vstdlib/random.h"
#include "../../game/shared/in_buttons.h"
#include "../../game/shared/shareddefs.h"
//#include "../../game_shared/util_shared.h"
#include "engine/IEngineTrace.h"
extern IBotManager *botmanager;
extern IUniformRandomStream *randomStr;
extern IPlayerInfoManager *playerinfomanager;
extern IVEngineServer *engine;
extern IEngineTrace *enginetrace;
extern IPlayerInfoManager *playerinfomanager; // game dll interface to interact with players
extern IServerPluginHelpers *helpers; // special 3rd party plugin helpers from the engine
extern CGlobalVars *gpGlobals;
ConVar bot_forcefireweapon( "plugin_bot_forcefireweapon", "", 0, "Force bots with the specified weapon to fire." );
ConVar bot_forceattack2( "plugin_bot_forceattack2", "0", 0, "When firing, use attack2." );
ConVar bot_forceattackon( "plugin_bot_forceattackon", "0", 0, "When firing, don't tap fire, hold it down." );
ConVar bot_flipout( "plugin_bot_flipout", "0", 0, "When on, all bots fire their guns." );
ConVar bot_changeclass( "plugin_bot_changeclass", "0", 0, "Force all bots to change to the specified class." );
static ConVar bot_mimic( "plugin_bot_mimic", "0", 0, "Bot uses usercmd of player by index." );
static ConVar bot_mimic_yaw_offset( "plugin_bot_mimic_yaw_offset", "0", 0, "Offsets the bot yaw." );
ConVar bot_sendcmd( "plugin_bot_sendcmd", "", 0, "Forces bots to send the specified command." );
ConVar bot_crouch( "plugin_bot_crouch", "0", 0, "Bot crouches" );
// This is our bot class.
class CPluginBot
{
public:
CPluginBot() :
m_bBackwards(0),
m_flNextTurnTime(0),
m_bLastTurnToRight(0),
m_flNextStrafeTime(0),
m_flSideMove(0),
m_ForwardAngle(),
m_LastAngles()
{
}
bool m_bBackwards;
float m_flNextTurnTime;
bool m_bLastTurnToRight;
float m_flNextStrafeTime;
float m_flSideMove;
QAngle m_ForwardAngle;
QAngle m_LastAngles;
IBotController *m_BotInterface;
IPlayerInfo *m_PlayerInfo;
edict_t *m_BotEdict;
};
CUtlVector<CPluginBot> s_Bots;
void Bot_Think( CPluginBot *pBot );
// Handler for the "bot" command.
void BotAdd_f()
{
if ( !botmanager )
return;
static int s_BotNum = 0;
char botName[64];
Q_snprintf( botName, sizeof(botName), "Bot_%i", s_BotNum );
s_BotNum++;
edict_t *botEdict = botmanager->CreateBot( botName );
if ( botEdict )
{
int botIndex = s_Bots.AddToTail();
CPluginBot & bot = s_Bots[ botIndex ];
bot.m_BotInterface = botmanager->GetBotController( botEdict );
bot.m_PlayerInfo = playerinfomanager->GetPlayerInfo( botEdict );
bot.m_BotEdict = botEdict;
Assert( bot.m_BotInterface );
}
}
ConCommand cc_Bot( "plugin_bot_add", BotAdd_f, "Add a bot." );
//-----------------------------------------------------------------------------
// Purpose: Run through all the Bots in the game and let them think.
//-----------------------------------------------------------------------------
void Bot_RunAll( void )
{
if ( !botmanager )
return;
for ( int i = 0; i < s_Bots.Count(); i++ )
{
CPluginBot & bot = s_Bots[i];
if ( bot.m_BotEdict->IsFree() || !bot.m_BotEdict->GetUnknown()|| !bot.m_PlayerInfo->IsConnected() )
{
s_Bots.Remove(i);
--i;
}
else
{
Bot_Think( &bot );
}
}
}
bool Bot_RunMimicCommand( CBotCmd& cmd )
{
if ( bot_mimic.GetInt() <= 0 )
return false;
if ( bot_mimic.GetInt() > gpGlobals->maxClients )
return false;
IPlayerInfo *playerInfo = playerinfomanager->GetPlayerInfo( engine->PEntityOfEntIndex( bot_mimic.GetInt() ) );
if ( !playerInfo )
return false;
cmd = playerInfo->GetLastUserCommand();
cmd.viewangles[YAW] += bot_mimic_yaw_offset.GetFloat();
if( bot_crouch.GetInt() )
cmd.buttons |= IN_DUCK;
return true;
}
void Bot_UpdateStrafing( CPluginBot *pBot, CBotCmd &cmd )
{
if ( gpGlobals->curtime >= pBot->m_flNextStrafeTime )
{
pBot->m_flNextStrafeTime = gpGlobals->curtime + 1.0f;
if ( randomStr->RandomInt( 0, 5 ) == 0 )
{
pBot->m_flSideMove = -600.0f + 1200.0f * randomStr->RandomFloat( 0, 2 );
}
else
{
pBot->m_flSideMove = 0;
}
cmd.sidemove = pBot->m_flSideMove;
if ( randomStr->RandomInt( 0, 20 ) == 0 )
{
pBot->m_bBackwards = true;
}
else
{
pBot->m_bBackwards = false;
}
}
}
void Bot_UpdateDirection( CPluginBot *pBot )
{
float angledelta = 15.0;
int maxtries = static_cast<int>(360.0f / angledelta);
if ( pBot->m_bLastTurnToRight )
{
angledelta = -angledelta;
}
QAngle angle( pBot->m_BotInterface->GetLocalAngles() );
trace_t trace;
Vector vecSrc, vecEnd, forward;
while ( --maxtries >= 0 )
{
AngleVectors( angle, &forward );
vecSrc = pBot->m_BotInterface->GetLocalOrigin() + Vector( 0, 0, 36 );
vecEnd = vecSrc + forward * 10;
Ray_t ray;
ray.Init( vecSrc, vecEnd, Vector(-16, -16, 0 ), Vector( 16, 16, 72 ) );
CTraceFilterWorldAndPropsOnly traceFilter;
enginetrace->TraceRay( ray, MASK_PLAYERSOLID, &traceFilter, &trace );
if ( trace.fraction == 1.0 )
{
if ( gpGlobals->curtime < pBot->m_flNextTurnTime )
{
break;
}
}
angle.y += angledelta;
if ( angle.y > 180 )
angle.y -= 360;
else if ( angle.y < -180 )
angle.y += 360;
pBot->m_flNextTurnTime = gpGlobals->curtime + 2.0;
pBot->m_bLastTurnToRight = randomStr->RandomInt( 0, 1 ) == 0 ? true : false;
pBot->m_ForwardAngle = angle;
pBot->m_LastAngles = angle;
}
pBot->m_BotInterface->SetLocalAngles( angle );
}
void Bot_FlipOut( CPluginBot *pBot, CBotCmd &cmd )
{
if ( bot_flipout.GetInt() > 0 && !pBot->m_PlayerInfo->IsDead() )
{
if ( bot_forceattackon.GetBool() || (RandomFloat(0.0,1.0) > 0.5) )
{
cmd.buttons |= bot_forceattack2.GetBool() ? IN_ATTACK2 : IN_ATTACK;
}
if ( bot_flipout.GetInt() >= 2 )
{
QAngle angOffset = RandomAngle( -1, 1 );
pBot->m_LastAngles += angOffset;
for ( int i = 0 ; i < 2; i++ )
{
if ( fabs( pBot->m_LastAngles[ i ] - pBot->m_ForwardAngle[ i ] ) > 15.0f )
{
if ( pBot->m_LastAngles[ i ] > pBot->m_ForwardAngle[ i ] )
{
pBot->m_LastAngles[ i ] = pBot->m_ForwardAngle[ i ] + 15;
}
else
{
pBot->m_LastAngles[ i ] = pBot->m_ForwardAngle[ i ] - 15;
}
}
}
pBot->m_LastAngles[ 2 ] = 0;
pBot->m_BotInterface->SetLocalAngles( pBot->m_LastAngles );
}
}
}
void Bot_HandleSendCmd( CPluginBot *pBot )
{
if ( strlen( bot_sendcmd.GetString() ) > 0 )
{
//send the cmd from this bot
helpers->ClientCommand( pBot->m_BotEdict, bot_sendcmd.GetString() );
bot_sendcmd.SetValue("");
}
}
// If bots are being forced to fire a weapon, see if I have it
void Bot_ForceFireWeapon( CPluginBot *pBot, CBotCmd &cmd )
{
if ( Q_strlen( bot_forcefireweapon.GetString() ) > 0 )
{
pBot->m_BotInterface->SetActiveWeapon( bot_forcefireweapon.GetString() );
bot_forcefireweapon.SetValue( "" );
// Start firing
// Some weapons require releases, so randomise firing
if ( bot_forceattackon.GetBool() || (RandomFloat(0.0,1.0) > 0.5) )
{
cmd.buttons |= bot_forceattack2.GetBool() ? IN_ATTACK2 : IN_ATTACK;
}
}
}
void Bot_SetForwardMovement( CPluginBot *pBot, CBotCmd &cmd )
{
if ( !pBot->m_BotInterface->IsEFlagSet(EFL_BOT_FROZEN) )
{
if ( pBot->m_PlayerInfo->GetHealth() == 100 )
{
cmd.forwardmove = 600 * ( pBot->m_bBackwards ? -1 : 1 );
if ( pBot->m_flSideMove != 0.0f )
{
cmd.forwardmove *= randomStr->RandomFloat( 0.1, 1.0f );
}
}
else
{
// Stop when shot
cmd.forwardmove = 0;
}
}
}
void Bot_HandleRespawn( CPluginBot *pBot, CBotCmd &cmd )
{
// Wait for Reinforcement wave
if ( pBot->m_PlayerInfo->IsDead() )
{
if ( pBot->m_PlayerInfo->GetTeamIndex() == 0 )
{
helpers->ClientCommand( pBot->m_BotEdict, "joingame" );
helpers->ClientCommand( pBot->m_BotEdict, "jointeam 3" );
helpers->ClientCommand( pBot->m_BotEdict, "joinclass 0" );
}
}
}
//-----------------------------------------------------------------------------
// Run this Bot's AI for one frame.
//-----------------------------------------------------------------------------
void Bot_Think( CPluginBot *pBot )
{
CBotCmd cmd;
Q_memset( &cmd, 0, sizeof( cmd ) );
// Finally, override all this stuff if the bot is being forced to mimic a player.
if ( !Bot_RunMimicCommand( cmd ) )
{
cmd.sidemove = pBot->m_flSideMove;
if ( !pBot->m_PlayerInfo->IsDead() )
{
Bot_SetForwardMovement( pBot, cmd );
// Only turn if I haven't been hurt
if ( !pBot->m_BotInterface->IsEFlagSet(EFL_BOT_FROZEN) && pBot->m_PlayerInfo->GetHealth() == 100 )
{
Bot_UpdateDirection( pBot );
Bot_UpdateStrafing( pBot, cmd );
}
// Handle console settings.
Bot_ForceFireWeapon( pBot, cmd );
Bot_HandleSendCmd( pBot );
}
else
{
Bot_HandleRespawn( pBot, cmd );
}
Bot_FlipOut( pBot, cmd );
cmd.viewangles = pBot->m_BotInterface->GetLocalAngles();
cmd.upmove = 0;
cmd.impulse = 0;
}
pBot->m_BotInterface->RunPlayerMove( &cmd );
}
//========= Copyright Valve Corporation, All rights reserved. ============//
//
// Purpose: Basic BOT handling.
//
// $Workfile: $
// $Date: $
//
//-----------------------------------------------------------------------------
// $Log: $
//
// $NoKeywords: $
//=============================================================================//
#include "interface.h"
#include "filesystem.h"
#undef VECTOR_NO_SLOW_OPERATIONS
#include "mathlib/vector.h"
#include "eiface.h"
#include "edict.h"
#include "game/server/iplayerinfo.h"
#include "igameevents.h"
#include "convar.h"
#include "vstdlib/random.h"
#include "../../game/shared/in_buttons.h"
#include "../../game/shared/shareddefs.h"
//#include "../../game_shared/util_shared.h"
#include "engine/IEngineTrace.h"
extern IBotManager *botmanager;
extern IUniformRandomStream *randomStr;
extern IPlayerInfoManager *playerinfomanager;
extern IVEngineServer *engine;
extern IEngineTrace *enginetrace;
extern IPlayerInfoManager *playerinfomanager; // game dll interface to interact with players
extern IServerPluginHelpers *helpers; // special 3rd party plugin helpers from the engine
extern CGlobalVars *gpGlobals;
ConVar bot_forcefireweapon( "plugin_bot_forcefireweapon", "", 0, "Force bots with the specified weapon to fire." );
ConVar bot_forceattack2( "plugin_bot_forceattack2", "0", 0, "When firing, use attack2." );
ConVar bot_forceattackon( "plugin_bot_forceattackon", "0", 0, "When firing, don't tap fire, hold it down." );
ConVar bot_flipout( "plugin_bot_flipout", "0", 0, "When on, all bots fire their guns." );
ConVar bot_changeclass( "plugin_bot_changeclass", "0", 0, "Force all bots to change to the specified class." );
static ConVar bot_mimic( "plugin_bot_mimic", "0", 0, "Bot uses usercmd of player by index." );
static ConVar bot_mimic_yaw_offset( "plugin_bot_mimic_yaw_offset", "0", 0, "Offsets the bot yaw." );
ConVar bot_sendcmd( "plugin_bot_sendcmd", "", 0, "Forces bots to send the specified command." );
ConVar bot_crouch( "plugin_bot_crouch", "0", 0, "Bot crouches" );
// This is our bot class.
class CPluginBot
{
public:
CPluginBot() :
m_bBackwards(0),
m_flNextTurnTime(0),
m_bLastTurnToRight(0),
m_flNextStrafeTime(0),
m_flSideMove(0),
m_ForwardAngle(),
m_LastAngles()
{
}
bool m_bBackwards;
float m_flNextTurnTime;
bool m_bLastTurnToRight;
float m_flNextStrafeTime;
float m_flSideMove;
QAngle m_ForwardAngle;
QAngle m_LastAngles;
IBotController *m_BotInterface;
IPlayerInfo *m_PlayerInfo;
edict_t *m_BotEdict;
};
CUtlVector<CPluginBot> s_Bots;
void Bot_Think( CPluginBot *pBot );
// Handler for the "bot" command.
void BotAdd_f()
{
if ( !botmanager )
return;
static int s_BotNum = 0;
char botName[64];
Q_snprintf( botName, sizeof(botName), "Bot_%i", s_BotNum );
s_BotNum++;
edict_t *botEdict = botmanager->CreateBot( botName );
if ( botEdict )
{
int botIndex = s_Bots.AddToTail();
CPluginBot & bot = s_Bots[ botIndex ];
bot.m_BotInterface = botmanager->GetBotController( botEdict );
bot.m_PlayerInfo = playerinfomanager->GetPlayerInfo( botEdict );
bot.m_BotEdict = botEdict;
Assert( bot.m_BotInterface );
}
}
ConCommand cc_Bot( "plugin_bot_add", BotAdd_f, "Add a bot." );
//-----------------------------------------------------------------------------
// Purpose: Run through all the Bots in the game and let them think.
//-----------------------------------------------------------------------------
void Bot_RunAll( void )
{
if ( !botmanager )
return;
for ( int i = 0; i < s_Bots.Count(); i++ )
{
CPluginBot & bot = s_Bots[i];
if ( bot.m_BotEdict->IsFree() || !bot.m_BotEdict->GetUnknown()|| !bot.m_PlayerInfo->IsConnected() )
{
s_Bots.Remove(i);
--i;
}
else
{
Bot_Think( &bot );
}
}
}
bool Bot_RunMimicCommand( CBotCmd& cmd )
{
if ( bot_mimic.GetInt() <= 0 )
return false;
if ( bot_mimic.GetInt() > gpGlobals->maxClients )
return false;
IPlayerInfo *playerInfo = playerinfomanager->GetPlayerInfo( engine->PEntityOfEntIndex( bot_mimic.GetInt() ) );
if ( !playerInfo )
return false;
cmd = playerInfo->GetLastUserCommand();
cmd.viewangles[YAW] += bot_mimic_yaw_offset.GetFloat();
if( bot_crouch.GetInt() )
cmd.buttons |= IN_DUCK;
return true;
}
void Bot_UpdateStrafing( CPluginBot *pBot, CBotCmd &cmd )
{
if ( gpGlobals->curtime >= pBot->m_flNextStrafeTime )
{
pBot->m_flNextStrafeTime = gpGlobals->curtime + 1.0f;
if ( randomStr->RandomInt( 0, 5 ) == 0 )
{
pBot->m_flSideMove = -600.0f + 1200.0f * randomStr->RandomFloat( 0, 2 );
}
else
{
pBot->m_flSideMove = 0;
}
cmd.sidemove = pBot->m_flSideMove;
if ( randomStr->RandomInt( 0, 20 ) == 0 )
{
pBot->m_bBackwards = true;
}
else
{
pBot->m_bBackwards = false;
}
}
}
void Bot_UpdateDirection( CPluginBot *pBot )
{
float angledelta = 15.0;
int maxtries = (int)360.0/angledelta;
if ( pBot->m_bLastTurnToRight )
{
angledelta = -angledelta;
}
QAngle angle( pBot->m_BotInterface->GetLocalAngles() );
trace_t trace;
Vector vecSrc, vecEnd, forward;
while ( --maxtries >= 0 )
{
AngleVectors( angle, &forward );
vecSrc = pBot->m_BotInterface->GetLocalOrigin() + Vector( 0, 0, 36 );
vecEnd = vecSrc + forward * 10;
Ray_t ray;
ray.Init( vecSrc, vecEnd, Vector(-16, -16, 0 ), Vector( 16, 16, 72 ) );
CTraceFilterWorldAndPropsOnly traceFilter;
enginetrace->TraceRay( ray, MASK_PLAYERSOLID, &traceFilter, &trace );
if ( trace.fraction == 1.0 )
{
if ( gpGlobals->curtime < pBot->m_flNextTurnTime )
{
break;
}
}
angle.y += angledelta;
if ( angle.y > 180 )
angle.y -= 360;
else if ( angle.y < -180 )
angle.y += 360;
pBot->m_flNextTurnTime = gpGlobals->curtime + 2.0;
pBot->m_bLastTurnToRight = randomStr->RandomInt( 0, 1 ) == 0 ? true : false;
pBot->m_ForwardAngle = angle;
pBot->m_LastAngles = angle;
}
pBot->m_BotInterface->SetLocalAngles( angle );
}
void Bot_FlipOut( CPluginBot *pBot, CBotCmd &cmd )
{
if ( bot_flipout.GetInt() > 0 && !pBot->m_PlayerInfo->IsDead() )
{
if ( bot_forceattackon.GetBool() || (RandomFloat(0.0,1.0) > 0.5) )
{
cmd.buttons |= bot_forceattack2.GetBool() ? IN_ATTACK2 : IN_ATTACK;
}
if ( bot_flipout.GetInt() >= 2 )
{
QAngle angOffset = RandomAngle( -1, 1 );
pBot->m_LastAngles += angOffset;
for ( int i = 0 ; i < 2; i++ )
{
if ( fabs( pBot->m_LastAngles[ i ] - pBot->m_ForwardAngle[ i ] ) > 15.0f )
{
if ( pBot->m_LastAngles[ i ] > pBot->m_ForwardAngle[ i ] )
{
pBot->m_LastAngles[ i ] = pBot->m_ForwardAngle[ i ] + 15;
}
else
{
pBot->m_LastAngles[ i ] = pBot->m_ForwardAngle[ i ] - 15;
}
}
}
pBot->m_LastAngles[ 2 ] = 0;
pBot->m_BotInterface->SetLocalAngles( pBot->m_LastAngles );
}
}
}
void Bot_HandleSendCmd( CPluginBot *pBot )
{
if ( strlen( bot_sendcmd.GetString() ) > 0 )
{
//send the cmd from this bot
helpers->ClientCommand( pBot->m_BotEdict, bot_sendcmd.GetString() );
bot_sendcmd.SetValue("");
}
}
// If bots are being forced to fire a weapon, see if I have it
void Bot_ForceFireWeapon( CPluginBot *pBot, CBotCmd &cmd )
{
if ( Q_strlen( bot_forcefireweapon.GetString() ) > 0 )
{
pBot->m_BotInterface->SetActiveWeapon( bot_forcefireweapon.GetString() );
bot_forcefireweapon.SetValue( "" );
// Start firing
// Some weapons require releases, so randomise firing
if ( bot_forceattackon.GetBool() || (RandomFloat(0.0,1.0) > 0.5) )
{
cmd.buttons |= bot_forceattack2.GetBool() ? IN_ATTACK2 : IN_ATTACK;
}
}
}
void Bot_SetForwardMovement( CPluginBot *pBot, CBotCmd &cmd )
{
if ( !pBot->m_BotInterface->IsEFlagSet(EFL_BOT_FROZEN) )
{
if ( pBot->m_PlayerInfo->GetHealth() == 100 )
{
cmd.forwardmove = 600 * ( pBot->m_bBackwards ? -1 : 1 );
if ( pBot->m_flSideMove != 0.0f )
{
cmd.forwardmove *= randomStr->RandomFloat( 0.1, 1.0f );
}
}
else
{
// Stop when shot
cmd.forwardmove = 0;
}
}
}
void Bot_HandleRespawn( CPluginBot *pBot, CBotCmd &cmd )
{
// Wait for Reinforcement wave
if ( pBot->m_PlayerInfo->IsDead() )
{
if ( pBot->m_PlayerInfo->GetTeamIndex() == 0 )
{
helpers->ClientCommand( pBot->m_BotEdict, "joingame" );
helpers->ClientCommand( pBot->m_BotEdict, "jointeam 3" );
helpers->ClientCommand( pBot->m_BotEdict, "joinclass 0" );
}
}
}
//-----------------------------------------------------------------------------
// Run this Bot's AI for one frame.
//-----------------------------------------------------------------------------
void Bot_Think( CPluginBot *pBot )
{
CBotCmd cmd;
Q_memset( &cmd, 0, sizeof( cmd ) );
// Finally, override all this stuff if the bot is being forced to mimic a player.
if ( !Bot_RunMimicCommand( cmd ) )
{
cmd.sidemove = pBot->m_flSideMove;
if ( !pBot->m_PlayerInfo->IsDead() )
{
Bot_SetForwardMovement( pBot, cmd );
// Only turn if I haven't been hurt
if ( !pBot->m_BotInterface->IsEFlagSet(EFL_BOT_FROZEN) && pBot->m_PlayerInfo->GetHealth() == 100 )
{
Bot_UpdateDirection( pBot );
Bot_UpdateStrafing( pBot, cmd );
}
// Handle console settings.
Bot_ForceFireWeapon( pBot, cmd );
Bot_HandleSendCmd( pBot );
}
else
{
Bot_HandleRespawn( pBot, cmd );
}
Bot_FlipOut( pBot, cmd );
cmd.viewangles = pBot->m_BotInterface->GetLocalAngles();
cmd.upmove = 0;
cmd.impulse = 0;
}
pBot->m_BotInterface->RunPlayerMove( &cmd );
}
@@ -1,383 +0,0 @@
<?xml version="1.0" encoding="Windows-1252"?>
<VisualStudioProject
ProjectType="Visual C++"
Version="8.00"
Name="Serverplugin_empty"
ProjectGUID="{B6572CBE-7C7F-4FFF-94DE-AFBBBAB11C64}"
RootNamespace="Serverplugin_empty"
>
<Platforms>
<Platform
Name="Win32"
/>
</Platforms>
<ToolFiles>
</ToolFiles>
<Configurations>
<Configuration
Name="Debug|Win32"
OutputDirectory=".\Debug"
IntermediateDirectory=".\Debug"
ConfigurationType="2"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
CommandLine=""
ExcludedFromBuild="false"
/>
<Tool
Name="VCCustomBuildTool"
CommandLine="if exist ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll attrib -r ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll&#x0D;&#x0A;if exist ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb attrib -r ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb&#x0D;&#x0A;"
Outputs="..\..\..\game\bin\serverplugin_empty.dll;..\..\..\game\bin\serverplugin_empty.pdb"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="0"
AdditionalIncludeDirectories="..\..\common;..\..\public;..\..\public\tier0;..\..\public\tier1,..\..\game\server,..\..\game\shared"
PreprocessorDefinitions="WIN32;_WIN32;_DEBUG;DEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;serverplugin_emptyONLY;_MBCS"
StringPooling="true"
MinimalRebuild="true"
ExceptionHandling="0"
BasicRuntimeChecks="3"
RuntimeLibrary="1"
BufferSecurityCheck="false"
FloatingPointModel="2"
ForceConformanceInForLoopScope="true"
RuntimeTypeInfo="true"
UsePrecompiledHeader="0"
AssemblerListingLocation="$(IntDir)/"
ObjectFile="$(IntDir)/"
ProgramDataBaseFileName="$(IntDir)/"
GenerateXMLDocumentationFiles="false"
BrowseInformation="0"
BrowseInformationFile="$(IntDir)/"
WarningLevel="4"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="4"
CompileAs="2"
ErrorReporting="1"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="_DEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE"
Culture="1033"
/>
<Tool
Name="VCPreLinkEventTool"
ExcludedFromBuild="false"
/>
<Tool
Name="VCLinkerTool"
UseUnicodeResponseFiles="false"
AdditionalDependencies="odbc32.lib odbccp32.lib"
ShowProgress="0"
OutputFile="$(OutDir)/serverplugin_empty.dll"
LinkIncremental="2"
SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\lib\common;..\..\lib\public"
GenerateManifest="false"
IgnoreDefaultLibraryNames="libc;libcd;libcmt"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(IntDir)/$(TargetName).pdb"
GenerateMapFile="true"
MapFileName="$(IntDir)/$(TargetName).map"
SubSystem="2"
BaseAddress=" "
TargetMachine="1"
ErrorReporting="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
SuppressStartupBanner="true"
/>
<Tool
Name="VCXDCMakeTool"
SuppressStartupBanner="true"
/>
<Tool
Name="VCBscMakeTool"
SuppressStartupBanner="true"
OutputFile="$(OutDir)/serverplugin_empty.bsc"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
CommandLine=""
ExcludedFromBuild="false"
/>
</Configuration>
<Configuration
Name="Release|Win32"
OutputDirectory=".\Release"
IntermediateDirectory=".\Release"
ConfigurationType="2"
CharacterSet="2"
>
<Tool
Name="VCPreBuildEventTool"
CommandLine=""
ExcludedFromBuild="false"
/>
<Tool
Name="VCCustomBuildTool"
CommandLine="if exist ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll attrib -r ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; ..\..\..\game\bin\&quot;$(TargetName)&quot;.dll&#x0D;&#x0A;if exist ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb attrib -r ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb&#x0D;&#x0A;copy &quot;$(TargetPath)&quot; ..\..\..\game\bin\&quot;$(TargetName)&quot;.pdb&#x0D;&#x0A;"
Outputs="..\..\..\game\bin\serverplugin_empty.dll;..\..\..\game\bin\serverplugin_empty.pdb"
/>
<Tool
Name="VCXMLDataGeneratorTool"
/>
<Tool
Name="VCWebServiceProxyGeneratorTool"
/>
<Tool
Name="VCMIDLTool"
/>
<Tool
Name="VCCLCompilerTool"
Optimization="2"
InlineFunctionExpansion="2"
EnableIntrinsicFunctions="true"
FavorSizeOrSpeed="1"
AdditionalIncludeDirectories="..\..\common;..\..\public;..\..\public\tier0;..\..\public\tier1,..\..\game\server,..\..\game\shared"
PreprocessorDefinitions="WIN32;_WIN32;NDEBUG;_WINDOWS;_USRDLL;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE;serverplugin_emptyONLY;_MBCS"
StringPooling="true"
ExceptionHandling="0"
RuntimeLibrary="0"
BufferSecurityCheck="false"
EnableFunctionLevelLinking="true"
FloatingPointModel="2"
ForceConformanceInForLoopScope="true"
RuntimeTypeInfo="true"
UsePrecompiledHeader="0"
AssemblerListingLocation="$(IntDir)/"
ObjectFile="$(IntDir)/"
ProgramDataBaseFileName="$(IntDir)/"
GenerateXMLDocumentationFiles="false"
BrowseInformation="0"
BrowseInformationFile="$(IntDir)/"
WarningLevel="4"
Detect64BitPortabilityProblems="true"
DebugInformationFormat="3"
CompileAs="2"
ErrorReporting="1"
/>
<Tool
Name="VCManagedResourceCompilerTool"
/>
<Tool
Name="VCResourceCompilerTool"
PreprocessorDefinitions="NDEBUG;_CRT_SECURE_NO_DEPRECATE;_CRT_NONSTDC_NO_DEPRECATE"
Culture="1033"
/>
<Tool
Name="VCPreLinkEventTool"
ExcludedFromBuild="false"
/>
<Tool
Name="VCLinkerTool"
UseUnicodeResponseFiles="false"
AdditionalDependencies="odbc32.lib odbccp32.lib"
ShowProgress="0"
OutputFile="$(OutDir)/serverplugin_empty.dll"
LinkIncremental="1"
SuppressStartupBanner="true"
AdditionalLibraryDirectories="..\..\lib\common;..\..\lib\public"
GenerateManifest="false"
IgnoreDefaultLibraryNames="libc;libcd;libcmtd"
GenerateDebugInformation="true"
ProgramDatabaseFile="$(IntDir)/$(TargetName).pdb"
GenerateMapFile="true"
MapFileName="$(IntDir)/$(TargetName).map"
SubSystem="2"
OptimizeReferences="2"
EnableCOMDATFolding="2"
BaseAddress=" "
TargetMachine="1"
ErrorReporting="1"
/>
<Tool
Name="VCALinkTool"
/>
<Tool
Name="VCManifestTool"
SuppressStartupBanner="true"
/>
<Tool
Name="VCXDCMakeTool"
SuppressStartupBanner="true"
/>
<Tool
Name="VCBscMakeTool"
SuppressStartupBanner="true"
OutputFile="$(OutDir)/serverplugin_empty.bsc"
/>
<Tool
Name="VCFxCopTool"
/>
<Tool
Name="VCAppVerifierTool"
/>
<Tool
Name="VCWebDeploymentTool"
/>
<Tool
Name="VCPostBuildEventTool"
CommandLine=""
ExcludedFromBuild="false"
/>
</Configuration>
</Configurations>
<References>
</References>
<Files>
<Filter
Name="Source Files"
Filter="cpp;c;cxx;rc;def;r;odl;idl;hpj;bat"
>
<File
RelativePath="..\..\public\tier0\memoverride.cpp"
>
</File>
<File
RelativePath=".\serverplugin_bot.cpp"
>
</File>
<File
RelativePath=".\serverplugin_empty.cpp"
>
</File>
</Filter>
<Filter
Name="Link Libraries"
Filter="lib"
>
<File
RelativePath="..\..\lib\public\mathlib.lib"
>
</File>
<File
RelativePath="..\..\lib\public\tier0.lib"
>
</File>
<File
RelativePath="..\..\lib\public\tier1.lib"
>
</File>
<File
RelativePath="..\..\lib\public\tier2.lib"
>
</File>
<File
RelativePath="..\..\lib\public\vstdlib.lib"
>
</File>
</Filter>
<Filter
Name="Header Files"
Filter="h;hpp;hxx;hm;inl"
>
<File
RelativePath="..\..\public\tier0\basetypes.h"
>
</File>
<File
RelativePath="..\..\public\Color.h"
>
</File>
<File
RelativePath="..\..\public\tier0\dbg.h"
>
</File>
<File
RelativePath="..\..\public\eiface.h"
>
</File>
<File
RelativePath="..\..\public\filesystem.h"
>
</File>
<File
RelativePath="..\..\public\vstdlib\ICommandLine.h"
>
</File>
<File
RelativePath="..\..\public\igameevents.h"
>
</File>
<File
RelativePath="..\..\public\tier1\interface.h"
>
</File>
<File
RelativePath="..\..\public\game\server\iplayerinfo.h"
>
</File>
<File
RelativePath="..\..\public\engine\iserverplugin.h"
>
</File>
<File
RelativePath="..\..\public\tier1\KeyValues.h"
>
</File>
<File
RelativePath="..\..\public\tier0\mem.h"
>
</File>
<File
RelativePath="..\..\public\tier0\memalloc.h"
>
</File>
<File
RelativePath="..\..\public\tier0\memdbgon.h"
>
</File>
<File
RelativePath="..\..\public\vstdlib\strtools.h"
>
</File>
<File
RelativePath="..\..\public\tier1\utlbuffer.h"
>
</File>
<File
RelativePath="..\..\public\tier1\utlmemory.h"
>
</File>
<File
RelativePath="..\..\public\tier1\utlvector.h"
>
</File>
<File
RelativePath="..\..\public\vstdlib\vstdlib.h"
>
</File>
</Filter>
</Files>
<Globals>
</Globals>
</VisualStudioProject>
File diff suppressed because it is too large. Load diff
@@ -0,0 +1,62 @@
//-----------------------------------------------------------------------------
// SERVERPLUGIN_EMPTY.VPC
//
// Project Script
//-----------------------------------------------------------------------------
$Macro SRCDIR "..\.."
$Macro OUTBINDIR "$SRCDIR\..\game\bin"
$Include "$SRCDIR\vpc_scripts\source_dll_base.vpc"
$Configuration
{
$Compiler
{
$AdditionalIncludeDirectories "$BASE,$SRCDIR\game\server,$SRCDIR\game\shared"
$PreprocessorDefinitions "$BASE;serverplugin_emptyONLY;_MBCS"
}
$Linker
{
$AdditionalDependencies "$BASE odbc32.lib odbccp32.lib"
}
}
$Project "Server Plugin (Empty)"
{
$Folder "Source Files"
{
$File "serverplugin_bot.cpp"
$File "serverplugin_empty.cpp"
}
$Folder "Header Files"
{
$File "$SRCDIR\public\tier0\basetypes.h"
$File "$SRCDIR\public\Color.h"
$File "$SRCDIR\public\tier0\dbg.h"
$File "$SRCDIR\public\eiface.h"
$File "$SRCDIR\public\filesystem.h"
$File "$SRCDIR\public\tier0\icommandline.h"
$File "$SRCDIR\public\igameevents.h"
$File "$SRCDIR\public\tier1\interface.h"
$File "$SRCDIR\public\game\server\iplayerinfo.h"
$File "$SRCDIR\public\engine\iserverplugin.h"
$File "$SRCDIR\public\tier1\KeyValues.h"
$File "$SRCDIR\public\tier0\mem.h"
$File "$SRCDIR\public\tier0\memalloc.h"
$File "$SRCDIR\public\tier0\memdbgon.h"
$File "$SRCDIR\public\tier1\strtools.h"
$File "$SRCDIR\public\tier1\utlbuffer.h"
$File "$SRCDIR\public\tier1\utlmemory.h"
$File "$SRCDIR\public\tier1\utlvector.h"
$File "$SRCDIR\public\vstdlib\vstdlib.h"
}
$Folder "Link Libraries"
{
$Lib mathlib
$Lib tier2
}
}