Changeset 139 for trunk/src/game/Spell.h

Show
Ignore:
Timestamp:
11/19/08 13:39:41 (17 years ago)
Author:
yumileroy
Message:

[svn] Spell target selection improvement. Remove most mangos hacks in spell target selection. (work almost done)
Merge mangos svn rev 6744.

Original author: megamage
Date: 2008-10-31 11:04:32-05:00

Files:
1 modified

Legend:

Unmodified
Added
Removed
  • trunk/src/game/Spell.h

    r110 r139  
    108108            m_itemTargetEntry  = target.m_itemTargetEntry; 
    109109 
    110             m_srcX = target.m_srcX; 
    111             m_srcY = target.m_srcY; 
    112             m_srcZ = target.m_srcZ; 
     110            //m_srcX = target.m_srcX; 
     111            //m_srcY = target.m_srcY; 
     112            //m_srcZ = target.m_srcZ; 
    113113 
    114114            m_destX = target.m_destX; 
    115115            m_destY = target.m_destY; 
    116116            m_destZ = target.m_destZ; 
     117            m_hasDest = target.m_hasDest; 
    117118 
    118119            m_strTarget = target.m_strTarget; 
     
    126127        Unit *getUnitTarget() const { return m_unitTarget; } 
    127128        void setUnitTarget(Unit *target); 
    128         void setDestination(float x, float y, float z); 
     129        void setDestination(float x, float y, float z, bool send = true); 
     130        void setDestination(Unit *target, bool send = true); 
    129131 
    130132        uint64 getGOTargetGUID() const { return m_GOTargetGUID; } 
     
    148150 
    149151        bool IsEmpty() const { return m_GOTargetGUID==0 && m_unitTargetGUID==0 && m_itemTarget==0 && m_CorpseTargetGUID==0; } 
     152        bool HasDest() const { return m_hasDest; } 
    150153 
    151154        void Update(Unit* caster); 
     
    153156        float m_srcX, m_srcY, m_srcZ; 
    154157        float m_destX, m_destY, m_destZ; 
     158        bool m_hasDest; 
    155159        std::string m_strTarget; 
    156160 
     
    552556            : i_data(&data), i_spell(spell), i_push_type(type), i_radius(radius), i_TargetType(TargetType), i_entry(entry) 
    553557        { 
    554             i_originalCaster = spell.GetOriginalCaster(); 
     558            i_originalCaster = spell.GetCaster(); 
    555559        } 
    556560