mirror of
https://github.com/ddnet/ddnet.git
synced 2024-11-10 10:08:18 +00:00
Fix project tile
This commit is contained in:
parent
e3fb77f444
commit
002cf9792f
|
@ -1,5 +1,9 @@
|
|||
#include "gamecontext.h"
|
||||
|
||||
#include <engine/shared/config.h>
|
||||
#include <engine/server/server.h>
|
||||
#include <game/server/teams.h>
|
||||
#include <game/server/gamemodes/DDRace.h>
|
||||
#include <game/version.h>
|
||||
|
||||
void CGameContext::ConTuneParam(IConsole::IResult *pResult, void *pUserData, int ClientId)
|
||||
{
|
||||
|
|
|
@ -118,7 +118,7 @@ void CProjectile::Tick()
|
|||
{
|
||||
if(m_Explosive/*??*/ && (!TargetChr || (TargetChr && !m_Freeze)))
|
||||
{
|
||||
GameServer()->CreateExplosion(ColPos, m_Owner, m_Weapon, m_Owner == -1, TargetChr->Team(),
|
||||
GameServer()->CreateExplosion(ColPos, m_Owner, m_Weapon, m_Owner == -1, (TargetChr ? -1 : TargetChr->Team()),
|
||||
(m_Owner != -1)? TeamMask : -1);
|
||||
GameServer()->CreateSound(ColPos, m_SoundImpact,
|
||||
(m_Owner != -1)? TeamMask : -1);
|
||||
|
|
|
@ -150,7 +150,7 @@ void CGameContext::CreateExplosion(vec2 P, int Owner, int Weapon, bool NoDamage,
|
|||
if((g_Config.m_SvHit||NoDamage) || Owner == apEnts[i]->m_pPlayer->GetCID())
|
||||
{
|
||||
if(Owner != -1 && apEnts[i]->m_Alive && !apEnts[i]->CanCollide(Owner)) continue;
|
||||
if(Owner == -1 && apEnts[i]->m_Alive && apEnts[i]->Team() != ActivatedTeam) continue;
|
||||
if(Owner == -1 && ActivatedTeam != -1 && apEnts[i]->m_Alive && apEnts[i]->Team() != ActivatedTeam) continue;
|
||||
apEnts[i]->TakeDamage(ForceDir*Dmg*2, (int)Dmg, Owner, Weapon);
|
||||
if(!g_Config.m_SvHit||NoDamage) break;
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue