diff options
| author | Teetime <TeetimeTW@yahoo.de> | 2012-02-18 16:55:57 +0100 |
|---|---|---|
| committer | Teetime <TeetimeTW@yahoo.de> | 2012-02-18 16:55:57 +0100 |
| commit | 5bf6ba19e964856396fcd470cfd52c47f8b1a55b (patch) | |
| tree | 9e388ae16e89f5115129a91f686122d54550a37e /src/game/server/entities/laser.cpp | |
| parent | 4c582edf1d7669369da7f785bb8cfbb7267fb9b0 (diff) | |
| download | zcatch-5bf6ba19e964856396fcd470cfd52c47f8b1a55b.tar.gz zcatch-5bf6ba19e964856396fcd470cfd52c47f8b1a55b.zip | |
added laserjumps and cleaned up some code
Diffstat (limited to 'src/game/server/entities/laser.cpp')
| -rw-r--r-- | src/game/server/entities/laser.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/game/server/entities/laser.cpp b/src/game/server/entities/laser.cpp index eb40c4e1..f45a1d1d 100644 --- a/src/game/server/entities/laser.cpp +++ b/src/game/server/entities/laser.cpp @@ -2,6 +2,7 @@ /* If you are missing that file, acquire a complete release at teeworlds.com. */ #include <game/generated/protocol.h> #include <game/server/gamecontext.h> +#include <engine/shared/config.h> #include "laser.h" CLaser::CLaser(CGameWorld *pGameWorld, vec2 Pos, vec2 Direction, float StartEnergy, int Owner) @@ -67,6 +68,9 @@ void CLaser::DoBounce() m_Energy = -1; GameServer()->CreateSound(m_Pos, SOUND_RIFLE_BOUNCE); + + if(m_Bounces == 1 && g_Config.m_SvLaserjumps && GameServer()->m_pController->IsZCatch()) + GameServer()->CreateExplosion(m_Pos, m_Owner, WEAPON_GAME, false); } } else |