From 3cff307e7756aae6e0f8c255f5a8a6eaf28270ec Mon Sep 17 00:00:00 2001 From: Randy Heit Date: Tue, 4 Feb 2014 19:36:29 -0600 Subject: [PATCH] Add Get/SetLineActivation ACS functions --- src/p_acs.cpp | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/p_acs.cpp b/src/p_acs.cpp index 26b62be70..1ed89f783 100644 --- a/src/p_acs.cpp +++ b/src/p_acs.cpp @@ -4251,6 +4251,8 @@ enum EACSFunctions ACSF_CheckFont, ACSF_DropItem, ACSF_CheckFlag, + ACSF_SetLineActivation, + ACSF_GetLineActivation, // ZDaemon ACSF_GetTeamScore = 19620, // (int team) @@ -5296,6 +5298,26 @@ doplaysound: if (funcIndex == ACSF_PlayActorSound) break; } + case ACSF_SetLineActivation: + if (argCount >= 2) + { + int line = -1; + + while ((line = P_FindLineFromID(args[0], line)) >= 0) + { + lines[line].activation = args[1]; + } + } + break; + + case ACSF_GetLineActivation: + if (argCount > 0) + { + int line = P_FindLineFromID(args[0], -1); + return line >= 0 ? lines[line].activation : 0; + } + break; + default: break; }