Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Sun's Song not Stunning redeads/gibdos #318

Closed
smashbro596 opened this issue May 14, 2022 · 13 comments
Closed

Sun's Song not Stunning redeads/gibdos #318

smashbro596 opened this issue May 14, 2022 · 13 comments
Assignees

Comments

@smashbro596
Copy link

smashbro596 commented May 14, 2022

When i play the sun song when redeads/gibdos are in the area (which is always in a place thats frozen in time) I'm instead warped to the area entrance and the time of day changes.
when the sun's song is played in redead/gibdo-infested areas, it should only stun them. any fix here?

@vaguerant
Copy link
Contributor

// Unrestricted Items
if (CVar_GetS32("gNoRestrictItems", 0) != 0) {
if (gGlobalCtx) {
memset(&gGlobalCtx->interfaceCtx.restrictions, 0, sizeof(gGlobalCtx->interfaceCtx.restrictions));
}
}

Zeroing out all restrictions is no good for this scenario because the Sun's Song restriction is how the game knows whether you're playing the song in an area where time passes or not, and so whether to warp you back to the entrance or not.

It's a bit hacky, but this would work:

    // Unrestricted Items
    if (CVar_GetS32("gNoRestrictItems", 0) != 0) {
        if (gGlobalCtx) {
            u8 sunsBackup = gGlobalCtx->interfaceCtx.restrictions.sunsSong;
            memset(&gGlobalCtx->interfaceCtx.restrictions, 0, sizeof(gGlobalCtx->interfaceCtx.restrictions));
            gGlobalCtx->interfaceCtx.restrictions.sunsSong = sunsBackup;
        }
    }

@leggettc18
Copy link
Contributor

There are a few ways to fix it, and I'm not sure which is better. We can do what @vaguerant suggested, which fixes the issue but misleadingly re-restricts Suns Song, which could be useful for warping to the beginning of dungeons. We can add a checkbox that appears after checking Unrestricted Items to re-restrict the Suns Song, but that would be bloating the UI. The last "fix" would be adding a tooltip or explanation of some form that "Unrestricted Items can break certain interactions (like ReDeads with Suns Song)". These all have Pros and Cons, and I'm not sure which is the best to do.

@vaguerant
Copy link
Contributor

We can do what @vaguerant suggested, which fixes the issue but misleadingly re-restricts Suns Song

I don't know if I'd really even consider it misleading, because that assumes users see "Unrestricted Items" and make a substantial logical leap to assume the Sun's Song will have its outside behavior inside dungeons and similar areas. If anything, I think the current behavior might be the misleading one.

You'd need a very specific knowledge of OoT to even think of the Sun's Song as an item to be unrestricted in the first place. The current tooltip does nothing to make anybody think which songs perform what functions in which area could or should be affected, either:

Allows you to use any item at any location

If we want the cheat to keep affecting how ocarina songs work, the cheat might be best renamed entirely, because "Unrestricted Items" just doesn't intuitively mean that to most users.

@jbodner09
Copy link
Contributor

I agree, especially since there are other ways of warping back to the entrance of a dungeon, and so people who are looking specifically to Sun's Song to do that only when this setting is enabled are probably doing something wrong 😊 Plus, I'm somebody who always says that more documentation is better, so turning the name "Unrestricted Items" into something that says more accurately (even if more verbosely) what it does seems like the right call, and then we don't need to worry about re-restricting a tiny thing here or there in the future either.

@leggettc18
Copy link
Contributor

I agree as well, I think keeping Sun's Song restricted is probably the correct move.

@aMannus
Copy link
Contributor

aMannus commented Jul 18, 2022

My vote also goes to just restricting suns song. I believe there was some other crash that had to do with dins fire as well in areas where the camera is locked, but that would be a different issue I suppose.

@stratomaster64
Copy link
Contributor

stratomaster64 commented Jul 18, 2022

As the original author of this cheat, the implementation I chose was copied over from gz. I just confirmed that the same does indeed happen over there.
I'm fine with "re-restricting" sun's song if need be, although I also believe that those who play with cheats on should be aware of the potential breaking effects that they may have (i.e., playing in an unintended way brings unintended consequences).

Edit: gz calls this cheat "usable items" in the context that it allows items to be used where they normally wouldn't be, so perhaps this could be a good alternative name?

@leggettc18
Copy link
Contributor

"Usable Items" doesn't really get the idea across any clearer, because what caused this issue to get as far as it has is that users don't think of Sun's Song as an "item". Calling the cheat "Unrestricted Items/Songs" might clue people in that they should consider turning that off before submitting a bug report. However, it's also more of a "double-edged sword" than other cheats in the menu, and unlike the other items, unrestricted Sun's Song causes you to be unable to collect a heart piece while it's enabled, so I think it can stand to be nerfed a bit. Plus with this "nerf" you don't really lose any useful functionality. Unrestricted Sun's song can be a warp, but in a vanilla playthrough the player would only be missing FW for one dungeon, and even then Save->Ctrl+R might be faster to reset to the beginning of the dungeon.

@PurpleHato
Copy link
Member

As the original author of this cheat, the implementation I chose was copied over from gz. I just confirmed that the same does indeed happen over there. I'm fine with "re-restricting" sun's song if need be, although I also believe that those who play with cheats on should be aware of the potential breaking effects that they may have (i.e., playing in an unintended way brings unintended consequences).

Edit: gz calls this cheat "usable items" in the context that it allows items to be used where they normally wouldn't be, so perhaps this could be a good alternative name?

Since it's literally breaking it, yeah: cf:
https://streamable.com/6zaff1

@PurpleHato
Copy link
Member

PurpleHato commented Jul 19, 2022

Fixed with #839

@leggettc18
Copy link
Contributor

I think he meant #839

@PurpleHato
Copy link
Member

PurpleHato commented Jul 19, 2022

I think he meant #839

Indeed my finger slipped ^-^
Thanks!

@PurpleHato PurpleHato self-assigned this Jul 22, 2022
Malkierian added a commit to Malkierian/Shipwright that referenced this issue Nov 20, 2023
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

No branches or pull requests

9 participants