Skip to content

Rando: Infinite Upgrades#3099

Closed
Pepe20129 wants to merge 14 commits intoHarbourMasters:developfrom
Pepe20129:infinite_upgrades_2
Closed

Rando: Infinite Upgrades#3099
Pepe20129 wants to merge 14 commits intoHarbourMasters:developfrom
Pepe20129:infinite_upgrades_2

Conversation

@Pepe20129
Copy link
Contributor

@Pepe20129 Pepe20129 commented Jul 30, 2023

This PR adds an option for rando which adds infinite upgrades for every consumable item (except magic beans):
image
image
image
image
image
image
image
image

The counts dissapear when you have the infinite upgrades:
image
image

Magic turns blue (can be changed in cosmetic editor) when you have its infinite upgrade:
image

Build Artifacts

@Pepe20129
Copy link
Contributor Author

Note that there's still a visual bug that causes the infinite bombchu textbox to be replaced with the normal bombchu textbox if gotten from progressive bombchus.

@Onemario1234
Copy link

I'm a big fan of this concept! I'm all for options that add more things to the item pool.


{ RAND_INF_KAK_100_GOLD_SKULLTULA_REWARD, "KAK_100_GOLD_SKULLTULA_REWARD" },
{ RAND_INF_GREG_FOUND, "RAND_INF_GREG_FOUND" },

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Obligatory merge conflict warning :)

if (AMMO(ITEM_BOMBCHU) > 50) {
AMMO(ITEM_BOMBCHU) = 50;
}
}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think this section should have been removed either. If your infinite upgrades are turned off, and you undo the change above to the number of progressive bombchu packs in the pool, then we still need this code to handle getting multiple progressive bombchu packs.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is fine because of the code added in randomizer.cpp:

case RG_PROGRESSIVE_BOMBCHUS:
    if (INV_CONTENT(ITEM_BOMBCHU) == ITEM_NONE) {
        return (GetItemID)RG_PROGRESSIVE_BOMBCHUS;
    } else if (infiniteUpgrades) {
        return (GetItemID)RG_BOMBCHU_INF;
    } else if (AMMO(ITEM_BOMBCHU) < 5) {
        return GI_BOMBCHUS_10;
    } else {
        return GI_BOMBCHUS_5;
    }

Now the progressive bombchus rg is only used when you originally get them, I made this change because it gave me problems the way it was implemented before and I figured it was fine as progressive bombchus are the only item that does logic in Randomizer_Item_Give. I can change it back if it's preferred that way.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also as a side effect of this, progressive bombchus only sparkle if you don't have them yet, instead of always.

@Malkierian
Copy link
Contributor

Alright, had a deep look. Just wanted to mention the obligatory n64ddFlag -> IS_RANDO change. Also liked the idea of having the maintenance for infinite stuff be outside of normal vanilla code, I just wish it was possible to do it without running the checks every frame...

@Pepe20129
Copy link
Contributor Author

Alright, had a deep look. Just wanted to mention the obligatory n64ddFlag -> IS_RANDO change. Also liked the idea of having the maintenance for infinite stuff be outside of normal vanilla code, I just wish it was possible to do it without running the checks every frame...

Did the n64ddFlag -> IS_RANDO change, as for the checks every frame, the only solution I can think of would be OnAmmoSpent and OnRupeesSpent hooks.

@Malkierian
Copy link
Contributor

Yeah, I don't think anything is setup for that yet. Was just lamenting that fact.

@garrettjoecox
Copy link
Contributor

@Pepe20129 do you intend on porting this to rando v3?

@Pepe20129
Copy link
Contributor Author

Yes, after my other rando v3 prs get merged.

@briaguya0
Copy link
Contributor

closing in favor of the rando v3 version #3942

@briaguya0 briaguya0 closed this Feb 17, 2024
@Pepe20129 Pepe20129 deleted the infinite_upgrades_2 branch February 17, 2024 22:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants