mirror of
https://github.com/YGGverse/hlsdk-portable.git
synced 2025-01-23 13:14:51 +00:00
Merge branch 'master' into opfor
This commit is contained in:
commit
51f214fb02
@ -212,7 +212,7 @@ void CHGrunt::GibMonster( void )
|
|||||||
Vector vecGunPos;
|
Vector vecGunPos;
|
||||||
Vector vecGunAngles;
|
Vector vecGunAngles;
|
||||||
|
|
||||||
if( GetBodygroup( 2 ) != 2 )
|
if( GetBodygroup( GUN_GROUP ) != GUN_NONE )
|
||||||
{
|
{
|
||||||
// throw a gun if the grunt has one
|
// throw a gun if the grunt has one
|
||||||
GetAttachment( 0, vecGunPos, vecGunAngles );
|
GetAttachment( 0, vecGunPos, vecGunAngles );
|
||||||
@ -543,7 +543,7 @@ void CHGrunt::TraceAttack( entvars_t *pevAttacker, float flDamage, Vector vecDir
|
|||||||
if( ptr->iHitgroup == 11 )
|
if( ptr->iHitgroup == 11 )
|
||||||
{
|
{
|
||||||
// make sure we're wearing one
|
// make sure we're wearing one
|
||||||
if( GetBodygroup( 1 ) == HEAD_GRUNT && ( bitsDamageType & (DMG_BULLET | DMG_SLASH | DMG_BLAST | DMG_CLUB ) ) )
|
if( GetBodygroup( HEAD_GROUP ) == HEAD_GRUNT && ( bitsDamageType & (DMG_BULLET | DMG_SLASH | DMG_BLAST | DMG_CLUB ) ) )
|
||||||
{
|
{
|
||||||
// absorb damage
|
// absorb damage
|
||||||
flDamage -= 20;
|
flDamage -= 20;
|
||||||
@ -788,27 +788,30 @@ void CHGrunt::HandleAnimEvent( MonsterEvent_t *pEvent )
|
|||||||
{
|
{
|
||||||
case HGRUNT_AE_DROP_GUN:
|
case HGRUNT_AE_DROP_GUN:
|
||||||
{
|
{
|
||||||
Vector vecGunPos;
|
if ( GetBodygroup( GUN_GROUP ) != GUN_NONE )
|
||||||
Vector vecGunAngles;
|
|
||||||
|
|
||||||
GetAttachment( 0, vecGunPos, vecGunAngles );
|
|
||||||
|
|
||||||
// switch to body group with no gun.
|
|
||||||
SetBodygroup( GUN_GROUP, GUN_NONE );
|
|
||||||
|
|
||||||
// now spawn a gun.
|
|
||||||
if( FBitSet( pev->weapons, HGRUNT_SHOTGUN ) )
|
|
||||||
{
|
{
|
||||||
DropItem( "weapon_shotgun", vecGunPos, vecGunAngles );
|
Vector vecGunPos;
|
||||||
}
|
Vector vecGunAngles;
|
||||||
else
|
|
||||||
{
|
|
||||||
DropItem( "weapon_9mmAR", vecGunPos, vecGunAngles );
|
|
||||||
}
|
|
||||||
|
|
||||||
if( FBitSet( pev->weapons, HGRUNT_GRENADELAUNCHER ) )
|
GetAttachment( 0, vecGunPos, vecGunAngles );
|
||||||
{
|
|
||||||
DropItem( "ammo_ARgrenades", BodyTarget( pev->origin ), vecGunAngles );
|
// switch to body group with no gun.
|
||||||
|
SetBodygroup( GUN_GROUP, GUN_NONE );
|
||||||
|
|
||||||
|
// now spawn a gun.
|
||||||
|
if( FBitSet( pev->weapons, HGRUNT_SHOTGUN ) )
|
||||||
|
{
|
||||||
|
DropItem( "weapon_shotgun", vecGunPos, vecGunAngles );
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
DropItem( "weapon_9mmAR", vecGunPos, vecGunAngles );
|
||||||
|
}
|
||||||
|
|
||||||
|
if( FBitSet( pev->weapons, HGRUNT_GRENADELAUNCHER ) )
|
||||||
|
{
|
||||||
|
DropItem( "ammo_ARgrenades", BodyTarget( pev->origin ), vecGunAngles );
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
break;
|
break;
|
||||||
|
@ -20,7 +20,7 @@ def configure(conf):
|
|||||||
conf.fatal("Could not find hl.def")
|
conf.fatal("Could not find hl.def")
|
||||||
|
|
||||||
def build(bld):
|
def build(bld):
|
||||||
excluded_files = ['mpstubb.cpp', 'stats.cpp', 'prop.cpp', 'Wxdebug.cpp', 'gearbox/gearbox_client.cpp']
|
excluded_files = ['mpstubb.cpp', 'stats.cpp', 'Wxdebug.cpp', 'gearbox/gearbox_client.cpp']
|
||||||
|
|
||||||
source = bld.path.ant_glob('**/*.cpp', excl=excluded_files)
|
source = bld.path.ant_glob('**/*.cpp', excl=excluded_files)
|
||||||
source += bld.path.parent.ant_glob('pm_shared/*.c')
|
source += bld.path.parent.ant_glob('pm_shared/*.c')
|
||||||
|
6
wscript
6
wscript
@ -10,6 +10,7 @@ import re
|
|||||||
VERSION = '2.4'
|
VERSION = '2.4'
|
||||||
APPNAME = 'hlsdk-portable'
|
APPNAME = 'hlsdk-portable'
|
||||||
top = '.'
|
top = '.'
|
||||||
|
default_prefix = '/'
|
||||||
|
|
||||||
Context.Context.line_just = 60 # should fit for everything on 80x26
|
Context.Context.line_just = 60 # should fit for everything on 80x26
|
||||||
|
|
||||||
@ -21,7 +22,7 @@ def get_taskgen_count(self):
|
|||||||
|
|
||||||
def options(opt):
|
def options(opt):
|
||||||
opt.load('reconfigure compiler_optimizations xcompile compiler_cxx compiler_c clang_compilation_database strip_on_install msdev msvs msvc subproject')
|
opt.load('reconfigure compiler_optimizations xcompile compiler_cxx compiler_c clang_compilation_database strip_on_install msdev msvs msvc subproject')
|
||||||
|
|
||||||
grp = opt.add_option_group('Common options')
|
grp = opt.add_option_group('Common options')
|
||||||
|
|
||||||
grp.add_option('-8', '--64bits', action = 'store_true', dest = 'ALLOW64', default = False,
|
grp.add_option('-8', '--64bits', action = 'store_true', dest = 'ALLOW64', default = False,
|
||||||
@ -238,6 +239,9 @@ def configure(conf):
|
|||||||
conf.add_subproject('cl_dll')
|
conf.add_subproject('cl_dll')
|
||||||
|
|
||||||
def build(bld):
|
def build(bld):
|
||||||
|
if bld.is_install and not bld.options.destdir:
|
||||||
|
bld.fatal('Set the install destination directory using --destdir option')
|
||||||
|
|
||||||
# don't clean QtCreator files and reconfigure saved options
|
# don't clean QtCreator files and reconfigure saved options
|
||||||
bld.clean_files = bld.bldnode.ant_glob('**',
|
bld.clean_files = bld.bldnode.ant_glob('**',
|
||||||
excl='*.user configuration.py .lock* *conf_check_*/** config.log %s/*' % Build.CACHE_DIR,
|
excl='*.user configuration.py .lock* *conf_check_*/** config.log %s/*' % Build.CACHE_DIR,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user