From 19b1427ee158a4414d1548b0b22a7f77e4d96346 Mon Sep 17 00:00:00 2001 From: Eric Date: Wed, 7 Jun 2023 20:12:59 -0700 Subject: [PATCH] fixed a bug with menu button unclickable in game --- .efrocachemap | 56 ++++++++++++++--------------- CHANGELOG.md | 4 ++- src/assets/ba_data/python/baenv.py | 2 +- src/ballistica/base/input/input.cc | 6 ++-- src/ballistica/base/ui/ui.cc | 9 +---- src/ballistica/base/ui/ui.h | 11 +----- src/ballistica/shared/ballistica.cc | 2 +- 7 files changed, 38 insertions(+), 52 deletions(-) diff --git a/.efrocachemap b/.efrocachemap index 9548ebb9..2a959f04 100644 --- a/.efrocachemap +++ b/.efrocachemap @@ -4072,26 +4072,26 @@ "build/assets/workspace/ninjafightplug.py": "https://files.ballistica.net/cache/ba1/c5/09/4f10b8a21ba87aa5509cff7a164b", "build/assets/workspace/onslaughtplug.py": "https://files.ballistica.net/cache/ba1/ff/0a/a354984f9c074dab0676ac7e4877", "build/assets/workspace/runaroundplug.py": "https://files.ballistica.net/cache/ba1/2a/1c/9ee5db6d1bceca7fa6638fb8abde", - "build/prefab/full/linux_arm64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/5d/c0/b0c3f97dc8be7a1ce7cefda5571d", - "build/prefab/full/linux_arm64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/85/df/ff042339b652dd67e113df0bf943", - "build/prefab/full/linux_arm64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/2e/d6/851e329bcc1a648dd0ee2688080b", - "build/prefab/full/linux_arm64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/76/6a/8f0b4eaa499f42463039eca0a2a7", - "build/prefab/full/linux_x86_64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/9c/ea/e2f1683e1e043f3a47c39066b183", - "build/prefab/full/linux_x86_64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/5a/62/988f1d63ed87e1beaea96ead800e", - "build/prefab/full/linux_x86_64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/24/0e/f5291cfe96963aed5e047ca8dc3f", - "build/prefab/full/linux_x86_64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/f9/65/ff80216ac4bcae2f8a8c4d484e2b", - "build/prefab/full/mac_arm64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/6c/bc/51f10c04edc010a6fccb1bea092c", - "build/prefab/full/mac_arm64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/70/4f/0726bcff9a37b6f167e7cacc0003", - "build/prefab/full/mac_arm64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/05/3a/8fef724c7c849945d9a2a003f3dd", - "build/prefab/full/mac_arm64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/f3/34/23ab44d7d443f2b49609b1b325b2", - "build/prefab/full/mac_x86_64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/a7/28/05bbf013c1399fb85376a4913511", - "build/prefab/full/mac_x86_64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/9c/d0/d1086359ab9e0b6c3e609fe67e20", - "build/prefab/full/mac_x86_64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/8f/6f/e0e3c5ae85b61b37f7f437e0102b", - "build/prefab/full/mac_x86_64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/20/3a/1e706ba99c9e663864b13ba9440d", - "build/prefab/full/windows_x86_gui/debug/BallisticaKit.exe": "https://files.ballistica.net/cache/ba1/0a/59/18879e3ee43cb81e63c1e01e2390", - "build/prefab/full/windows_x86_gui/release/BallisticaKit.exe": "https://files.ballistica.net/cache/ba1/4b/c5/b5ee2c4b820387d2f6654231c5fb", - "build/prefab/full/windows_x86_server/debug/dist/BallisticaKitHeadless.exe": "https://files.ballistica.net/cache/ba1/94/2d/012b5cc35c20f0e92036724bd302", - "build/prefab/full/windows_x86_server/release/dist/BallisticaKitHeadless.exe": "https://files.ballistica.net/cache/ba1/f6/c1/b309507f58e6d5325e52b441310b", + "build/prefab/full/linux_arm64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/16/45/d88feac0b70205ef727adb8e0539", + "build/prefab/full/linux_arm64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/6e/1e/4c65c27f16121fb19c1986975ac6", + "build/prefab/full/linux_arm64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/c4/79/dda03acdac10dda499c97098b6df", + "build/prefab/full/linux_arm64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/5c/19/3f9e1db269df76ec37fc0e62f061", + "build/prefab/full/linux_x86_64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/b0/e0/92ab1f913417c9854a726e1dccc7", + "build/prefab/full/linux_x86_64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/a6/52/2df57c46b96ffe5e4f5fe7a738db", + "build/prefab/full/linux_x86_64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/71/aa/530e5f451284e768c5ed4d4a4a80", + "build/prefab/full/linux_x86_64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/27/b3/633f739fced5ac019aa219911ea6", + "build/prefab/full/mac_arm64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/70/65/86bf214eef166a3a508a296dcef9", + "build/prefab/full/mac_arm64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/02/ab/60c078c55c734699b6e15295277c", + "build/prefab/full/mac_arm64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/1c/3d/d8ec8383ae4a6bcfe7bca4274420", + "build/prefab/full/mac_arm64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/d0/01/5da440631934aa5d2451e0bd59f7", + "build/prefab/full/mac_x86_64_gui/debug/ballisticakit": "https://files.ballistica.net/cache/ba1/15/0a/8b0b6ea93fa9b4b92c5a34885574", + "build/prefab/full/mac_x86_64_gui/release/ballisticakit": "https://files.ballistica.net/cache/ba1/dd/a2/8a1904e5c440b7aa47e40600c9f7", + "build/prefab/full/mac_x86_64_server/debug/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/52/1d/c80d4632d100260e2ff562171c59", + "build/prefab/full/mac_x86_64_server/release/dist/ballisticakit_headless": "https://files.ballistica.net/cache/ba1/b0/f3/296763c20e84cf065626882196aa", + "build/prefab/full/windows_x86_gui/debug/BallisticaKit.exe": "https://files.ballistica.net/cache/ba1/6a/82/d66f2f99f003085ed785e602f0e2", + "build/prefab/full/windows_x86_gui/release/BallisticaKit.exe": "https://files.ballistica.net/cache/ba1/bd/fd/a1c164169e9775cceee8ed801009", + "build/prefab/full/windows_x86_server/debug/dist/BallisticaKitHeadless.exe": "https://files.ballistica.net/cache/ba1/0d/d8/13bb9bf1f71f8e8867d4ed7ac1d6", + "build/prefab/full/windows_x86_server/release/dist/BallisticaKitHeadless.exe": "https://files.ballistica.net/cache/ba1/ec/b1/c0c0041a6b3cfe32330b5c84bd59", "build/prefab/lib/linux_arm64_gui/debug/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/86/b8/5aaa1f826bdb5abe5ad57b0fc0c9", "build/prefab/lib/linux_arm64_gui/release/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/d4/8e/70f425b0259655a3efe710846cce", "build/prefab/lib/linux_arm64_server/debug/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/f5/71/9c18e9e43026aa763c5ac6e5b445", @@ -4108,14 +4108,14 @@ "build/prefab/lib/mac_x86_64_gui/release/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/9b/30/f27a1766b6ce7c5dc63c0c5a1f65", "build/prefab/lib/mac_x86_64_server/debug/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/8e/97/dc049e4ff4ad2c808a6f5c685dc7", "build/prefab/lib/mac_x86_64_server/release/libballistica_plus.a": "https://files.ballistica.net/cache/ba1/c1/83/aacd3c0321301d6eaf81eb656456", - "build/prefab/lib/windows/Debug_Win32/BallisticaKitGenericPlus.lib": "https://files.ballistica.net/cache/ba1/61/06/efe333f8f4d86881ec8f06f3aea9", - "build/prefab/lib/windows/Debug_Win32/BallisticaKitGenericPlus.pdb": "https://files.ballistica.net/cache/ba1/c1/2e/9f8a5af787b03bc2d17ac75c5fd1", - "build/prefab/lib/windows/Debug_Win32/BallisticaKitHeadlessPlus.lib": "https://files.ballistica.net/cache/ba1/7c/55/99886cad6f0aefe8f39f1a298e25", - "build/prefab/lib/windows/Debug_Win32/BallisticaKitHeadlessPlus.pdb": "https://files.ballistica.net/cache/ba1/15/af/3a577c40161caaf4285398eb2fe1", - "build/prefab/lib/windows/Release_Win32/BallisticaKitGenericPlus.lib": "https://files.ballistica.net/cache/ba1/67/d3/ad793ef717d79872d7c6614b444e", - "build/prefab/lib/windows/Release_Win32/BallisticaKitGenericPlus.pdb": "https://files.ballistica.net/cache/ba1/d5/0f/b88cf9b5fed9dcb11ab24377ccd8", - "build/prefab/lib/windows/Release_Win32/BallisticaKitHeadlessPlus.lib": "https://files.ballistica.net/cache/ba1/1b/90/013c8c3f3491bd79b61760b78ceb", - "build/prefab/lib/windows/Release_Win32/BallisticaKitHeadlessPlus.pdb": "https://files.ballistica.net/cache/ba1/81/ce/37e84fdddf7ed8c494c7a1a73cd3", + "build/prefab/lib/windows/Debug_Win32/BallisticaKitGenericPlus.lib": "https://files.ballistica.net/cache/ba1/f4/e3/51c0f6dab525d600ebedaea36ad3", + "build/prefab/lib/windows/Debug_Win32/BallisticaKitGenericPlus.pdb": "https://files.ballistica.net/cache/ba1/f4/50/5c3d1fb95c5ce0de017205f16945", + "build/prefab/lib/windows/Debug_Win32/BallisticaKitHeadlessPlus.lib": "https://files.ballistica.net/cache/ba1/08/6d/5d9aa2e3edc78af51fba7e27f71e", + "build/prefab/lib/windows/Debug_Win32/BallisticaKitHeadlessPlus.pdb": "https://files.ballistica.net/cache/ba1/84/93/e9e5fe8e5dacebdb8ac359f12c3f", + "build/prefab/lib/windows/Release_Win32/BallisticaKitGenericPlus.lib": "https://files.ballistica.net/cache/ba1/83/08/dd85f77bded28958ce1eccc94434", + "build/prefab/lib/windows/Release_Win32/BallisticaKitGenericPlus.pdb": "https://files.ballistica.net/cache/ba1/ba/cf/094acd3d64454e199e992b4f909d", + "build/prefab/lib/windows/Release_Win32/BallisticaKitHeadlessPlus.lib": "https://files.ballistica.net/cache/ba1/a4/95/b73b4d0726da5fb638d049681101", + "build/prefab/lib/windows/Release_Win32/BallisticaKitHeadlessPlus.pdb": "https://files.ballistica.net/cache/ba1/ce/2e/ae918b603dd8f6876680ba6c0064", "src/assets/ba_data/python/babase/_mgen/__init__.py": "https://files.ballistica.net/cache/ba1/52/c6/c11130af7b10d6c0321add5518fa", "src/assets/ba_data/python/babase/_mgen/enums.py": "https://files.ballistica.net/cache/ba1/38/c3/1dedd5e74f2508efc5974c8815a1", "src/ballistica/base/mgen/pyembed/binding_base.inc": "https://files.ballistica.net/cache/ba1/75/9f/bcf597b362c9f2480cb348188bdd", diff --git a/CHANGELOG.md b/CHANGELOG.md index 7a32c1c3..d6723fba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,4 +1,4 @@ -### 1.7.20 (build 21064, api 8, 2023-06-07) +### 1.7.20 (build 21066, api 8, 2023-06-07) - This seems like a good time for a `refactoring` release in anticipation of changes coming in 1.8. Basically this means that a lot of things will be @@ -292,6 +292,8 @@ problem within the plugin's code. This is now correctly handled and reported. Which is good because this situation will come up a lot for people upgrading old plugins which reference 'ba' and other modules that no longer exist. +- (build 21064) Fixed an issue where the menu button wasn't clickable in-game + (thanks for the heads up Irvin). ### 1.7.19 (build 20997, api 7, 2023-01-19) diff --git a/src/assets/ba_data/python/baenv.py b/src/assets/ba_data/python/baenv.py index 5e36f734..9d59cb08 100644 --- a/src/assets/ba_data/python/baenv.py +++ b/src/assets/ba_data/python/baenv.py @@ -28,7 +28,7 @@ if TYPE_CHECKING: # Build number and version of the ballistica binary we expect to be # using. -TARGET_BALLISTICA_BUILD = 21064 +TARGET_BALLISTICA_BUILD = 21066 TARGET_BALLISTICA_VERSION = '1.7.20' _g_env_config: EnvConfig | None = None diff --git a/src/ballistica/base/input/input.cc b/src/ballistica/base/input/input.cc index b7b11f48..fdc682e9 100644 --- a/src/ballistica/base/input/input.cc +++ b/src/ballistica/base/input/input.cc @@ -1263,9 +1263,9 @@ void Input::HandleMouseDown(int button, const Vector2f& position) { return; } - if (!g_base->ui->MainMenuVisible()) { - return; - } + // if (!g_base->ui->MainMenuVisible()) { + // return; + // } mark_input_active(); diff --git a/src/ballistica/base/ui/ui.cc b/src/ballistica/base/ui/ui.cc index 4ed51333..4a707510 100644 --- a/src/ballistica/base/ui/ui.cc +++ b/src/ballistica/base/ui/ui.cc @@ -97,13 +97,6 @@ auto UI::MainMenuVisible() const -> bool { return false; } -// FIXME should be same as MainMenuVisible. -// auto UI::IsWindowPresent() const -> bool { -// return ((screen_root_widget_.Exists() && screen_root_widget_->HasChildren()) -// || (overlay_root_widget_.Exists() -// && overlay_root_widget_->HasChildren())); -//} - auto UI::PartyIconVisible() -> bool { if (g_base->HaveUIV1()) { return g_base->ui_v1()->PartyIconVisible(); @@ -211,7 +204,7 @@ auto UI::ShouldHighlightWidgets() const -> bool { // Show selection highlights only if we've got controllers connected and only // when the main UI is visible (dont want a selection highlight for toolbar // buttons during a game). - return (g_base->input->have_non_touch_inputs() && MainMenuVisible()); + return g_base->input->have_non_touch_inputs() && MainMenuVisible(); } auto UI::ShouldShowButtonShortcuts() const -> bool { diff --git a/src/ballistica/base/ui/ui.h b/src/ballistica/base/ui/ui.h index f3b4a1a3..bb796f30 100644 --- a/src/ballistica/base/ui/ui.h +++ b/src/ballistica/base/ui/ui.h @@ -25,11 +25,8 @@ // Predeclare a few things from ui_v1. namespace ballistica::ui_v1 { -class ContainerWidget; -class RootWidget; class Widget; -class RootUI; -} // namespace ballistica::ui_v1 +} namespace ballistica::base { @@ -50,8 +47,6 @@ class UI { void Reset(); - // auto IsCurrentContext() const -> bool; - /// Pop up an in-game window to show a url (NOT in a browser). /// Can be called from any thread. void ShowURL(const std::string& url); @@ -70,10 +65,6 @@ class UI { void HandleLegacyRootUIMouseUp(float x, float y); auto PartyWindowOpen() -> bool; - /// Return whether there is UI present in either the main or overlay - /// stacks. Generally this implies the focus should be on the UI. - // auto IsWindowPresent() const -> bool; - void Draw(FrameDef* frame_def); // Returns the widget an input should send commands to, if any. diff --git a/src/ballistica/shared/ballistica.cc b/src/ballistica/shared/ballistica.cc index 189fa858..be5db71e 100644 --- a/src/ballistica/shared/ballistica.cc +++ b/src/ballistica/shared/ballistica.cc @@ -39,7 +39,7 @@ auto main(int argc, char** argv) -> int { namespace ballistica { // These are set automatically via script; don't modify them here. -const int kEngineBuildNumber = 21064; +const int kEngineBuildNumber = 21066; const char* kEngineVersion = "1.7.20"; auto MonolithicMain(const core::CoreConfig& core_config) -> int {