From bf29b5c6d188dfe25e0d6c5b614b254d1502ca5b Mon Sep 17 00:00:00 2001 From: Monster Iestyn Date: Sat, 1 Apr 2017 20:16:48 +0100 Subject: [PATCH] Print warning message in console if line->next is NULL --- src/p_spec.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/p_spec.c b/src/p_spec.c index 3d83561a9..a699cbc25 100644 --- a/src/p_spec.c +++ b/src/p_spec.c @@ -3039,7 +3039,10 @@ static void P_ProcessLineSpecial(line_t *line, mobj_t *mo, sector_t *callsec) case 443: // Calls a named Lua function #ifdef HAVE_BLUA - LUAh_LinedefExecute(line, mo, callsec); + if (line->text) + LUAh_LinedefExecute(line, mo, callsec); + else + CONS_Alert(CONS_WARNING, "Linedef %d is missing the hook name of the Lua function to call! (This should be given in the front texture fields)\n", line-lines); #else CONS_Alert(CONS_ERROR, "The map is trying to run a Lua script, but this exe was not compiled with Lua support!\n"); #endif