Fix FindBestNearbyCover() and delete global var (#156)

This commit is contained in:
rftrdev
2023-05-26 21:28:00 -07:00
committed by GitHub
parent f2ab296b49
commit 119c6fe6bb
6 changed files with 30 additions and 29 deletions
+1 -1
View File
@@ -753,7 +753,7 @@ INT32 FindBestNearbyCover(SOLDIERTYPE *pSoldier, INT32 morale, INT32 *piPercentB
iMyThreatValue = CalcManThreatValue(pSoldier, NOWHERE, FALSE, pSoldier);
// prepare threat list from known enemies
PrepareThreatlist(pSoldier);
uiThreatCnt = PrepareThreatlist(pSoldier);
// if no known opponents were found to threaten us, can't worry about cover
if (!uiThreatCnt)