In EnTest_Destroy, the check for nearby Stalfos uses
Actor_FindNearby which includes killed actors (update == NULL)
still in the linked list. When multiple Stalfos die in the
same frame or in quick succession, the last one to be destroyed
still sees the others in the actor list and skips the BGM
restore call (func_800F5B58).
Replace Actor_FindNearby with a custom check that only counts
living actors (update != NULL). This ensures the miniboss BGM
is properly restored to the dungeon theme when the last
Stalfos in a group is defeated.
Co-authored-by: serprex <159546+serprex@users.noreply.github.com>
So this fixes some logical errors with loading the resources so its checking they exist before trying to test-load them... It also added a cache for the alt skeleton by tunic type so we arent constantly trying to reassign the tunic (This change in particular may prevent instant model swapping depending how the model swap with custom content is handled if loaded in a menu like NEI does)... Current system was just spamming that check over and over and trying to reload skeletons constantly so I opted for detecting if the tunic actually changes THEN allow a recheck here, otherwise exit out early. The skeleton.cpp and skeleton.h files can be reverted if suspected that will interfere with intended custom model usage.
Triforce Pieces can now be tokens for bridge or ganon's soul. & can be tokens for multiple rewards
Wincon can now be arbitrary conditions
Ganon's Soul (removed from existing boss soul options) can now be arbitrary conditions
Co-authored-by: Pepper0ni <93387759+Pepper0ni@users.noreply.github.com>
When 2 players are in the fairy fountain and 1 activates the great fairy cutscene, it can force the other player into the cutscene as well, and I've had some crashes arbitrarily too so this guarentees that doesnt happen.
Fixes an issue where actors do not load properly after creating a savestate and then going to either a new scene or loading a different area of the map (graveyard near shadow -> main section of graveyard dampes door is missing after loading again.)
Previous co op softlock fix introduced a possible trial softlock making barrier never dissappear. This not only ensures that softlock cant happen, it syncs the trial flags in real time and allows all cutscenes to finish playing to properly remove the barrier even if the beams are physically visible in your game.
When a scene-forced/fixed camera (e.g. the Spirit Temple boulder-room
alcoves, CAM_SET_PREREND_FIXED / Camera_Fixed3) drives the view, the Free
Look angles in play->camX/camY are left untouched while manualCamera stays
set. On exit, Camera_Free resumed from those stale pre-alcove angles, so
the camera snapped/reversed instead of following the player out.
This does NOT change the forced-camera behavior: the alcove still clamps
exactly as the game intends. It only fixes the hand-off back to Free Look:
when Camera_Free resumes after another camera function drove the previous
frame (detected via a frame-number gap), the free-look yaw/pitch are
re-seeded from the camera's current orientation so the view continues from
where it was left.
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
GetAvailableAudioBackends()/GetAvailableWindowBackends() can report a backend
that has no entry in the static name maps (e.g. a newly added or platform-
specific backend), which made audioBackendsMap.at()/windowBackendsMap.at()
throw std::out_of_range and crash. Look up with find() (single lookup) and skip
backends that aren't named instead of dereferencing a missing key.
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>
* Avoid `randomizer_check_tracker.h` in widely used `randomizer.h` due to transitive `libultraship.h`/`UIWidgets.hpp` inclusion
* Avoid `libultraship.h` inclusion in heavily used `GameInteractor.h` header
* Remove unused libultraship includes
* Break huge unneeded transitive include chain (via UIWidgets.hpp)
This avoids that changing just UIWidgets.hpp, for example, would retrigger a rebuild of like half the project.
There were a huge transitive include chains, mostly via MenuTypes.h and UIWidgets.hpp. Because of that, I'm splitting UIWidgets into a second header file UIWidgetOptions.hpp, which can be consumed by MenuTypes.h. MenuTypes.h is split into BackendTypes.h to avoid pulling in Fast3D/Windowing/GUI stuff into unrelated code.
Example chain, one of many:
libultraship.h <- UIWidgets.hpp <- MenuTypes.hpp <- randomizer/option.h <- randomizer/item_location.h <- trial.h <- static_data.h <- SeedContext <- (basically all randomizer related sources, lots of other sources in Enhancement, more...)
* Avoid libultraship.h in Notification.h and ObjectExtension.h; these headers are also heavily used
* Add missing include
* Remove unused libultraship includes
* Include only ship/window/GuiWindow.h in GUI-related headers instead of libultraship.h
* Cleanup ConfigUpdater.h and playthrough.cpp
* Remove libultraship.h from Anchor.h and fix transitive dependencies in OTRGlobals.cpp
* Remove unused libultraship.h includes in Anchor code