1
0
mirror of https://github.com/veden/Rampant.git synced 2025-02-09 13:36:53 +02:00

Merge branch 'AI_STATE_AGGRESSIVE-squad-generation-fix' of https://github.com/Dagothur/Rampant into prod

This commit is contained in:
Aaron Veden 2021-05-14 20:57:32 -07:00
commit 282243a237
No known key found for this signature in database
GPG Key ID: FF5990B1C6DD3F84

View File

@ -21,7 +21,7 @@ local AI_STATE_ONSLAUGHT = constants.AI_STATE_ONSLAUGHT
function aiPredicates.canAttack(map, tick)
local surface = map.surface
local goodAI = (((map.state == AI_STATE_AGGRESSIVE) and (map.canAttackTick > tick)) or
local goodAI = (((map.state == AI_STATE_AGGRESSIVE) and (map.canAttackTick < tick)) or
(map.state == AI_STATE_RAIDING) or
(map.state == AI_STATE_ONSLAUGHT))
local notPeaceful = not surface.peaceful_mode