From 71838e3b10c248767511c871d285f85dfb91df64 Mon Sep 17 00:00:00 2001 From: Chr1Z93 Date: Fri, 1 Nov 2024 23:35:45 +0100 Subject: [PATCH] Updated doom counter reset to remove ignored doom --- src/core/DoomInPlayCounter.ttslua | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/core/DoomInPlayCounter.ttslua b/src/core/DoomInPlayCounter.ttslua index aa678f5d..2fbba272 100644 --- a/src/core/DoomInPlayCounter.ttslua +++ b/src/core/DoomInPlayCounter.ttslua @@ -84,9 +84,9 @@ function getDoomCount() end -- gets quantity (for stacks) of doom -function getDoomAmount(obj) +function getDoomAmount(obj, disregardIgnoreTag) if (obj.is_face_down and obj.getCustomObject().image_bottom == doomURL) - and not obj.hasTag(IGNORE_TAG) + and (not obj.hasTag(IGNORE_TAG) or disregardIgnoreTag) and inArea(obj.getPosition(), TOTAL_PLAY_AREA) then return math.abs(obj.getQuantity()) else @@ -115,7 +115,7 @@ end function removeDoomFromList(objList) local count = 0 for _, obj in ipairs(objList) do - local amount = getDoomAmount(obj) + local amount = getDoomAmount(obj, true) if amount > 0 then TRASH.putObject(obj) count = count + amount