From 1f5ce047ad6cb709f746b794b4a2dea9e2f89fb6 Mon Sep 17 00:00:00 2001 From: Simon Howard Date: Fri, 20 Feb 2015 00:03:15 -0500 Subject: Fix game code that makes false boolean assumptions. Various bits of code assume that booleans are represented as 32-bit ints and that they can be assigned to from 32-bit values. This isn't true on all systems; fix code that does this to convert to boolean values properly. This is more progress towards fixing #509. --- src/strife/p_enemy.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/strife/p_enemy.c') diff --git a/src/strife/p_enemy.c b/src/strife/p_enemy.c index 8aad08fc..e358e616 100644 --- a/src/strife/p_enemy.c +++ b/src/strife/p_enemy.c @@ -891,7 +891,7 @@ void A_Look (mobj_t* actor) // as a parameter to control allaround look behavior. Did they just run out of // flags, or what? // STRIFE-TODO: Needs serious verification. - if (!P_LookForPlayers (actor, actor->flags & MF_GIVEQUEST) ) + if (!P_LookForPlayers(actor, (actor->flags & MF_GIVEQUEST) != 0)) return; // go into chase state @@ -975,7 +975,7 @@ void A_FriendLook(mobj_t* actor) gamemap != 3 && gamemap != 34) { // STRIFE-TODO: Needs serious verification. - if(P_LookForPlayers(actor, actor->flags & MF_GIVEQUEST)) + if(P_LookForPlayers(actor, (actor->flags & MF_GIVEQUEST) != 0)) { P_SetMobjState(actor, actor->info->seestate); actor->flags |= MF_NODIALOG; -- cgit v1.2.3