From a09e4abd8fd3fdfa0181aaa19e6dbd17d27d3541 Mon Sep 17 00:00:00 2001 From: Bruno Cordioli Date: Wed, 21 Feb 2024 22:16:49 -0300 Subject: [PATCH] v2.0.7-beta (#72) * feat: fast-mode and skip lobby (#61) * feat: added fast-mode and skip lobby implementation * fix: Debug * fix: fastmode shouldn't show on other commands besides shop * feat: popconfirm on checkboxes * fix: debug * feat: devmode * feat: improve dev mode display * fix: currentscreen and fastmode still enabled not on devmode --------- Co-authored-by: Bruno Cordioli * v2.0.6-beta * feat: reworked features (#71) * Develop (#68) * feat: fast-mode and skip lobby (#61) * feat: added fast-mode and skip lobby implementation * fix: Debug * fix: fastmode shouldn't show on other commands besides shop * feat: popconfirm on checkboxes * fix: debug * feat: devmode * feat: improve dev mode display * fix: currentscreen and fastmode still enabled not on devmode --------- Co-authored-by: Bruno Cordioli * fix: prettier * v2.0.6-beta --------- Co-authored-by: Bruno Cordioli * v2.0.6-beta (#69) * feat: fast-mode and skip lobby (#61) * feat: added fast-mode and skip lobby implementation * fix: Debug * fix: fastmode shouldn't show on other commands besides shop * feat: popconfirm on checkboxes * fix: debug * feat: devmode * feat: improve dev mode display * fix: currentscreen and fastmode still enabled not on devmode --------- Co-authored-by: Bruno Cordioli * v2.0.6-beta --------- Co-authored-by: Bruno Cordioli * fix: hunt * feat: Made daily button disabled --------- Co-authored-by: Bruno Cordioli * feat: Update changelog and version --------- Co-authored-by: Bruno Cordioli --- CHANGELOG.md | 12 +++++++++-- .../app/src/components/AppSider/AppSider.tsx | 20 +++++++++---------- packages/app/src/context/AppContext.tsx | 2 ++ packages/core/epic7_bot/modules/Battle.py | 2 +- packages/core/view.py | 3 +-- 5 files changed, 24 insertions(+), 15 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 7fe5801..885d929 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -4,13 +4,21 @@ All notable changes to this project will be documented in this file. Dates are d Generated by [`auto-changelog`](https://github.com/CookPete/auto-changelog). +#### [v2.0.7-beta](https://github.com/brunocordioli072/epic7_bot/compare/v2.0.6-beta...v2.0.7-beta) + +> 21 February 2024 + +- feat: fast-mode and skip lobby [`#61`](https://github.com/brunocordioli072/epic7_bot/pull/61) +- feat: Made daily button disabled [`7889803`](https://github.com/brunocordioli072/epic7_bot/commit/7889803b3a6d28d3a2cbf0a8edc6a3fb6fcd79e8) +- fix: hunt [`8260caf`](https://github.com/brunocordioli072/epic7_bot/commit/8260caf3126b757d8f4f4c2745b93dcf43e112e3) + #### [v2.0.6-beta](https://github.com/brunocordioli072/epic7_bot/compare/v2.0.5-beta...v2.0.6-beta) > 16 February 2024 -- feat: fast-mode and skip lobby [`#61`](https://github.com/brunocordioli072/epic7_bot/pull/61) +- v2.0.6-beta [`#69`](https://github.com/brunocordioli072/epic7_bot/pull/69) +- Develop [`#68`](https://github.com/brunocordioli072/epic7_bot/pull/68) - Update README.md [`04f8363`](https://github.com/brunocordioli072/epic7_bot/commit/04f83637ee36c01950295b1a44b066c2450a99e0) -- fix: prettier [`efd016f`](https://github.com/brunocordioli072/epic7_bot/commit/efd016f93ba752cf2408ffa51ec26098952d0ddf) - Update README.md [`bae0210`](https://github.com/brunocordioli072/epic7_bot/commit/bae0210693e62a30e48e403b7ba5688bc8aaa74b) #### [v2.0.5-beta](https://github.com/brunocordioli072/epic7_bot/compare/v2.0.4-beta...v2.0.5-beta) diff --git a/packages/app/src/components/AppSider/AppSider.tsx b/packages/app/src/components/AppSider/AppSider.tsx index 7cda1f0..4742213 100644 --- a/packages/app/src/components/AppSider/AppSider.tsx +++ b/packages/app/src/components/AppSider/AppSider.tsx @@ -1,12 +1,5 @@ import { useState } from 'react'; import { Layout, Menu } from 'antd'; -import { - DesktopOutlined, - ShoppingOutlined, - RocketOutlined, - BorderlessTableOutlined, - RetweetOutlined, -} from '@ant-design/icons'; import type { MenuProps } from 'antd'; import './AppSider.css' import { useAppContext } from '../../context/AppContext'; @@ -15,17 +8,19 @@ const { Sider } = Layout; type MenuItem = Required['items'][number]; -function getItem( +function getItem({ label, key, icon, children, disabled }: { label: React.ReactNode, key: React.Key, icon?: React.ReactNode, children?: MenuItem[], -): MenuItem { + disabled?: boolean +}): MenuItem { return { key, icon, children, label, + disabled, } as MenuItem; } @@ -50,7 +45,12 @@ const AppSider: React.FC = () => { return ( setCollapsed(value)} > handleSelect(e.key)} defaultSelectedKeys={['shop']} mode="inline" items={commands.map(el => { - return getItem(el.label, el.label, el.icon) + return getItem({ + label: el.label, + key: el.label, + icon: el.icon, + disabled: el.disabled + }) })} />
Version: {appVersion}
diff --git a/packages/app/src/context/AppContext.tsx b/packages/app/src/context/AppContext.tsx index 928855f..6c7cb22 100644 --- a/packages/app/src/context/AppContext.tsx +++ b/packages/app/src/context/AppContext.tsx @@ -13,6 +13,7 @@ interface Command { python_command: string; table: string icon: JSX.Element; + disabled?: boolean } interface AppContextInterface { @@ -86,6 +87,7 @@ export const AppProvider = ({ children }: { children: any }) => { "python_command": "start_daily", "table": 'daily', "icon": , + "disabled": true }, ]) const [command, setCommand] = useState(commands.find((el: any) => el.label === "Shop") as any) diff --git a/packages/core/epic7_bot/modules/Battle.py b/packages/core/epic7_bot/modules/Battle.py index db48ec4..2008525 100644 --- a/packages/core/epic7_bot/modules/Battle.py +++ b/packages/core/epic7_bot/modules/Battle.py @@ -45,7 +45,7 @@ def do_hunt_rotation(self): logging.info(f"Wait for repeat battling has ended to appear") while ( self.ScreenManager.match_template_on_screen( - template=self.HuntTemplates.repeat_battling_has_ended, percentage=0.6 + template=self.HuntTemplates.repeat_battling_has_ended, percentage=0.7 ) is None ): # change this to match other screen diff --git a/packages/core/view.py b/packages/core/view.py index 4a5d151..5b36b23 100644 --- a/packages/core/view.py +++ b/packages/core/view.py @@ -6,8 +6,7 @@ from epic7_bot.processes.CommandRunner import CommandRunner ROOT_DIR = os.path.dirname(os.path.abspath(__file__)) -CURRENT_APP_VERSION = "v2.0.6-beta" - +CURRENT_APP_VERSION = "v2.0.7-beta" class Api: