diff options
Diffstat (limited to 'src/script')
-rw-r--r-- | src/script/lua_api/l_mapgen.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/script/lua_api/l_mapgen.cpp b/src/script/lua_api/l_mapgen.cpp index 825292419..7adb6a534 100644 --- a/src/script/lua_api/l_mapgen.cpp +++ b/src/script/lua_api/l_mapgen.cpp @@ -493,7 +493,7 @@ int ModApiMapgen::l_get_mapgen_object(lua_State *L) EmergeManager *emerge = getServer(L)->getEmergeManager(); Mapgen *mg = emerge->getCurrentMapgen(); if (!mg) - return 0; + throw LuaError("Must only be called in a mapgen thread!"); size_t maplen = mg->csize.X * mg->csize.Z; |