summaryrefslogtreecommitdiff
path: root/src/scripting/luautil.cpp
diff options
context:
space:
mode:
authorThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-01-30 22:16:40 +0100
committerThorbjørn Lindeijer <thorbjorn@lindeijer.nl>2012-01-31 21:50:49 +0100
commit4cd1957231605e976c5cf001eddea80d5e49272f (patch)
tree1fd13522adeb62c408562a4ff76c98ee2e254342 /src/scripting/luautil.cpp
parentbc291713c56a2bc27ec10cef52dd3a52a0579c7d (diff)
downloadmanaserv-4cd1957231605e976c5cf001eddea80d5e49272f.tar.gz
manaserv-4cd1957231605e976c5cf001eddea80d5e49272f.tar.bz2
manaserv-4cd1957231605e976c5cf001eddea80d5e49272f.tar.xz
manaserv-4cd1957231605e976c5cf001eddea80d5e49272f.zip
Use a full user data object for MapObject references
Based on a templated helper class, MapObject references in Lua scripts are now full user data objects. Using the '__index' member of their metatable, a library is associated with it so that member functions can be called directly on the object. Reviewed-by: Yohann Ferreira Reviewed-by: Erik Schilling
Diffstat (limited to 'src/scripting/luautil.cpp')
-rw-r--r--src/scripting/luautil.cpp5
1 files changed, 0 insertions, 5 deletions
diff --git a/src/scripting/luautil.cpp b/src/scripting/luautil.cpp
index a7521426..b7680c6b 100644
--- a/src/scripting/luautil.cpp
+++ b/src/scripting/luautil.cpp
@@ -116,8 +116,3 @@ void push(lua_State *s, double val)
{
lua_pushnumber(s, val);
}
-
-void push(lua_State *s, MapObject *val)
-{
- lua_pushlightuserdata(s, val);
-}