From 8da91f63f710a012be339ea2a162a6df765614b2 Mon Sep 17 00:00:00 2001 From: Erik Schilling Date: Thu, 9 Aug 2012 00:17:02 +0200 Subject: Fixed item_drop insertion of object --- src/scripting/lua.cpp | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/scripting/lua.cpp') diff --git a/src/scripting/lua.cpp b/src/scripting/lua.cpp index a759e0b4..5e0f93c9 100644 --- a/src/scripting/lua.cpp +++ b/src/scripting/lua.cpp @@ -2173,7 +2173,6 @@ static int item_class_on(lua_State *s) /** * drop_item(int x, int y, int id || string name[, int number]): bool * Creates an item stack on the floor. - * @Returns whether the insertion was successful. */ static int item_drop(lua_State *s) { @@ -2188,8 +2187,8 @@ static int item_drop(lua_State *s) i->setMap(map); Point pos(x, y); i->setPosition(pos); - lua_pushboolean(s, GameState::insertOrDelete(i)); - return 1; + GameState::enqueueInsert(i); + return 0; } /** -- cgit v1.2.3-70-g09d2