diff --git a/src/LuaAPI.cpp b/src/LuaAPI.cpp index 46fffe4..fba9264 100644 --- a/src/LuaAPI.cpp +++ b/src/LuaAPI.cpp @@ -7,6 +7,9 @@ #include static std::string LuaToString(const sol::object Value, size_t Indent = 1) { + if (Indent > 80) { + return "[[possible recursion, refusing to keep printing]]"; + } switch (Value.get_type()) { case sol::type::userdata: { std::stringstream ss;