mirror of
https://github.com/Dingo-Shenanigans/ReSkate.git
synced 2026-10-27 22:07:07 +01:00
A third ReSkate tab in the game's pause menu (native_menu.cpp slot 2, the Store's tab art), drawn by the overlay as the other two are (mod_manager_page.inl, included into hub_page.cpp): - BROWSE: search, categories in a panel of their own (shown only, hidden or either, kept in the profile), sort, a featured carousel and rows (most popular, recently updated, new, the biggest categories), a grid for results, and a mod's own page with its README, what it brings with it, and INSTALL, switch on or off and uninstall. Works from a controller: the carousel's card is one stop that left and right turn, and B goes back from a mod's page (the page's Back is held meanwhile). - MY MODS: the Mods folder with the states the ReSkate menu shows; UPDATES: Update all. - The foot of the page shows the install's progress and the apply's, and Apply (View on a pad). Leaving the menu with changes not applied asks first (a two-answer card in message_card.cpp, answered by the runtime as the message is); LATER closes the menu. Behind it, Extension/Assets/mod_store: Thunderstore's listing (cached on disk), the installed mods, and a queue that downloads and installs packages with their dependencies, updates and uninstalls them. An update or uninstall of a mod the game holds open waits in Mods/.reskate-pending and the launcher makes it before the next start (launcher_mods::apply_pending). Package icons load into their own SRV slots (store_icons.cpp), sharing the launcher's icon cache. Tests: mod_store_view (search, categories, the front page's rows, install plans), the pending updates and uninstalls in mod_manager_tests, and the third tab in native_menu_view_tests.
30 lines
1.7 KiB
C++
30 lines
1.7 KiB
C++
#pragma once
|
|
#include <cstdint>
|
|
#include <string>
|
|
|
|
namespace dingosdk::overlay { struct CallbacksV3; struct HubPage; }
|
|
|
|
namespace dingosdk::multiplayer {
|
|
// Call after the session tick, including while disconnected. All UI model
|
|
// operations execute on the client thread under the native model lock.
|
|
void tick_native_menu(std::uintptr_t base, bool loading) noexcept;
|
|
// Run on the client thread BEFORE submitting a map load, while widget assets
|
|
// and dynamic schemas still exist. Returns false if cleanup could not finish.
|
|
bool prepare_native_menu_level_load(std::uintptr_t base) noexcept;
|
|
// Register with the validated client-transition hook, before the native handler
|
|
// releases assets. Suspends updates through native loads, permanently on exit.
|
|
void native_menu_before_level_transition(std::uintptr_t base, unsigned next) noexcept;
|
|
// Uses the same validated runtime queues as the overlay. The reader must be a
|
|
// snapshot reader; it must not consume the overlay's console log cursor.
|
|
void set_native_menu_callbacks(const overlay::CallbacksV3& callbacks);
|
|
// Whether one of ReSkate's pages (Multiplayer, Mod Options, Mod Manager) is the pause menu's page on
|
|
// screen right now, and which. Any thread: the overlay draws the page from it
|
|
// (overlay::HubPageFeed).
|
|
overlay::HubPage native_menu_page() noexcept;
|
|
// While held, the Mod Manager page's Back does nothing, so B and Escape stay the overlay's: they
|
|
// leave a mod's page for the list instead of closing the pause menu. Any thread.
|
|
void hold_native_menu_back(bool held) noexcept;
|
|
// Whether the game's own pause menu is up, on any of its pages. Any thread.
|
|
bool native_pause_menu_open() noexcept;
|
|
} // namespace dingosdk::multiplayer
|