aboutsummaryrefslogtreecommitdiff
path: root/src/script
diff options
context:
space:
mode:
Diffstat (limited to 'src/script')
-rw-r--r--src/script/lua_api/l_mapgen.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/script/lua_api/l_mapgen.cpp b/src/script/lua_api/l_mapgen.cpp
index dc3644e1c..76e94e97e 100644
--- a/src/script/lua_api/l_mapgen.cpp
+++ b/src/script/lua_api/l_mapgen.cpp
@@ -215,7 +215,8 @@ Schematic *load_schematic_from_def(lua_State *L, int index,
}
}
- ndef->pendNodeResolve(schem);
+ if (ndef)
+ ndef->pendNodeResolve(schem);
return schem;
}