From 93a1aba588581653809e9ad3950bab9c10dd1053 Mon Sep 17 00:00:00 2001 From: Lactozilla Date: Tue, 30 Apr 2024 01:41:23 -0300 Subject: [PATCH] Use fixed-point angle in Thing_TrackAngle --- src/acs/call-funcs.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/acs/call-funcs.cpp b/src/acs/call-funcs.cpp index fb3390a74..21fbbb567 100644 --- a/src/acs/call-funcs.cpp +++ b/src/acs/call-funcs.cpp @@ -2001,7 +2001,7 @@ bool CallFunc_TrackObjectAngle(ACSVM::Thread *thread, const ACSVM::Word *argV, A mobj_t *anchormo = P_FindMobjFromTID(argV[1], NULL, NULL); if (mobj != NULL && anchormo != NULL && P_MobjWasRemoved(mobj) == false && P_MobjWasRemoved(anchormo) == false) { - INT32 failureangle = FixedAngle((std::min(std::max(abs((int)argV[2]), 0), 360))*FRACUNIT); + angle_t failureangle = ACS_FixedToAngle(argV[2]); INT32 failureexectag = argV[3]; INT32 failuredelay = argC >= 5 ? abs((int)argV[4]) : 0; boolean persist = argC >= 6 ? (argV[5] == 0) : false;