aboutsummaryrefslogtreecommitdiff
path: root/src/game/GridNotifiers.h
diff options
context:
space:
mode:
authorgvcoman <none@none>2008-11-14 20:40:35 -0600
committergvcoman <none@none>2008-11-14 20:40:35 -0600
commit5deef1bb59ba53570d481a97e5c1df39ef316f37 (patch)
tree334e913e1247419d2ad485f1681e859aa8875044 /src/game/GridNotifiers.h
parent3085e66b966fec0012decf2543c7e32064b47102 (diff)
[svn] * Reimplemented packet/update forwarding in more generic way
* Implemented far sight spells (Far Sight, Eagle Eye, etc) at unlimited range and properly forward packets * Implemented bind vision spells (Mind Vision, etc) to forward packets at unlimited distance * Implemented Sentry Totem (both vision switching/forwarding and alerting) * Other misc possession fixes * Added .bindsight and .unbindsight commands Please test out the above spells (including Mind Control) and report any issues on the forums. --HG-- branch : trunk
Diffstat (limited to 'src/game/GridNotifiers.h')
-rw-r--r--src/game/GridNotifiers.h14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/game/GridNotifiers.h b/src/game/GridNotifiers.h
index daa5ece7c6a..972c209964c 100644
--- a/src/game/GridNotifiers.h
+++ b/src/game/GridNotifiers.h
@@ -95,10 +95,12 @@ namespace Trinity
WorldPacket *i_message;
std::set<uint64> plr_list;
bool i_toPossessor;
+ bool i_toSelf;
float i_dist;
- Deliverer(WorldObject &src, WorldPacket *msg, bool to_possessor, float dist = 0.0f) : i_source(src), i_message(msg), i_toPossessor(to_possessor), i_dist(dist) {}
+ Deliverer(WorldObject &src, WorldPacket *msg, bool to_possessor, bool to_self, float dist = 0.0f) : i_source(src), i_message(msg), i_toPossessor(to_possessor), i_toSelf(to_self), i_dist(dist) {}
void Visit(PlayerMapType &m);
void Visit(CreatureMapType &m);
+ void Visit(DynamicObjectMapType &m);
virtual void VisitObject(Player* plr) = 0;
void SendPacket(Player* plr);
template<class SKIP> void Visit(GridRefManager<SKIP> &) {}
@@ -106,28 +108,26 @@ namespace Trinity
struct TRINITY_DLL_DECL MessageDeliverer : public Deliverer
{
- bool i_toSelf;
- MessageDeliverer(Player &pl, WorldPacket *msg, bool to_possessor, bool to_self) : Deliverer(pl, msg, to_possessor), i_toSelf(to_self) {}
+ MessageDeliverer(Player &pl, WorldPacket *msg, bool to_possessor, bool to_self) : Deliverer(pl, msg, to_possessor, to_self) {}
void VisitObject(Player* plr);
};
struct TRINITY_DLL_DECL ObjectMessageDeliverer : public Deliverer
{
- explicit ObjectMessageDeliverer(WorldObject &src, WorldPacket *msg, bool to_possessor) : Deliverer(src, msg, to_possessor) {}
+ explicit ObjectMessageDeliverer(WorldObject &src, WorldPacket *msg, bool to_possessor) : Deliverer(src, msg, to_possessor, false) {}
void VisitObject(Player* plr) { SendPacket(plr); }
};
struct TRINITY_DLL_DECL MessageDistDeliverer : public Deliverer
{
- bool i_toSelf;
bool i_ownTeamOnly;
- MessageDistDeliverer(Player &pl, WorldPacket *msg, bool to_possessor, float dist, bool to_self, bool ownTeamOnly) : Deliverer(pl, msg, to_possessor, dist), i_toSelf(to_self), i_ownTeamOnly(ownTeamOnly) {}
+ MessageDistDeliverer(Player &pl, WorldPacket *msg, bool to_possessor, float dist, bool to_self, bool ownTeamOnly) : Deliverer(pl, msg, to_possessor, to_self, dist), i_ownTeamOnly(ownTeamOnly) {}
void VisitObject(Player* plr);
};
struct TRINITY_DLL_DECL ObjectMessageDistDeliverer : public Deliverer
{
- ObjectMessageDistDeliverer(WorldObject &obj, WorldPacket *msg, bool to_possessor, float dist) : Deliverer(obj, msg, to_possessor, dist) {}
+ ObjectMessageDistDeliverer(WorldObject &obj, WorldPacket *msg, bool to_possessor, float dist) : Deliverer(obj, msg, to_possessor, false, dist) {}
void VisitObject(Player* plr) { SendPacket(plr); }
};