aboutsummaryrefslogtreecommitdiff
path: root/src/bindings/scripts/include
diff options
context:
space:
mode:
authormegamage <none@none>2009-05-29 16:49:28 -0500
committermegamage <none@none>2009-05-29 16:49:28 -0500
commit89f4c1c444b9a0b090d71667c26f05165394a594 (patch)
treeb70b3583bba1a1341f1e371e9a9a1956dc1377c0 /src/bindings/scripts/include
parent3faa712d429fe5e352b73a6e5e524a2d1f4630d7 (diff)
*Add function FindNearestCreature and FindNearestGameObject to replace old FindCreature and FindGameObject
--HG-- branch : trunk
Diffstat (limited to 'src/bindings/scripts/include')
-rw-r--r--src/bindings/scripts/include/sc_creature.cpp22
-rw-r--r--src/bindings/scripts/include/sc_creature.h7
2 files changed, 0 insertions, 29 deletions
diff --git a/src/bindings/scripts/include/sc_creature.cpp b/src/bindings/scripts/include/sc_creature.cpp
index 347330c2006..b0ff9d48584 100644
--- a/src/bindings/scripts/include/sc_creature.cpp
+++ b/src/bindings/scripts/include/sc_creature.cpp
@@ -507,28 +507,6 @@ void ScriptedAI::DoTeleportAll(float x, float y, float z, float o)
i_pl->TeleportTo(m_creature->GetMapId(), x, y, z, o, TELE_TO_NOT_LEAVE_COMBAT);
}
-Unit* FindCreature(uint32 entry, float range, Unit* Finder)
-{
- if(!Finder)
- return NULL;
- Creature* target = NULL;
- Trinity::AllCreaturesOfEntryInRange check(Finder, entry, range);
- Trinity::CreatureSearcher<Trinity::AllCreaturesOfEntryInRange> searcher(Finder, target, check);
- Finder->VisitNearbyObject(range, searcher);
- return target;
-}
-
-GameObject* FindGameObject(uint32 entry, float range, Unit* Finder)
-{
- if(!Finder)
- return NULL;
- GameObject* target = NULL;
- Trinity::AllGameObjectsWithEntryInGrid go_check(entry);
- Trinity::GameObjectSearcher<Trinity::AllGameObjectsWithEntryInGrid> searcher(Finder, target, go_check);
- Finder->VisitNearbyGridObject(range, searcher);
- return target;
-}
-
Unit* ScriptedAI::DoSelectLowestHpFriendly(float range, uint32 MinHPDiff)
{
Unit* pUnit = NULL;
diff --git a/src/bindings/scripts/include/sc_creature.h b/src/bindings/scripts/include/sc_creature.h
index 88801227493..3eef1db1947 100644
--- a/src/bindings/scripts/include/sc_creature.h
+++ b/src/bindings/scripts/include/sc_creature.h
@@ -29,13 +29,6 @@ class SummonList : private std::list<uint64>
Creature *m_creature;
};
-
-//Get a single creature of given entry
-Unit* FindCreature(uint32 entry, float range, Unit* Finder);
-
-//Get a single gameobject of given entry
-GameObject* FindGameObject(uint32 entry, float range, Unit* Finder);
-
struct PointMovement
{
uint32 m_uiCreatureEntry;