mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-19 14:38:18 +00:00
Fix freeze projectiles only hit one tee (Fixes #1759)
This commit is contained in:
parent
39303e3430
commit
bbbdd89e64
|
@ -168,8 +168,14 @@ void CProjectile::Tick()
|
||||||
(m_Owner != -1)? TeamMask : -1LL);
|
(m_Owner != -1)? TeamMask : -1LL);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if(pTargetChr && m_Freeze && ((m_Layer == LAYER_SWITCH && GameServer()->Collision()->m_pSwitchers[m_Number].m_Status[pTargetChr->Team()]) || m_Layer != LAYER_SWITCH))
|
else if(m_Freeze)
|
||||||
pTargetChr->Freeze();
|
{
|
||||||
|
CCharacter *apEnts[MAX_CLIENTS];
|
||||||
|
int Num = GameWorld()->FindEntities(CurPos, 1.0f, (CEntity**)apEnts, MAX_CLIENTS, CGameWorld::ENTTYPE_CHARACTER);
|
||||||
|
for (int i = 0; i < Num; ++i)
|
||||||
|
if (apEnts[i] && (m_Layer != LAYER_SWITCH || (m_Layer == LAYER_SWITCH && GameServer()->Collision()->m_pSwitchers[m_Number].m_Status[pTargetChr->Team()])))
|
||||||
|
apEnts[i]->Freeze();
|
||||||
|
}
|
||||||
|
|
||||||
if (pOwnerChar && ColPos && !GameLayerClipped(ColPos) &&
|
if (pOwnerChar && ColPos && !GameLayerClipped(ColPos) &&
|
||||||
((m_Type == WEAPON_GRENADE && pOwnerChar->m_HasTeleGrenade) || (m_Type == WEAPON_GUN && pOwnerChar->m_HasTeleGun)))
|
((m_Type == WEAPON_GRENADE && pOwnerChar->m_HasTeleGrenade) || (m_Type == WEAPON_GUN && pOwnerChar->m_HasTeleGun)))
|
||||||
|
|
Loading…
Reference in a new issue