Add world object methods

This commit is contained in:
Rochet2
2017-09-28 23:45:41 +03:00
parent b1e31a6886
commit fad53ae637
3 changed files with 216 additions and 22 deletions

View File

@@ -91,22 +91,6 @@ namespace LuaUnit
return 1;
}
/**
* Returns true if the [WorldObject] is within given radius of the [Unit].
*
* @param [WorldObject] obj
* @param float radius
* @return bool withinDist
*/
int IsWithinDistInMap(lua_State* L, Unit* unit)
{
WorldObject* obj = Eluna::CHECKOBJ<WorldObject>(L, 2);
float radius = Eluna::CHECKVAL<float>(L, 3);
Eluna::Push(L, unit->IsWithinDistInMap(obj, radius));
return 1;
}
/**
* Returns true if the [Unit] is in an accessible place for the given [Creature].
*