1
0
mirror of https://github.com/veden/Rampant.git synced 2025-03-17 20:58:35 +02:00

FACTO-256: Missed potential nil in chunkPassScan

This commit is contained in:
Aaron Veden 2023-03-13 17:24:05 -07:00
parent d6562329aa
commit c25e100f88
No known key found for this signature in database
GPG Key ID: FF5990B1C6DD3F84

View File

@ -306,7 +306,7 @@ function ChunkUtils.chunkPassScan(chunk, map)
setAreaInQueryChunkSize(Universe.cpsFilteredTilesQuery, chunk)
local pass = scanPaths(chunk, map)
local enemyCount = surface.count_entities_filtered(Universe.cpsFilteredEnemyAnyFound)
local playerObjects = chunk.playerBaseGenerator
local playerObjects = (chunk.playerBaseGenerator or 0)
if (pass ~= CHUNK_IMPASSABLE) or (enemyCount > 0) or playerObjects then
local neutralObjects = mMax(0,