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

Fixes crash

updated readme

added preventive fix from @Frag31337
This commit is contained in:
Marcos Miller Dantas 2023-09-21 09:19:53 -03:00 committed by Veden
parent 59c4202536
commit 5307304ad2
3 changed files with 8 additions and 3 deletions

View File

@ -1,3 +1,8 @@
---------------------------------------------------------------------------------------------------
Version: 3.3.4
Bugfixes:
- Fixed Rampant::on_entity_died
---------------------------------------------------------------------------------------------------
Version: 3.3.3
Bugfixes:

View File

@ -491,7 +491,7 @@ local function onDeath(event)
end
end
if (getCombinedDeathGeneratorRating(chunk) < Universe.retreatThreshold) and cause and cause.valid then
if (getCombinedDeathGeneratorRating(chunk) < Universe.retreatThreshold) and cause and cause.valid and cause.get_health_ratio() ~= nil then
retreatUnits(chunk,
cause,
tick,
@ -515,7 +515,7 @@ local function onDeath(event)
end
end
if cause and cause.valid then
if cause and cause.valid and cause.get_health_ratio() ~= nil then
retreatUnits(chunk,
cause,
tick,

View File

@ -1,7 +1,7 @@
{
"name" : "Rampant",
"factorio_version" : "1.1",
"version" : "3.3.3",
"version" : "3.3.4",
"title" : "Rampant",
"author" : "Veden",
"homepage" : "https://forums.factorio.com/viewtopic.php?f=94&t=31445",