From f45ebae8baab99cbc7576b8cfb5316095c83187f Mon Sep 17 00:00:00 2001 From: Jethro Yu Date: Fri, 22 Mar 2024 06:34:33 +0800 Subject: [PATCH] [2048.12] Fix auto buy sell out buildings when sell mode is on --- CHANGELOG.md | 3 +++ RELEASE.md | 5 ++--- info.txt | 4 ++-- main.js | 2 +- 4 files changed, 8 insertions(+), 6 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index f90d8f6..d8280f1 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3,6 +3,9 @@ All notable changes to this project will be documented in this file. The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/). +## [2048.12] - 2024.03.22 +- Fix auto buy sell out buildings when sell mode is on + ## [2048.11] - 2024.03.18 ### Feature - Add auto buy feature to buy the best deal automatically diff --git a/RELEASE.md b/RELEASE.md index fbc43a5..1cd93f2 100644 --- a/RELEASE.md +++ b/RELEASE.md @@ -1,3 +1,2 @@ -## [2048.11] - 2024.03.18 -### Feature -- Add auto buy feature to buy the best deal automatically \ No newline at end of file +## [2048.12] - 2024.03.22 +- Fix auto buy sell out buildings when sell mode is on \ No newline at end of file diff --git a/info.txt b/info.txt index b4955b2..0e5b20d 100644 --- a/info.txt +++ b/info.txt @@ -3,9 +3,9 @@ "ID": "BestDealHelper", "Author": "Jethro Yu", "Description": "Help you choose best deal! (Best Deal Helper)", - "ModVersion": 2048.11, + "ModVersion": 2048.12, "GameVersion": 2.048, - "Date": "03/18/2024", + "Date": "03/22/2024", "Dependencies": [ "CCSE" ], diff --git a/main.js b/main.js index 1714e21..eefafe6 100644 --- a/main.js +++ b/main.js @@ -756,7 +756,7 @@ class PaybackRateMod { this.reorderUpgrades(upgrades); this.reorderBuildings(buildings); - if (this.config.autoBuy && all[0].waitingTime === "") { + if (this.config.autoBuy && all[0].waitingTime === "" && Game.buyMode == 1) { all[0].buy(); } }