mirror of
https://github.com/openmoh/openmohaa.git
synced 2025-05-08 19:48:08 +03:00
If the actor is an american, always call ThinkHoldGun_TurretGun() without checking for enemy
This commit is contained in:
parent
4b05c400b2
commit
ac8c18250d
1 changed files with 11 additions and 2 deletions
|
@ -89,10 +89,13 @@ void Actor::End_MachineGunner(void)
|
||||||
}
|
}
|
||||||
|
|
||||||
Unholster();
|
Unholster();
|
||||||
if (m_pTurret && m_pTurret->GetOwner() == this) {
|
if (m_pTurret) {
|
||||||
|
m_pTurret->m_bHadOwner = true;
|
||||||
|
if (m_pTurret->GetOwner() == this) {
|
||||||
m_pTurret->TurretEndUsed();
|
m_pTurret->TurretEndUsed();
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void Actor::ThinkHoldGun_TurretGun(void)
|
void Actor::ThinkHoldGun_TurretGun(void)
|
||||||
{
|
{
|
||||||
|
@ -207,6 +210,12 @@ void Actor::Think_MachineGunner_TurretGun(void)
|
||||||
|
|
||||||
UpdateEnemyInternal();
|
UpdateEnemyInternal();
|
||||||
|
|
||||||
|
if (m_Team == TEAM_AMERICAN) {
|
||||||
|
// Added in 2.30
|
||||||
|
ThinkHoldGun_TurretGun();
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
|
||||||
if (m_pTurret->AI_CanTarget(G_GetEntity(0)->centroid)) {
|
if (m_pTurret->AI_CanTarget(G_GetEntity(0)->centroid)) {
|
||||||
ThinkHoldGun_TurretGun();
|
ThinkHoldGun_TurretGun();
|
||||||
return;
|
return;
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue