From d7262a62986ccdf24fdf8a8f3702246adf359d3d Mon Sep 17 00:00:00 2001 From: tartalo Date: Tue, 1 Dec 2009 11:43:57 +0100 Subject: Implement No Fly Zone using Spell, by Spp. Needs db support. Closes #494 --HG-- branch : trunk --- src/game/Spell.cpp | 9 +++++++++ 1 file changed, 9 insertions(+) (limited to 'src/game/Spell.cpp') diff --git a/src/game/Spell.cpp b/src/game/Spell.cpp index 7e886402480..66c8f5fa99c 100644 --- a/src/game/Spell.cpp +++ b/src/game/Spell.cpp @@ -5094,6 +5094,15 @@ SpellCastResult Spell::CheckCast(bool strict) break; } + case 44795: // Parachute + { + float x, y, z; + m_caster->GetPosition(x, y, z); + float ground_Z = m_caster->GetMap()->GetVmapHeight(x, y, z, true); + if (fabs(ground_Z - z) < 0.1f) + return SPELL_FAILED_DONT_REPORT; + break; + } default: break; } -- cgit v1.2.3