mirror of
https://github.com/HarbourMasters/Shipwright.git
synced 2025-07-30 11:39:07 -07:00
Randomizer Auto Location tracker (#1942)
* Initial Auto-Location Tracking * Updates styling for checked items in Check Tracker * Fixes crashing issues with Check Tracker rendering * Auto scroll Check Tracker windows to current area * Checks Tracker only shows checked locations once in game * Fixes issue where Check Tracker would auto-scroll to wrong location when entering a grotto * Fixes gerudo fortress checks showing in tracker when settings have them removed * InfTable Check Location Fixes: Lost Dog Richard, Rolling Gorons, HBA 1000, Thawed Zora * Fixes most Event Chk Inf Checks on Check Tracker, and Frogs * Check Tracker - Song from Malon now works * Check Tracker - Fixes Claim Check check not tracking - Fixes spoiler for Claim Check check when getting Biggoron's Sword - Fixes LACS being spoiled and not tracking * Check Tracker - Fixes #2 for Skull Mask and Mask of Truth checks * Check Tracker - Adds support for merchants - Fixes #7 for Bomchu Salesman - Fixes #12 for Medigoron * Check Tracker - Fixes #8 for Song from Saria * Check Tracker - Fixes #9 for Adult Shooting Gallery * Check Tracker - Fixes #10 for Composer Grave * Check Tracker - Fixes #14 for Song from Ocarina of Time * Check Tracker - Fixes #16 for Shooting the Sun * Check Tracker - Fixes #19 for Darunia's Joy * Save Editor - Adds missing label for Treasure Chest Game * Check Tracker - Fixes Great Faries checks * Check Tracker - Fixes Sheik at Temple * Check Tracker - Fixes Great Fairy auto-scroll to wrong location * Check Tracker - Updates blue warp checks - Fixes Bongo Bongo and Twinrova checks * Check Tracker - Fixes Dampe's Gravedigging Tour * Check Tracker - Fixes Prescription to King Zora * Check Tracker - Fixes Bazaar showing under wrong area on tracker between adult/child * Check Tracker - Fixes scroll for Hyrule Market and Bazaar * Check Tracker - Fixes giving Adult Trade Items shown on tracker: Broken Sword, Saw, Cojiro, Eyeball Froge, and Eyedrops * Cleans up item_location * Check Tracker - Item List - Fixes item list not updating when changing seeds/options - Separates item exclusion list from item check list - Clean up comments * Check Tracker - Adds Skip functionality to buttons * Check Tracker - Refactors adult trade items to RandomizerInf * Check Tracker - Fixes an issue where any time an item is removed the tracker would cause an application crash * Check Tracker - Item names are now dependent on file language * Check Tracker - Fixes Gerudo Card check not showing in Fast setting * Reorders headers to (hopefully) avoid CI build conflicts on linux/consoles * Explicitly defines vector header in randomizer.h to fix compile errors * Complete Refactor of Check Tracker ImGui * Adds missing check tracker files to CMakeLists * Reverts the Item_location whitespace cleanup fromad10807c
* Check Tracker - Loading Fixes - Fixes a bug where loading a save file a second time would add all the checks again - Fixes a bug where the check tracker would not render at all until in a save file * Check Tracker - Fixes a bug where checks would sometimes fail to load * Check Tracker - Fixes duplicated checks when using Only on Pause or Only on Combo * Check Tracker - Works around issue where single characters don't show in EnhancementCombobox, and fixes a label for combo buttons held option * Check Tracker - Applies all Check Tracker changes to Item Location * Check Tracker - Updated Check List - Adds Link's pocket, either in KF or HM depending on starting age - Supports Scrubs and Merchants - Uses enums instead of magic numbers - Updates DC Scrub Short Names for MQ * Check Tracker - Adds a performance mode option * Check Tracker - List Fixes (requires new rando generation) - Fixes Frogs Rupees always visible - Fixes Kokiri Sword Chest not showing - Fixes Weird Egg not showing * Check Tracker - MQ List basic support * Check Tracker - MQ/Vanilla anti-spoilers * Check Tracker - Collecting a compass now spoils the area * Check Tracker - Basic Vanilla Support and fixes - Vanilla items show in check tracker, even if many won't auto check - Fixes an issue with Gerudo Fortress Keys - Refactors IsVisibleInCheckTracker to randomizer_check_tracjer * Check Tracker - Fixes merge conflict from08a487f35e
* Check Tracker - Fixes tracker loading as Floating when default value is set to Windowed * Randomizer Location Exclusion List - Adds Scrubs, Merchants, Shops. Adult Trade items, MQ Dungeons, and Bean Salesman - Fixes Kokiri Sword Chest, Weird Egg, and Frog Song Rupees from misbehaving - Updates Gerudo Fortress logic to be dependent on Open/Fast/Normal Fortress - Removes Invalid Check - Adds RO Enum for MQ settings - Updates magic values to RO enum * Location Exclusion List - Scrubs that are always randomized now always show on the list * For now, removes some extra code only needed for a Check Tracker. * Randomizer Location Exclusion List - Fixes Eyeball Frog from showing up when Adult Trade Items was off * Location Tracker - Updates Eyedrops to use RandomizerInf instead of Chest * Check Tracker - Fixes a bug where Link's Pocket item wasn't acting as checked for area item count * Check Tracker - Fixes a bug where Locations would incorrectly say Vanilla due to the first check in the area being a non-MQ check * Check Tracker - Fixes a crash when Check Tracker is docked but not visible * Check Tracker - Fixes areas being spoiled when loading different save files * Check Tracker - Only reset variables if they are initialized * Check Tracker - Cleans up old comments, unused variables, methods, and macros, adds language TODOs, * Check Tracker - Readds rainbow UI elements after Cosmetics Editor refactor * Check Tracker - Removal of flag lookup that was refactored, no longer needed header, and some trivial whitespace fixes. * Check Tracker - Refactors Index to Bitmask code to a macro * Check Tracker - Changes ordering from alphabetical to RandomizerCheck ordering * Check Tracker - Wraps everything in a namespace to avoid global variable usage * Check Tracker - Explicitly defines for-loop scope * Check Tracker - refactors dungeon lookup from static array to function * Fixes a bug when using EnhancementColor with alpha * Check Tracker - Refactors all colour to use direct conversions * Check Tracker - refactors settings loading and check visibility for readability * Check Tracker - Fixes a bug where the wrong label showed on the Check Tracker BG Color * UIWidgets - Adds Alpha bar to EnhancementColor when using alpha parameter
This commit is contained in:
parent
40cb4a6d7d
commit
b56e8926f0
19 changed files with 1276 additions and 96 deletions
|
@ -894,6 +894,30 @@ std::map<RandomizerCheck, RandomizerCheckObject> RandomizerCheckObjects::GetAllR
|
|||
return rcObjects;
|
||||
}
|
||||
|
||||
std::map<SceneID, RandomizerCheckArea> rcAreaBySceneID = {};
|
||||
std::map<SceneID, RandomizerCheckArea> RandomizerCheckObjects::GetAllRCAreaBySceneID() {
|
||||
//memoize on first request
|
||||
if (rcAreaBySceneID.size() == 0) {
|
||||
for (auto& [randomizerCheck, rcObject] : rcObjects) {
|
||||
rcAreaBySceneID[rcObject.sceneId] = rcObject.rcArea;
|
||||
}
|
||||
//Add checkless Hyrule Market areas to the area return
|
||||
for (int id = (int)SCENE_ENTRA; id <= (int)SCENE_MARKET_RUINS; id++) {
|
||||
rcAreaBySceneID[(SceneID)id] = RCAREA_MARKET;
|
||||
}
|
||||
}
|
||||
return rcAreaBySceneID;
|
||||
}
|
||||
|
||||
RandomizerCheckArea RandomizerCheckObjects::GetRCAreaBySceneID(SceneID sceneId) {
|
||||
std::map<SceneID, RandomizerCheckArea> areas = GetAllRCAreaBySceneID();
|
||||
auto areaIt = areas.find(sceneId);
|
||||
if (areaIt == areas.end())
|
||||
return RCAREA_INVALID;
|
||||
else
|
||||
return areaIt->second;
|
||||
}
|
||||
|
||||
void RandomizerCheckObjects::UpdateImGuiVisibility() {
|
||||
for (auto& [randomizerCheck, locationIt] : rcObjects) {
|
||||
locationIt.visibleInImgui = (
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue