mirror of
https://github.com/ZDoom/Raze.git
synced 2024-11-22 12:11:17 +00:00
use a feature flag for the enemy attacks in 3 callback functions.
This is simple enough to handle without gModernMap
This commit is contained in:
parent
11caee7477
commit
40ca77c6b5
4 changed files with 6 additions and 3 deletions
|
@ -160,7 +160,8 @@ void BlastSSeqCallback(int, DBloodActor* actor)
|
|||
}
|
||||
}
|
||||
// allow to fire missile in non-player targets
|
||||
if (target->IsPlayerActor() || gModernMap) {
|
||||
if (target->IsPlayerActor() || currentLevel->featureflags & kFeatureEnemyAttacks)
|
||||
{
|
||||
actFireMissile(actor, -7.5, 0, Aim, kMissileArcGargoyle);
|
||||
actFireMissile(actor, 7.5, 0, Aim, kMissileArcGargoyle);
|
||||
}
|
||||
|
|
|
@ -147,7 +147,8 @@ void ghostBlastSeqCallback(int, DBloodActor* actor)
|
|||
}
|
||||
}
|
||||
// allow fire missile in non-player targets if not a demo
|
||||
if (target->IsPlayerActor() || gModernMap) {
|
||||
if (target->IsPlayerActor() || currentLevel->featureflags & kFeatureEnemyAttacks)
|
||||
{
|
||||
sfxPlay3DSound(actor, 489, 0, 0);
|
||||
actFireMissile(actor, 0, 0, Aim, kMissileEctoSkull);
|
||||
}
|
||||
|
|
|
@ -52,7 +52,7 @@ void houndBiteSeqCallback(int, DBloodActor* actor)
|
|||
if (!actor->ValidateTarget(__FUNCTION__)) return;
|
||||
auto target = actor->GetTarget();
|
||||
DVector3 vec(actor->spr.Angles.Yaw.ToVector() * 64, target->spr.pos.Z - actor->spr.pos.Z);
|
||||
if (target->IsPlayerActor() || gModernMap) // allow to hit non-player targets
|
||||
if (target->IsPlayerActor() || currentLevel->featureflags & kFeatureEnemyAttacks)
|
||||
actFireVector(actor, 0, 0, vec, kVectorHoundBite);
|
||||
}
|
||||
|
||||
|
|
|
@ -62,6 +62,7 @@ BEGIN_BLD_NS
|
|||
enum EFeatureFlags
|
||||
{
|
||||
kFeatureCustomAmmoCount = 1,
|
||||
kFeatureEnemyAttacks = 2,
|
||||
};
|
||||
|
||||
constexpr int BMAX_PATH = 260;
|
||||
|
|
Loading…
Reference in a new issue