From fd8c95add9e33065dee879981afaa0e60f02836b Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lilian=20J=C3=B3nsd=C3=B3ttir?= Date: Thu, 8 Oct 2020 20:34:04 -0700 Subject: [PATCH] faction is already lower, don't need this --- MWSE/mods/celediel/NPCsGoHome/functions/checks.lua | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/MWSE/mods/celediel/NPCsGoHome/functions/checks.lua b/MWSE/mods/celediel/NPCsGoHome/functions/checks.lua index 0a70de0..0aee29d 100644 --- a/MWSE/mods/celediel/NPCsGoHome/functions/checks.lua +++ b/MWSE/mods/celediel/NPCsGoHome/functions/checks.lua @@ -245,10 +245,10 @@ this.isPublicHouse = function(cell) info.percentage = (info.total / npcs.total) * 100 log(common.logLevels.large, "[CHECKS] No NPCs of ignored class in %s, checking faction %s (ignored: %s, player joined: %s) with %s (%s%%) vs total %s", - cell.name, faction, config.ignored[faction:lower()], info.playerJoined, info.total, info.percentage, npcs.total) + cell.name, faction, config.ignored[faction], info.playerJoined, info.total, info.percentage, npcs.total) -- less than configured amount of NPCs can't be a public house unless it's a Blades house - if (config.ignored[faction:lower()] or info.playerJoined) and + if (config.ignored[faction] or info.playerJoined) and (npcs.total >= config.minimumOccupancy or faction == "Blades") and (info.percentage >= config.factionIgnorePercentage) then log(common.logLevels.medium, "[CHECKS] %s is %s%% faction %s, marking public.", cell.name, info.percentage, faction)