This commit is contained in:
Patrick12115 2024-05-09 22:47:38 -04:00
parent e0fc23762f
commit afd87316d2
2 changed files with 7 additions and 7 deletions

View File

@ -718,7 +718,7 @@ void RegisterMirrorModeHandler() {
}
void UpdatePatchChildHylianShield() {
if ((CVarGetInteger("gEnhancements.RotateScaleChildHylianShield", 0) && LINK_IS_CHILD) &&
if ((CVarGetInteger(CVAR_ENHANCEMENT("RotateScaleChildHylianShield", 0) && LINK_IS_CHILD) &&
(gSaveContext.equips.buttonItems[0] == ITEM_SWORD_KOKIRI || gSaveContext.equips.buttonItems[0] == ITEM_FISHING_POLE)) {
ResourceMgr_PatchGfxByName(gLinkAdultHylianShieldSwordAndSheathNearDL, "childHylianShield1", 82, gsSPDisplayListOTRFilePath(gLinkChildSwordAndSheathNearDL));
ResourceMgr_PatchGfxByName(gLinkAdultHylianShieldSwordAndSheathNearDL, "childHylianShield2", 83, gsSPEndDisplayList());
@ -726,7 +726,7 @@ void UpdatePatchChildHylianShield() {
ResourceMgr_UnpatchGfxByName(gLinkAdultHylianShieldSwordAndSheathNearDL, "childHylianShield1");
ResourceMgr_UnpatchGfxByName(gLinkAdultHylianShieldSwordAndSheathNearDL, "childHylianShield2");
}
if ((CVarGetInteger("gEnhancements.RotateScaleChildHylianShield", 0) && LINK_IS_CHILD) &&
if ((CVarGetInteger(CVAR_ENHANCEMENT("RotateScaleChildHylianShield", 0) && LINK_IS_CHILD) &&
(gSaveContext.equips.buttonItems[0] == ITEM_NONE || gSaveContext.equips.buttonItems[0] == ITEM_STICK)) {
ResourceMgr_PatchGfxByName(gLinkAdultHylianShieldSwordAndSheathNearDL, "childHylianShield3", 82, gsSPEndDisplayList());
} else {

View File

@ -707,15 +707,15 @@ void DrawEnhancementsMenu() {
}
}
UIWidgets::Tooltip("Allows strength to be toggled on and off by pressing A on the strength upgrade in the equipment subscreen of the pause menu (This allows performing some glitches that require the player to not have strength).");
if (UIWidgets::PaddedEnhancementCheckbox("Hold Hylian Shield as Child Link", "gEnhancements.ChildHoldsHylianShield", true, false)) {
if (CVarGetInteger("gEnhancements.ChildHoldsHylianShield", 0) == 0) {
CVarSetInteger("gEnhancements.RotateScaleChildHylianShield", 0);
if (UIWidgets::PaddedEnhancementCheckbox("Hold Hylian Shield as Child Link", CVAR_ENHANCEMENT("ChildHoldsHylianShield", true, false)) {
if (CVarGetInteger(CVAR_ENHANCEMENT("ChildHoldsHylianShield", 0) == 0) {
CVarSetInteger(CVAR_ENHANCEMENT("RotateScaleChildHylianShield", 0);
}
UpdateChildHylianShieldState();
}
UIWidgets::Tooltip("Allows Child Link to hold the Hylian Shield the same way as the rest of the shields.");
if (CVarGetInteger("gEnhancements.ChildHoldsHylianShield", 0) == 1) {
if (UIWidgets::PaddedEnhancementCheckbox("Rotate and Scale Child Hylian Shield", "gEnhancements.RotateScaleChildHylianShield", true, false)) {
if (CVarGetInteger(CVAR_ENHANCEMENT("ChildHoldsHylianShield", 0) == 1) {
if (UIWidgets::PaddedEnhancementCheckbox("Rotate and Scale Child Hylian Shield", CVAR_ENHANCEMENT("RotateScaleChildHylianShield", true, false)) {
UpdateChildHylianShieldState();
UpdatePatchChildHylianShield();
}