1
0
mirror of https://github.com/alliedmodders/metamod-source.git synced 2025-01-19 08:52:34 +01:00

Added support for Bloody Good Time (bug 4784, r=DS).

This commit is contained in:
Nicholas Hastings 2011-01-10 14:09:50 -05:00
parent 9e5c7d9c91
commit bb3fd3ea2d
6 changed files with 25 additions and 7 deletions

View File

@ -13,16 +13,18 @@ class MMS:
'name': 'EPISODEONE', 'platform': ['windows', 'linux']}
self.sdkInfo['ep2'] = {'sdk': 'HL2SDKOB', 'ext': '2.ep2', 'def': '3',
'name': 'ORANGEBOX', 'platform': ['windows', 'linux']}
self.sdkInfo['ep2v'] = {'sdk': 'HL2SDKOBVALVE', 'ext': '2.ep2v', 'def': '4',
self.sdkInfo['ep2v'] = {'sdk': 'HL2SDKOBVALVE', 'ext': '2.ep2v', 'def': '5',
'name': 'ORANGEBOXVALVE', 'platform': ['windows', 'linux', 'darwin']}
self.sdkInfo['l4d'] = {'sdk': 'HL2SDKL4D', 'ext': '2.l4d', 'def': '5',
self.sdkInfo['l4d'] = {'sdk': 'HL2SDKL4D', 'ext': '2.l4d', 'def': '6',
'name': 'LEFT4DEAD', 'platform': ['windows', 'linux', 'darwin']}
self.sdkInfo['l4d2'] = {'sdk': 'HL2SDKL4D2', 'ext': '2.l4d2', 'def': '6',
self.sdkInfo['l4d2'] = {'sdk': 'HL2SDKL4D2', 'ext': '2.l4d2', 'def': '7',
'name': 'LEFT4DEAD2', 'platform': ['windows', 'linux', 'darwin']}
self.sdkInfo['darkm'] = {'sdk': 'HL2SDK-DARKM', 'ext': '2.darkm', 'def': '2',
'name': 'DARKMESSIAH', 'platform': ['windows']}
self.sdkInfo['swarm'] = {'sdk': 'HL2SDK-SWARM', 'ext': '2.swarm', 'def': '7',
self.sdkInfo['swarm'] = {'sdk': 'HL2SDK-SWARM', 'ext': '2.swarm', 'def': '8',
'name': 'ALIENSWARM', 'platform': ['windows']}
self.sdkInfo['bgt'] = {'sdk': 'HL2SDK-BGT', 'ext': '2.bgt', 'def': '4',
'name': 'BLOODYGOODTIME', 'platform': ['windows']}
if AMBuild.mode == 'config':
#Detect compilers
@ -42,6 +44,7 @@ class MMS:
if AMBuild.target['platform'] == 'windows':
envvars['HL2SDK-DARKM'] = 'hl2sdk-darkm'
envvars['HL2SDK-SWARM'] = 'hl2sdk-swarm'
envvars['HL2SDK-BGT'] = 'hl2sdk-bgt'
#Must have a path for each envvar (file a bug if you don't like this)
for i in envvars:

View File

@ -44,6 +44,7 @@
#define SOURCE_ENGINE_ORANGEBOXVALVE 6 /**< Orange Box Source Engine for Valve games (TF2/DOD:S) */
#define SOURCE_ENGINE_LEFT4DEAD2 7 /**< Left 4 Dead 2 */
#define SOURCE_ENGINE_ALIENSWARM 8 /**< Alien Swarm */
#define SOURCE_ENGINE_BLOODYGOODTIME 9 /**< Bloody Good Time */
#define METAMOD_PLAPI_VERSION 15 /**< Version of this header file */
#define METAMOD_PLAPI_NAME "ISmmPlugin" /**< Name of the plugin interface */

View File

@ -111,7 +111,9 @@ bool Command_Meta(IMetamodSourceCommandInfo *info)
}
#endif
#if SOURCE_ENGINE == SE_ALIENSWARM
#if SOURCE_ENGINE == SE_BLOODYGOODTIME
CONMSG(" Engine: Bloody Good Time (2010)\n");
#elif SOURCE_ENGINE == SE_ALIENSWARM
CONMSG(" Engine: Alien Swarm (2010)\n");
#elif SOURCE_ENGINE == SE_LEFT4DEAD2
CONMSG(" Engine: Left 4 Dead 2 (2009)\n");

View File

@ -358,7 +358,9 @@ const char *BaseProvider::GetGameDescription()
int BaseProvider::DetermineSourceEngine(const char *game)
{
#if SOURCE_ENGINE == SE_ALIENSWARM
#if SOURCE_ENGINE == SE_BLOODYGOODTIME
return SOURCE_ENGINE_BLOODYGOODTIME;
#elif SOURCE_ENGINE == SE_ALIENSWARM
return SOURCE_ENGINE_ALIENSWARM;
#elif SOURCE_ENGINE == SE_LEFT4DEAD2
return SOURCE_ENGINE_LEFT4DEAD2;

View File

@ -73,6 +73,7 @@ static const char *backend_names[] =
"1.ep1",
"2.darkm",
"2.ep2",
"2.bgt",
"2.ep2v",
"2.l4d",
"2.l4d2",
@ -285,7 +286,15 @@ mm_DetermineBackend(QueryValveInterface engineFactory, const char *game_name)
{
if (engineFactory("VModelInfoServer002", NULL) != NULL)
{
return MMBackend_Episode2;
/* BGT has same iface version numbers and libs as ep2 */
if (strcmp(game_name, "pm") == 0)
{
return MMBackend_BloodyGoodTime;
}
else
{
return MMBackend_Episode2;
}
}
else if (engineFactory("VModelInfoServer003", NULL) != NULL)
{

View File

@ -83,6 +83,7 @@ enum MetamodBackend
MMBackend_Episode1 = 0,
MMBackend_DarkMessiah,
MMBackend_Episode2,
MMBackend_BloodyGoodTime,
MMBackend_Episode2Valve,
MMBackend_Left4Dead,
MMBackend_Left4Dead2,