From f02303d33cd164cc2773efc47f8008ddcc3b1821 Mon Sep 17 00:00:00 2001 From: Christoph Oelckers Date: Wed, 17 Feb 2010 22:25:48 +0000 Subject: [PATCH] - added a lock parameter to Door_Animated. SVN r2167 (trunk) --- src/actionspecials.h | 2 +- src/p_lnspec.cpp | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/src/actionspecials.h b/src/actionspecials.h index 5d9471fec..cd49504c3 100644 --- a/src/actionspecials.h +++ b/src/actionspecials.h @@ -12,7 +12,7 @@ DEFINE_SPECIAL(Door_Close, 10, 2, 3, 3) DEFINE_SPECIAL(Door_Open, 11, 2, 3, 3) DEFINE_SPECIAL(Door_Raise, 12, 3, 4, 4) DEFINE_SPECIAL(Door_LockedRaise, 13, 4, 5, 5) -DEFINE_SPECIAL(Door_Animated, 14, 3, 3, 3) +DEFINE_SPECIAL(Door_Animated, 14, 4, 4, 4) DEFINE_SPECIAL(Autosave, 15, 0, 0, 0) // [RH] Save the game *now* DEFINE_SPECIAL(Transfer_WallLight, 16, -1, -1, 2) DEFINE_SPECIAL(Thing_Raise, 17, 1, 1, 1) diff --git a/src/p_lnspec.cpp b/src/p_lnspec.cpp index db2214ec7..cf79e376b 100644 --- a/src/p_lnspec.cpp +++ b/src/p_lnspec.cpp @@ -189,8 +189,11 @@ FUNC(LS_Door_CloseWaitOpen) } FUNC(LS_Door_Animated) -// Door_Animated (tag, speed, delay) +// Door_Animated (tag, speed, delay, lock) { + if (arg3 != 0 && !P_CheckKeys (it, arg3, arg0 != 0)) + return false; + return EV_SlidingDoor (ln, it, arg0, arg1, arg2); }