diff --git a/src/g_level.cpp b/src/g_level.cpp index 60e9b0699..fadfd9245 100644 --- a/src/g_level.cpp +++ b/src/g_level.cpp @@ -1291,6 +1291,9 @@ void G_FinishTravel () if (level.FromSnapshot) { FBehavior::StaticStartTypedScripts (SCRIPT_Return, pawn, true); + + // [Nash] run REOPEN scripts upon map re-entry + FBehavior::StaticStartTypedScripts(SCRIPT_Reopen, NULL, false); } } diff --git a/src/p_acs.cpp b/src/p_acs.cpp index ffac7a78f..c85cc65d6 100644 --- a/src/p_acs.cpp +++ b/src/p_acs.cpp @@ -2822,7 +2822,8 @@ void FBehavior::StaticStartTypedScripts (WORD type, AActor *activator, bool alwa "Lightning", "Unloading", "Disconnect", - "Return" + "Return", + "Reopen" }; DPrintf(DMSG_NOTIFY, "Starting all scripts of type %d (%s)\n", type, type < countof(TypeNames) ? TypeNames[type] : TypeNames[SCRIPT_Lightning - 1]); diff --git a/src/p_acs.h b/src/p_acs.h index 243e2ccf3..d26829c61 100644 --- a/src/p_acs.h +++ b/src/p_acs.h @@ -272,6 +272,7 @@ enum SCRIPT_Return = 15, SCRIPT_Event = 16, // [BB] SCRIPT_Kill = 17, // [JM] + SCRIPT_Reopen = 18, // [Nash] }; // Script flags