From a87f75a4ff94af7d83ebd3486fb770f1c087cc75 Mon Sep 17 00:00:00 2001 From: Stefano Pigozzi Date: Sun, 14 May 2023 22:20:44 +0200 Subject: [PATCH] Fix rounding error in `perks_amount` --- init.lua | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/init.lua b/init.lua index 29bc891..9334bde 100755 --- a/init.lua +++ b/init.lua @@ -13,7 +13,7 @@ function OnPlayerSpawned( player_entity ) GameAddFlagRun( init_check_flag ) -- Load mod settings - local perks_amount = math.ceil(ModSettingGet("starting_perk.perks_spawned")) + local perks_amount = math.ceil(ModSettingGet("starting_perk.perks_spawned") - 0.5) local only_one = ModSettingGet("starting_perk.only_one") -- Print mod settings to the player