Commit graph

70 commits

Author SHA1 Message Date
Malkierian
e673eaefb6
Warnings Round 2 (mostly Rando) (#5486)
* Handle virtually all warnings in `soh/Enhancements/randomizer`.
Handle order of operations warning in FasterHeavyBlockLift.

* Missed a few.

* Add float-specific versions of some M_PI and M_SQRT defines, and swap them in for the static casts in draw.cpp.

* Swap a static cast for M_PIf in check tracker code.
2025-05-16 21:54:36 -07:00
Malkierian
23a5198986
Merge pull request #5497 from HarbourMasters/develop-blair
blair -> dev
2025-05-16 21:46:00 -07:00
Philip Dubé
d790ea4bce
use LOGIC_BUY_STICKS / LOGIC_BUY_NUTS in logic (#5251) 2025-05-01 19:34:56 -07:00
Pepper0ni
103a36e5fe
fix MQGTG right side resetting (#5442) 2025-04-22 20:38:14 -07:00
Malkierian
02ef33393a
Implements a rand inf for Ruto's letter to apply to logic to track it separate from the underwater item check. (#5405) 2025-04-15 13:13:30 -04:00
Malkierian
c12349a7a3
Add check for bean inventory slot having bean on it to allow availability to succeed with ammo count 0. (#5370) 2025-04-09 16:58:06 -04:00
Pepper0ni
88154d78c8
Fix Market Grass and Crate logic (#5340)
* fix market grass and crate logic

* apply clang
2025-04-08 08:26:04 -07:00
Christopher Leggett
b71a0c5803
Fix checking gSaveContext for used small keys (#5346) 2025-04-07 19:07:07 -04:00
Archez
8f126344a4
Apply clang-format to files (#5273) 2025-04-01 22:33:38 -04:00
xxAtrain223
2bde8fbe5d
Use GetDungeonFromScene (#5271)
* Use GetDungeonFromScene.

* Remove SceneToDungeon map.
2025-03-31 21:18:07 -07:00
xxAtrain223
35d17b8b0b
Available Randomizer Checks (#5091)
* Calculate accessible checks and show them in the check tracker.

* Added added DoorUnlocked checks to the Fire Temple doors.

This is needed when calculating Accessible checks while playing and using small keys. Otherwise checks will appear unaccessible because Keys have been used.

* Changed RecalculateAccessibleChecks to use the logic ReachabilitySearch.

* Reverted DoorUnlocked changes.

* Added recalculate_accessible_checks debug console command.

* Skip CanBuy check when calculating accessible checks, it spoils that some items can't be bought with the current wallet.

* Set RAND_INF_ZELDAS_LETTER.

* Don't add locations to the pool when calculating accessible checks.

* Save and Load randomizer trick options.

* Get the number of used small keys.

* Added check if bean was planted.

* Show number of Accessible checks in each Area.

* Accounted for missing RG_POCKET_CUCCO in logic HasItem and ApplyItemEffect.

* Show accessible checks via an icon.

* Check shop price against current wallet.

* Recalculate Accessible Checks in CheckTrackerLoadGame instead of LoadFile.

* RecalculateAccessibleChecks on save.

* Don't unset Zelda's Letter.

* Added Only Show Available Checks checkbox.

* Rename Accessible Checks to Available Checks.

* Added option to Enable Available Checks.

* Remove debug console to recalculate available checks, this can now be done by toggling Enable Available Checks in the settings.

* Remove extra requiredTrial.

* Default "Hide unshuffled shop item checks" unchecked.

* Updated GetSmallKeyCount to return int8_t.

* Default AmmoDrop to true until the setting is implemented.

* Fixed Sleeping Waterfall timesaver.

* Updated Only Show Available Checks to let Show Hidden Items reveal hidden available checks.

* Revert "Don't unset Zelda's Letter."

This reverts commit 4b5903940f.

* Set RAND_INF_ZELDAS_LETTER.

* Revert "Fixed Sleeping Waterfall timesaver."

This reverts commit 9b62fd5297.

* Added isMagicAcquired to Logic::HasItem.

* GetDungeonSmallKeyDoors return static emptyVector.

* Comment out AmmoCanDrop in ResetLogic.

* Added location_access CanBuy todo.

* Reverted Get and Set SmallKeyCount to use uint8_t and handled -1 keys.

* Added todo for MQ Water GetUsedSmallKeyCount.
2025-03-30 22:18:42 -07:00
Pepper0ni
c38205ddcf
Apply better big poe logic (#5245) 2025-03-30 23:51:00 +02:00
Philip Dubé
b417b87d1c
Shuffle cleanup (#5222)
* Shuffle cleanup

* Grass can be cut with Goron's Bracelet
* Gohma's grass can be cut without defeating Gohma

* more whitespace
2025-03-27 07:48:37 +01:00
Eric Hoey
47c653a0e5
[Rando] Shuffle Crates (#5017)
* location list + enums

* add identity function

* add new files + hook handlers + settings + crate struct

* add dungeon struct + large crate locations

* fix wasteland name + add overworld hints

* add dungeon hints

* add to item pool

* opt desc + check tracker + overworld locs

* add VB funcs + fix fire locs + dmc crate + shuffle crates not pots again

* fix crate option def

* fix gy crate area

* add ow locs

* context + more location_list

* fix kak crate

* add gv child crates + make exceptions for OOB GF crates + fix GF rht name

* finish adding gv crates + align GF child crates + fix adult GF locs

* fix VB draw + adjust color

* begin logic

* add child archery crate + overworld logic

* deku + dc + rename dc locs

* gtg + spirit

* fire temple logic

* start water temple + some renaming

* finish water temple + renames

* fix dmc crate

* remove child GV + GF crates :( + simplify hints + french

* fix dungeon hint + add french attempt

* cleanup

* smol crate loc list + enums

* setup small crates

* fix fire temple fairy hints

* add logic

* fix small crates + locs

* align GF crates without moving

* add child GV-GF crates for No Logic

* convert to shipinit

* whitespace

* remove old comments

* assets

* proper cap

* better comments on not-shuffled crates

* update for context changes

* update for rest of context changes

* cleanup

* fix shadow hint RHT

* more cleanup

* count to three

* child gf logic

* gv cow crate

* loc list spacing

* remove redundant small crates

* remove left over vb funcs

* split out location list

* fix van spawns

* move NL crates to new type

* rm whitespace

* more whitespacing

* more more whitespace

* update VB

* restore support for custom models

* prep dungeon for develop

* update context for location changes

* finish context post-develop merge

* add heart crates to CSMC

* update loc list + logic fix

* update breakroom crates to adult only

* newline to make github happy

* revise vbshoulds

* formatting sheesh

* update vb info

* BRACKET

* whitespacent

* ws finalfinal
2025-03-26 21:32:32 +01:00
Philip Dubé
b7b5949bc4
Some location access fixes (#5121)
* Some location access fixes

Split out a few fixes I've made while working on #5105

* assert false

* IC feedback
2025-03-19 12:42:18 +01:00
Pepper0ni
dd7dee8f07
Fix finite shields getting thier effect applied in SCL (#5130) 2025-03-19 11:15:55 +01:00
Pepe20129
06387060d6
Trade cleanup (#4971)
* Move adult trade to flags

* Move child trade to flags

* Fix vanilla

* Address review

* Rename `trade_shuffle` to `ShuffleTradeItems`

* Fix mac build

* Update GIVanillaBehavior.h

* Update z_kankyo.c

* Update z_en_heishi2.c
2025-02-25 12:09:01 +01:00
Philip Dubé
db41c6513b
Move boss kill logic into CanKillEnemy (#5000)
* Move boss kill logic into CanKillEnemy

Added hammer as being able to defeat Morpha

* add hammer vs gohma, king dodongo, & twinrova
2025-02-25 10:25:45 +01:00
Philip Dubé
e516f45e23
logic: allow finding big poe in bottle for reward logic (#5075)
* logic: allow finding big poe in bottle for reward logic

only applies when big poe count is set to 1

* Allow multiple big poe bottles for when big poe requirement > 1
2025-02-25 09:30:05 +01:00
Philip Dubé
e5ddcce7f2
use CanKillEnemy more (#4867)
* use CanKillEnemy more

reviewed instances of RG_KOKIRI_SWORD in logic

* kokiri does not damage spikes

* confirmed hammer works vs dodongos

* 3
2025-02-03 10:46:59 +01:00
Christopher Leggett
b5e6342bc1
Rip Settings out of Rando::Context (#4943)
Not completely happy with everything here but this should fix the bugs
related to settings getting cleared on save load.
2025-01-27 11:30:04 -07:00
Malkierian
ef0350d830
Add translation for bottle item RGs to itemIDs for assigning to slots in logic.cpp (#4954)
Change `CanEmptyBigPoes` to reset to false instead of true.
2025-01-27 09:48:13 -07:00
Garrett Cox
eab11d7f56
Lock overworld doors Randomizer option (#4489) 2025-01-21 00:03:02 +01:00
Pepper0ni
3e6a0ef566
Add Dana's models to the game, add cosmetic customisation for keys and rename Bombchus in Logic (#4311)
* initial implementation of new models

* fix typo

* Add smaller skeleton key model and try to fix windows build

* stupid windows, you made me look bad!

* make DrawBombchuBag function work

* small cleanups

* OOGGA BOOGA BOO

* fix post merge leftovers

* post merge fix

* Added Big Key Lighting override to show vanilla lighting when unchanged

* rename CustomdLists into customIconDLs

* post merge fixes

* fix some tooltip issues

* post merge cleanup and some small menu changes

* post merge fix

* post merge fix

* add new boss soul model, colours broken

* update boss soul model for env support

* Add dungeon customise buttons to cosmetic editor

* fix mac build?

* keys don't support alpha

* fix submodules

* ring now draws

* fix keyring colours

* Add bombchu Bag RG, fix boss soul skull colour

* address reviews
2025-01-15 14:18:52 +01:00
Pepper0ni
95a4e1cfba
Fix big poe bottle logic (#4837)
* fix big poe logic

* oops
2025-01-15 13:47:30 +01:00
Pepper0ni
ce289c0be9
Properly store starting age in spoiler log (#4873)
* properly store starting age in spoiler log

* convert ResolvedStatingAge to a setting to store it in the save
2025-01-15 13:05:52 +01:00
Pepe20129
7f31fd2e4e
Organize ship specific save context additions (#4597)
* Basic restructure

* Undo most randomizerInf changes for now

* Small fixes

* Fix linux & mac builds?

* Fix remnants of randomizerInf changes

* Post-merge fix

* Post-merge fix
2025-01-15 13:04:47 +01:00
Philip Dubé
51fcf4d2c6
Add trick for using blue fire on mud walls (#4810) 2025-01-08 05:49:55 +01:00
Philip Dubé
47ba512351
Clean up enemy logic (#4816)
* Fix logic thinking naked adult can clear wolfos grotto

Use CanKillEnemy more

* GERUDO_WARRIOR. Can defeat with a lot more than swords

* one more flare dancer

* Put defeating Gerudo Warrior with slingshot/bombchu behind trick
2025-01-07 19:32:52 +01:00
Pepper0ni
55e1af9e81
Fairysanity (#4744)
* Define VB for fairy group spawning

* Add skeleton of new files for fairy shuffle

* Add option to enable/disable fairy shuffle

* Add field to fairy entities to hold randomizer data

* Expose the current grotto id, or find it if not shuffled

This is necessary since, unlike chest or scrub grottos,
fairy fountains, lacking any elements that would normally
differ between grottos, often have identical respawn data.
This change enables fairy shuffle to correctly identify
which fairy fountain was entered so it could load the right
checks.

* Initialise fairy groups if detected

* Randomize first set of fairies

* Make randomized fairies collectible

* VBify fairy healing customization

* Add remaining grotto fairies

* Add remaining fairy group spawns

* Override bean sprouts spawning fairies

* Define bean sprout fairy checks

* Add HasItem and CanUse entries for magic beans.

* Define logic for bean sprout fairies

* Enabling looking up fairies by z coordinate

* Add Temple of Time Gossip Stones

Logic might look a little weird. While the Gossip Stones
respond to Sun's Song, the scene transition takes priority,
so the fairies aren't actually obtainable. Adult does not have
day and night versions and is fully capable of acquiring the
fairies with Sun's Song.

Song of Time is similar, but rather than being dependant on
age, it's dependant on the timesaver to switch ages anywhere
with Song of Time. In this case, the fairies still spawn,
but the age transition deletes them before giving the chance
to collect them. While I could've chosen to ignore this and
simply require the player to disable the enhancement before
playing if it's their only option, I instead decided to
accomodate the enhancement and require one of the other songs
in order for the check to be in logic.

* Disable quick age change around gossip stones to simplify logic

* Add remaining gossip stone fairies

* Finish gossip stone fairies

* Add Desert Colossus Oasis

* Restrict fairy type

Somehow, it was previously possible for Navi to get detected
as a randomized fairy and rendered as an item. I was not
able to reproduce the behavior, but this should prevent it
from happening again.

* Add overworld special fairy spots

* Add mini-dungeon fairy song spots

* Add remaining dungeons except Shadow

* Add Shadow Temple fairies

* Add fairy check flags to the save editor

* Filter fairy checks from check tracker

* Add hints for fairy checks

* get fairysanity as far as I can for now

* fix a few obvious issues

* now builds

* try to convert FairyOnVanillaBehaviorHandler to vardic args

* convert RegisterFairyCustomization to REGISTER_VB_SHOULD

* fix some generation issues

* remove the list of fairy locations

* fix up logic

* more logic changes for gossip stones

* try silly thing for windows

* more stupid

* more dumb testing

* more testing

* small fixes

* implement inside fence storms fairy

* add inside fence storms fairy to logic

* remove duplicate hints (stupid conflicts)

* oops

* Rewrite game interfacing code of fairy shuffle

* Better function names

---------

Co-authored-by: Angel Bulfone <mbulfone@gmail.com>
Co-authored-by: aMannus <mannusmenting@gmail.com>
2025-01-05 14:52:27 +01:00
Pepper0ni
1f99dcf56a
Clean up Kakariko logic and fix some errors, move AtNight into CanGetNightTimeGS. (#4748)
* fix kakariko logic

* Update soh/soh/Enhancements/randomizer/3drando/location_access/locacc_kakariko.cpp

Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>

---------

Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>
2024-12-25 21:14:21 -07:00
Pepper0ni
9ea9100787
Freestanding Rupees/Hearts Shuffle (#4686)
* Enable freestanding items other than heart pieces and keys

* Add option to disable freestanding rupee & heart shuffle

* Add items to pool

* Actually add shuffle setting

* Define overworld locations

* Add logic for overworld freestanding checks

* Add freestanding items for child dungeons.

* Add checks for Ice Cavern and Bottom of the Well

* Add checks for Forest Temple and Gerudo Training Grounds

* Add checks for Fire Temple and Water Temple

* Add Shadow Temple checks

This does not include the spinning pots rupees, even though
they're included with freestanding rupees in the N64 randomizer
as they would require dedicated overrides for the code for
the pots in question.

* Define Spirit Temple and Ganon's Castle hearts

* Add remaining checks to dungeon definitions

* Fix missing logic

* Add freestanding checks to Save Flags Editor

* Fix flags for Zora Fountain underwater rupees

* Add option to enable freestanding shuffle for either dungeons or overworld

* Add missing MQ checks and fix mac & windows compile error

* Improve description and add hint text

* Update logic for Bombchu fixes

* Add missing Spirit Temple MQ hearts

* Add missing settings entries

* Actually add Forest Temple trick to the tricks menu.

* Re-add Ice Cavern lobby rupee

* go over MQ logic

* review logic on non-MQ checks

* convert all freestandings to location based

* add option enum and fix jabu exit logic

* fix mislocated freestandings

* fix mislocted freestandings

* Fix some mislocationed checks

---------

Co-authored-by: Angel Bulfone <mbulfone@gmail.com>
2024-12-22 11:16:00 -07:00
Malkierian
a7d082246f
Rename all instances of "Training Grounds" to "Training Ground" to match the many that are already there as well as the in-game name. (#4730) 2024-12-19 10:44:16 +01:00
aMannus
1a5632e3b5
[RANDO] Shuffle Pots (#4592)
* Potsanity proof of concept

* Hide pot item cutscenes for very frequent items

* Add 1 new pot to the item pool

* V1 custom pot model

* V2 pot model

* Pushing for help. lol

* Format clean up on added hint_list entries.
Removal of WriteIngameSpoilerLog call that was unneeded.

* THREE_ACTOR_PARAMS -> TWO_ACTOR_PARAMS and hints in a loop

* Lost woods pots logic

* Realign Pot Checklist in Location_list.cpp

* Correcting some values and adding Master Quest pots.

* Remove vanilla placements

* Re-order enums + start hints per region

* Fix build

* Break up shuffle pot options to dungeon/overworld/all

* Fixes

* Prepare default pot contents, fix/add dungeons

* Fix dungeon/overworld only settings

* Updates to Parameters and RHT information

* Remove unused hints

* Add proper check tracker entry exclusion

* Tweak items to skip cutscenes for

* Vanilla Drop List

* Update magic to blue rupees

* After merge fixes

* Fix Ganondorf's Lair pots

* Fix check tracker + minor stuff

* Unlock early GBK door

* Minor fixes

* More minor stuff and start of logic entries

* Fix TWO_ACTOR_PARAMS overlap between pots

* De-dupe defines

* Add missing water trial pot

* Update to develop-rando

* VBify pots progress

* Cleanup and fixes

* Overworld logic done

* Cleanup and fix item00 queues

* Implement skipping cutscenes for common items

* Revert "Implement skipping cutscenes for common items"

This reverts commit fe44916588.

* Ganons tower pot not spawning item fix + cleanup

* Fix ganon's tower, barinade, water temple pots

* VBify ganons key door

* Lizalfos Pot addition (example)

* Separate MQ pots in randomizerTypes.h

* Fix build

* Fix linux build (?)

* DC/Jabu/Botw/ start of Forest Pots (NMQ)

* Remaining Dungeon Non MQ Pot Location Logic

* After merge fixes round 1

* Post merge fixes round 2

* Apply MQ pot logic

* Re-align some stuff

* Cleanup, more work on locationlist

* Start of handling dungeon pots in item pool

* Finish dungeon pots in item pool

* GTG MQ Pots

* Review comments round 1 & code cleanup

* Fix ganon's lair pots being behind GBK in logic

* Update soh/include/z64actor.h

Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>

* Update soh/src/overlays/actors/ovl_Obj_Tsubo/z_obj_tsubo.c

Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>

* Address review comment

* Fix logic for pots in Fire Temple

* Fix GtG MQ pots, fix water temple pot logic

* Review Comments

* Logic review part 1

* Logic comments part 2

---------

Co-authored-by: Caladius <Caladius@users.noreply.github.com>
Co-authored-by: Pepper0ni <93387759+Pepper0ni@users.noreply.github.com>
Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>
2024-12-13 21:15:40 +01:00
Pepper0ni
ab863653ce
Do some renames for the new settings arrangment (#4668)
* Automate settings text to enum conversion

* rename fortress setting into carpenters

* More renames for the new spoiler log layout
2024-12-13 12:30:13 -07:00
Pepper0ni
ad23298500
Automate settings text to enum conversion and remove OptionGroups from the process (#4636)
* Automate settings text to enum conversion

* rename fortress setting into carpenters
2024-12-09 19:18:00 -07:00
Pepper0ni
b1d1852655
Rewrite vanilla jabu logic (#4603)
* rewrite vanilla jabu logic

* cleanup

* more cleanup
2024-12-03 09:44:36 -07:00
Malkierian
55960da402
Separate option values into context and menu indexes. (#4581)
* Separate option values into context and menu indexes.

* Fix option index reference in `CleanCheckConditionString`.

* Update soh/soh/Enhancements/randomizer/3drando/location_access.cpp

Co-authored-by: Pepe20129 <72659707+Pepe20129@users.noreply.github.com>

* Restore `const` classification to functions returning `string&`.

* Restore `const` classification to getter functions.

* Restore a couple more `const`s; cleanup header.

* Final consts; rename `SetCVar` to `SaveCVar`.
2024-11-29 17:58:30 -07:00
Pepper0ni
9c99a1e515
Fix the "Greg as Reward" option in logic (#4565) 2024-11-22 16:22:27 -07:00
Pepper0ni
2603b97366
Rewrite MQ spirit logic (#4534)
* rewrite MQ spirit logic

* fix oversights
2024-11-09 09:40:00 -07:00
Pepe20129
c8815a26f7
Improve ganon tower logic (#4526)
* Improve ganon tower logic

* Fix build and address review

* Update locacc_ganons_castle.cpp

* Update locacc_ganons_castle.cpp

* Update locacc_ganons_castle.cpp

* Update logic.cpp

* Update randomizerTypes.h

---------

Co-authored-by: Malkierian <malkierian@gmail.com>
Co-authored-by: Malkierian <malkierian@live.com>
2024-11-09 09:34:05 -07:00
Pepper0ni
1d9d273a57
Rewrite MQ Water Temple Logic (#4520)
* Rewrite Storage Temple Logic

* fix a boss room oversight

* Fix some random errors

* cleanups
2024-11-07 09:51:29 -07:00
Pepper0ni
0d17e72dca
Rewrite MQ Shadow Temple logic (#4502) 2024-11-01 08:15:27 -07:00
Archez
ec1f03e8a2
Pass for some warning fixes (#4501) 2024-10-31 07:42:27 -07:00
Pepper0ni
71e9e616b6
Rewrite MQ Jabu Logic (#4493)
* rewrite MQ Jabu Logic

* Add swim requirement to the rang jump trick as link hints the water first
2024-10-29 14:05:09 -07:00
Pepper0ni
438a8bff79
Rewrite MQ GTG and Ice Cavern logic (#4483)
* rewrite GTG logic

* Rewrite MQ Ice Cavern Logic
2024-10-27 14:16:51 -07:00
Pepper0ni
6ca55aadbd
Rewrite MQ Ganon's castle logic (#4469)
* rewrite ganon MQ logic

* typo fix

* remove excess brackets to avoid compiler errors
2024-10-25 17:51:07 -07:00
Pepper0ni
dd9253808b
Rewrite forest MQ logic, add swim to lake logic (#4464)
* rewrite forest logic, add swim to lake logic

* fix small oops

* oops
2024-10-21 19:18:50 -07:00
Pepper0ni
323c67b47c
Change CanUse to include an assert, fix some bad uses of CanUse (#4444) 2024-10-20 01:03:09 -07:00
Pepper0ni
ba38d985b3
Rewrite MQ fire logic and fix MQ deku logic (#4443)
* commit to merge

* rewrite fire and fix deku
2024-10-20 01:00:39 -07:00