Make aiMaxDeviation only supported on 2.0 and above

This commit is contained in:
smallmodel 2024-02-15 00:21:01 +01:00
parent efc1354dcb
commit abfdac59ba
No known key found for this signature in database
GPG key ID: 9F2D623CEDF08512

View file

@ -10150,12 +10150,14 @@ Vector Actor::GunTarget(bool bNoCollision, const vec3_t position, const vec3_t f
Vector dir = mTargetPos - EyePosition();
dir.normalize();
if (DotProduct2D(forward, dir) < aiMaxDeviation->value) {
Vector vOut;
if (g_target_game > target_game_e::TG_MOH) {
if (DotProduct2D(forward, dir) < aiMaxDeviation->value) {
Vector vOut;
VectorMA(position, 2048, forward, vOut);
VectorMA(position, 2048, forward, vOut);
return vOut;
return vOut;
}
}
if (mTargetPos == vec_zero) {