From 87e3ce2a203592c7cf60c6e6366fa0bd0c8ea0d9 Mon Sep 17 00:00:00 2001 From: Kherae Date: Tue, 3 Sep 2024 20:39:56 -0700 Subject: [PATCH] indentation --- bees/apiary.lua | 68 ++++++++++++++++++++++++------------------------- 1 file changed, 34 insertions(+), 34 deletions(-) diff --git a/bees/apiary.lua b/bees/apiary.lua index 2c0cd280ec..98604bbabb 100644 --- a/bees/apiary.lua +++ b/bees/apiary.lua @@ -92,7 +92,7 @@ specialFrameFunctions = { end end, copperFrame = function(data) - self.randAmount = math.random(1,2) + self.randAmount = math.random(1,2) if isHiveQueenActive(true) and areDronesActive() then if not ironFrameTimer then ironFrameTimer = data[1] @@ -105,7 +105,7 @@ specialFrameFunctions = { end end, ironFrame = function(data) - self.randAmount = math.random(1,2) + self.randAmount = math.random(1,2) if isHiveQueenActive(true) and areDronesActive() then if not ironFrameTimer then ironFrameTimer = data[1] @@ -118,7 +118,7 @@ specialFrameFunctions = { end end, tungstenFrame = function(data) - self.randAmount = math.random(1,2) + self.randAmount = math.random(1,2) if isHiveQueenActive(true) and areDronesActive() then if not ironFrameTimer then ironFrameTimer = data[1] @@ -131,7 +131,7 @@ specialFrameFunctions = { end end, titaniumFrame = function(data) - self.randAmount = math.random(1,2) + self.randAmount = math.random(1,2) if isHiveQueenActive(true) and areDronesActive() then if not ironFrameTimer then ironFrameTimer = data[1] @@ -144,7 +144,7 @@ specialFrameFunctions = { end end, durasteelFrame = function(data) - self.randAmount = math.random(1,2) + self.randAmount = math.random(1,2) if isHiveQueenActive(true) and areDronesActive() then if not ironFrameTimer then ironFrameTimer = data[1] @@ -172,7 +172,7 @@ function init() biome = world.type() -- Disabled on ship and player space stations - if biome == "unknown" then --or biome == "playerstation" then + if biome == "unknown" then --or biome == "playerstation" then script.setUpdateDelta(-1) return end @@ -527,7 +527,7 @@ function getFrames(dt) frameBonuses[stat] = true end elseif cfg.config[stat] then - -- the total frame count influences the overall stats. Take the current frame bonus and add the amount in the stack to the provided bonus + -- the total frame count influences the overall stats. Take the current frame bonus and add the amount in the stack to the provided bonus frameBonuses[stat] = (frameBonuses[stat] + cfg.config[stat]) * (1 + ((contents[frameSlot].count/100) * 0.5 )) --add total frames to total end end @@ -655,7 +655,7 @@ function queenProduction() --youngQueenProgress = youngQueenProgress + productionQueen * (math.random(beeData.productionRandomModifierRange[1],beeData.productionRandomModifierRange[2]) * 0.01) * 0.25 youngQueenProgress = youngQueenProgress + productionQueen * (math.random(beeData.productionRandomModifierRange[1],beeData.productionRandomModifierRange[2]) * 0.01) * 0.5 --sb.logInfo(youngQueenProgress) - droneProgress = droneProgress + productionDrone * (math.random(beeData.productionRandomModifierRange[1],beeData.productionRandomModifierRange[2]) * 0.01) * 0.25 + droneProgress = droneProgress + productionDrone * (math.random(beeData.productionRandomModifierRange[1],beeData.productionRandomModifierRange[2]) * 0.01) * 0.25 if youngQueenProgress >= beeData.youngQueenProductionRequirement then local produced = math.floor(youngQueenProgress / beeData.youngQueenProductionRequirement) @@ -736,11 +736,11 @@ end -- Can be called from other places (Like the frame scripts) function ageQueen(amount) --if changing this, make sure it matches in beeBuilder.lua - local fullLifespan = genelib.statFromGenomeToValue(queen.parameters.genome, "queenLifespan") * ((frameBonuses.queenLifespan or 0 / 8) + 1) - --sb.logInfo(fullLifespan) + local fullLifespan = genelib.statFromGenomeToValue(queen.parameters.genome, "queenLifespan") * ((frameBonuses.queenLifespan or 0 / 8) + 1) + --sb.logInfo(fullLifespan) if not queen.parameters.lifespan or queen.parameters.lifespan < 0 then - queen.parameters.lifespan = fullLifespan + queen.parameters.lifespan = fullLifespan end @@ -993,21 +993,21 @@ function miteGrowth() --sb.logInfo("%s",sDBG) --display an infested hive image over the normal hive appearance if its infested enough - if storage.mites > 20 then --if mites pass 20, display a really rotten looking apiary - animator.setAnimationState("base", "infested2", true) - animator.setAnimationState("warning", "on", true) - elseif storage.mites > 6 then --if mites pass 6, display a rotten looking apiary - animator.setAnimationState("base", "infested", true) - animator.setAnimationState("warning", "on", true) + if storage.mites > 20 then --if mites pass 20, display a really rotten looking apiary + animator.setAnimationState("base", "infested2", true) + animator.setAnimationState("warning", "on", true) + elseif storage.mites > 6 then --if mites pass 6, display a rotten looking apiary + animator.setAnimationState("base", "infested", true) + animator.setAnimationState("warning", "on", true) elseif storage.mites > 0.98 then - animator.setAnimationState("warning", "on", true) --show symbol for mite infestation, but dont change apiary look + animator.setAnimationState("warning", "on", true) --show symbol for mite infestation, but dont change apiary look else - animator.setAnimationState("base", "default", true) - animator.setAnimationState("warning", "off", true) + animator.setAnimationState("base", "default", true) + animator.setAnimationState("warning", "off", true) end -- elseif fartstick <= beeData.mites.infestationChance then elseif math.random() <= beeData.mites.infestationChance then - storage.mites = beeData.mites.growthStatic --storage.mites = storage.mites + (storage.mites*mult) - (hiveMiteResistance) + storage.mites = beeData.mites.growthStatic --storage.mites = storage.mites + (storage.mites*mult) - (hiveMiteResistance) end end @@ -1120,27 +1120,27 @@ function getBiomeFavor(name) --frame immunity to biomes if frameBonuses.radResistance then if (biome == "alien") or (biome == "jungle") or (biome == "barren") or (biome == "barren2") or (biome == "barren3") or (biome == "chromatic") or (biome == "irradiated") or (biome == "metallicmoon") then - if (favor < 2) then - favor = 2 - end + if (favor < 2) then + favor = 2 + end end elseif frameBonuses.coldResistance then if (biome == "snow") or (biome == "arctic") or (biome == "snowdark") or (biome == "arcticdark") or (biome == "tundra") or (biome == "tundradark") or (biome == "crystalmoon") or (biome == "frozenvolcanic") or (biome == "icemoon") or (biome == "icewaste") or (biome == "icewastedark") or (biome == "nitrogensea") then - if (favor < 2) then - favor = 2 - end + if (favor < 2) then + favor = 2 + end end elseif frameBonuses.heatResistance then if (biome == "desert") or (biome == "volcanic") or (biome == "volcanicdark") or (biome == "magma") or (biome == "magmadark") or (biome == "desertwastes") or (biome == "desertwastesdark") or (biome == "infernus") or (biome == "infernusdark") or (biome == "frozenvolcanic") then - if (favor < 2) then - favor = 2 - end + if (favor < 2) then + favor = 2 + end end elseif frameBonuses.physicalResistance then - if (biome == "toxic") or (biome == "moon") or (biome == "scorched") or (biome == "scorchedcity") or (biome == "volcanic") or (biome == "volcanicdark") or (biome == "savannah") or (biome == "jungle") or (biome == "thickjungle") or (biome == "sulphuric") or (biome == "sulphuricdark") or (biome == "tidewater") then - if (favor < 2) then - favor = 2 - end + if (biome == "toxic") or (biome == "moon") or (biome == "scorched") or (biome == "scorchedcity") or (biome == "volcanic") or (biome == "volcanicdark") or (biome == "savannah") or (biome == "jungle") or (biome == "thickjungle") or (biome == "sulphuric") or (biome == "sulphuricdark") or (biome == "tidewater") then + if (favor < 2) then + favor = 2 + end end end