shithub: choc

Download patch

ref: dd913a157ea5b8072d72b712b8d038f2231981ba
parent: 698015b6224ca500a7852450994c94a69afe761f
author: Turo Lamminen <turol@iki.fi>
date: Thu May 7 13:38:23 EDT 2020

hexen: Fix another clang abs warning in DragonSeek

--- a/src/hexen/p_enemy.c
+++ b/src/hexen/p_enemy.c
@@ -2915,9 +2915,9 @@
                 mo = P_FindMobjFromTID(target->args[i], &search);
                 angleToSpot = R_PointToAngle2(actor->x, actor->y,
                                               mo->x, mo->y);
-                if (abs(angleToSpot - angleToTarget) < bestAngle)
+                if (abs((int) angleToSpot - (int) angleToTarget) < bestAngle)
                 {
-                    bestAngle = abs(angleToSpot - angleToTarget);
+                    bestAngle = abs((int) angleToSpot - (int) angleToTarget);
                     bestArg = i;
                 }
             }