From 0e4d0a9bfb90969121d2a31913eac0d440982453 Mon Sep 17 00:00:00 2001 From: Shad000w Date: Fri, 7 Jul 2023 10:40:33 +0200 Subject: [PATCH] fix for issue #105, turned out that the issue happened due to the vanilla code that was using gTacticalStatus.uiFlags & GODMODE despite it was never actually implemented by SirTech. I changed it to only work gainst player mercs so militia and npcs can damage each other again. (#174) --- Tactical/LOS.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Tactical/LOS.cpp b/Tactical/LOS.cpp index 276aaf691..1911493ea 100644 --- a/Tactical/LOS.cpp +++ b/Tactical/LOS.cpp @@ -3018,7 +3018,7 @@ BOOLEAN BulletHitMerc( BULLET * pBullet, STRUCTURE * pStructure, BOOLEAN fIntend // Determine damage, checking guy's armour, etc sRange = GetRangeInCellCoordsFromGridNoDiff( pBullet->sOrigGridNo, pTarget->sGridNo ); - if ( gTacticalStatus.uiFlags & GODMODE && pBullet->ubFirerID != NOBODY && !(pFirer->flags.uiStatusFlags & SOLDIER_PC)) + if ( gTacticalStatus.uiFlags & GODMODE && pTarget->bTeam == OUR_TEAM && pBullet->ubFirerID != NOBODY && !(pFirer->flags.uiStatusFlags & SOLDIER_PC)) { // in god mode, and firer is computer controlled iImpact = 0;