Skip to content

Commit

Permalink
Update 1.4.2 (#7)
Browse files Browse the repository at this point in the history
- Moved logging back to the common file
  • Loading branch information
msolefonte authored Aug 8, 2022
1 parent e62ca52 commit 4ad5044
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 8 deletions.
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -64,3 +64,7 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
- New method `get_unit_cost_from_key(unit_key)` added to the CBAC lib API
- Renamed `script/campaign/mod/cbac.lua` into `script/campaign/mod/cbac-tooltip.lua`
- Introduced and enforced a 120 chars per line limit

## [1.4.2] - 08.08.2022

- Moved logging back to the common file
Binary file modified dist/wolfy_cost_based_army_caps.pack
Binary file not shown.
5 changes: 1 addition & 4 deletions src/script/_lib/mod/cbac.lua
Original file line number Diff line number Diff line change
Expand Up @@ -65,10 +65,7 @@ end

function cbac:log(str)
if cbac:get_config("logging_enabled") then
local log_file = io.open("wolfy_mods_log.txt","a");
log_file:write("\n[cbac] " .. str);
log_file:flush();
log_file:close();
out("[wolfy][cbac] " .. str);
end
end

Expand Down
8 changes: 4 additions & 4 deletions src/script/mct/settings/cbac.lua
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ mct_mod:set_title("Cost-based Army Caps", false);
mct_mod:set_author("Wolfy & Jadawin");
mct_mod:set_description("MP-Style Cost Limit For All Armies", false);

local mct_section_base = mct_mod:add_new_section("1-cbac-base", "Base Options", false);
mct_mod:add_new_section("1-cbac-base", "Base Options", false);

local option_cbac_army_limit_player = mct_mod:add_new_option("army_limit_player", "slider");
option_cbac_army_limit_player:set_text("Player Limit (Base)");
Expand All @@ -33,7 +33,7 @@ option_cbac_hero_cap:slider_set_min_max(0, 19);
option_cbac_hero_cap:slider_set_step_size(1);
option_cbac_hero_cap:set_default_value(2);

local mct_section_extra = mct_mod:add_new_section("2-cbac-extra", "Extra Options", false);
mct_mod:add_new_section("2-cbac-extra", "Extra Options", false);

local option_cbac_dynamic_limit = mct_mod:add_new_option("dynamic_limit", "checkbox");
option_cbac_dynamic_limit:set_text("Enable Dynamic Cost Limit");
Expand Down Expand Up @@ -77,7 +77,7 @@ option_cbac_army_limit_fl_bonus:slider_set_min_max(0, 10000);
option_cbac_army_limit_fl_bonus:slider_set_step_size(500);
option_cbac_army_limit_fl_bonus:set_default_value(0);

local mct_section_ai = mct_mod:add_new_section("3-cbac-ai", "AI Behaviour Options [NOT READY]", false);
mct_mod:add_new_section("3-cbac-ai", "AI Behaviour Options [NOT READY]", false);

local option_cbac_upgrade_ai = mct_mod:add_new_option("upgrade_ai_armies", "checkbox");
option_cbac_upgrade_ai:set_text("Enable Upgraded AI Armies");
Expand All @@ -100,7 +100,7 @@ option_cbac_autolevel_ai:slider_set_min_max(0, 5);
option_cbac_autolevel_ai:slider_set_step_size(1);
option_cbac_autolevel_ai:set_default_value(3);

local mct_section_ao = mct_mod:add_new_section("4-cbac-ao", "Advanced Options", false);
mct_mod:add_new_section("4-cbac-ao", "Advanced Options", false);

local option_cbac_settings_locked = mct_mod:add_new_option("settings_locked", "checkbox");
option_cbac_settings_locked:set_text("Lock settings during campaigns");
Expand Down

0 comments on commit 4ad5044

Please sign in to comment.