diff --git a/src/lua_consolelib.c b/src/lua_consolelib.c
index 4fe234deeecc88f6643d04bd0663a070b3fa85be..36b1c3669220fb643f9080f288bae08150da5862 100644
--- a/src/lua_consolelib.c
+++ b/src/lua_consolelib.c
@@ -444,7 +444,7 @@ static int lib_consPrintf(lua_State *L)
 	if (n < 2)
 		return luaL_error(L, "CONS_Printf requires at least two arguments: player and text.");
 	//HUDSAFE
-	INLEVEL
+
 	plr = *((player_t **)luaL_checkudata(L, 1, META_PLAYER));
 	if (!plr)
 		return LUA_ErrInvalid(L, "player_t");
diff --git a/src/lua_mobjlib.c b/src/lua_mobjlib.c
index 129339b96fde68c6eab8b3878c91aacadfa529f5..e2826e1600d3daae964fc8c6a98780adf0591ee1 100644
--- a/src/lua_mobjlib.c
+++ b/src/lua_mobjlib.c
@@ -165,14 +165,15 @@ static int mobj_get(lua_State *L)
 	enum mobj_e field = Lua_optoption(L, 2, NULL, mobj_opt);
 	lua_settop(L, 2);
 
-	INLEVEL
-
-	if (!mo) {
+	if (!mo || !ISINLEVEL) {
 		if (field == mobj_valid) {
 			lua_pushboolean(L, 0);
 			return 1;
 		}
-		return LUA_ErrInvalid(L, "mobj_t");
+		if (!mo) {
+			return LUA_ErrInvalid(L, "mobj_t");
+		} else
+			return luaL_error(L, "Do not access an mobj_t field outside a level!");
 	}
 
 	switch(field)