Dragging - Minor optimisation (#9679)

Minor optimisation for dragging
This commit is contained in:
johnb432 2023-12-18 18:02:45 +01:00 committed by GitHub
parent 1b6b0aaf0b
commit e8c10f905e
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -33,7 +33,7 @@ if (_target isKindOf "StaticWeapon") exitWith {
// Units need to be unconscious or limping; Units also need to not be in ragdoll, as that causes desync issues
if (_target isKindOf "CAManBase") exitWith {
!(alive _target != isAwake _target) &&
isAwake _target && // not ragdolled
{lifeState _target == "INCAPACITATED" ||
{_target getHitPointDamage "HitLegs" >= 0.5}}
};

View File

@ -29,7 +29,7 @@ if (_target isKindOf "StaticWeapon") exitWith {
// Units need to be unconscious or limping; Units also need to not be in ragdoll, as that causes desync issues
if (_target isKindOf "CAManBase") exitWith {
!(alive _target != isAwake _target) &&
isAwake _target && // not ragdolled
{lifeState _target == "INCAPACITATED" ||
{_target getHitPointDamage "HitLegs" >= 0.5}}
};