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

[Enhancement] Built in alt inst unlocking #3961

Open
wants to merge 5 commits into
base: develop
Choose a base branch
from

Conversation

MidyGamy
Copy link

This add a built in check of available alt inst and if it's unlocked, allowing to remove that annoying function found in almost all song scripts (and will be easier do add more mixes)

  public override function listAltInstrumentalIds(difficultyId:String, variationId:String):Array<String> {
    if (difficultyId == 'easy' || difficultyId == 'normal' || difficultyId == 'hard') {
      var hasBeatenPicoMix = Save.instance.hasBeatenSong(this.id, null, 'pico');

      switch (variationId) {
        case 'pico':
          // return hasBeatenPicoMix ? [''] : [];
          // No Pico mix on BF instrumental, sorry!
          return [];
        default:
          return hasBeatenPicoMix ? ['pico'] : [];
      }
    }
  }

It also adds the unlockedInstByDefault property in the song metadata of a song alt to lock it (since it's unlocked by default if the property doesn't exits)

@github-actions github-actions bot added size: medium A medium pull request with 100 or fewer changes. pr: haxe PR modifies game code. labels Dec 29, 2024
@MidyGamy
Copy link
Author

Btw that also fixes a problem where a song with a Pico Mix couldn't have an other altInst using the _merge folder

@MidyGamy MidyGamy changed the title [Enhancement] Built in alt inst checking [Enhancement] Built in alt inst unlocking Dec 29, 2024
@EliteMasterEric EliteMasterEric added the status: pending triage Awaiting review. label Jan 17, 2025
@TechnikTil
Copy link
Contributor

i made something like this on FunkinCrew/funkin.assets#105

@MidyGamy
Copy link
Author

i made something like this on FunkinCrew/funkin.assets#105

Yeah, but you have to manually put it every times, here it's built in, with just the need of a check box in the chart editor

@TechnikTil
Copy link
Contributor

i made something like this on FunkinCrew/funkin.assets#105

Yeah, but you have to manually put it every times, here it's built in, with just the need of a check box in the chart editor

o ok

@Hundrec Hundrec added the type: enhancement Involves an enhancement or new feature. label Jan 22, 2025
@AbnormalPoof
Copy link
Collaborator

This PR appears to have merge conflicts. Please fix them!

@AbnormalPoof AbnormalPoof added status: needs revision Cannot be approved because it is awaiting some work by the contributor. status: pending triage Awaiting review. and removed status: pending triage Awaiting review. status: needs revision Cannot be approved because it is awaiting some work by the contributor. labels Jan 22, 2025
@MidyGamy
Copy link
Author

wait there is the assets to update before (and for some reasons, I can't manage to do it)

@MidyGamy MidyGamy changed the base branch from main to develop January 27, 2025 18:00
@AbnormalPoof AbnormalPoof added status: pending triage Awaiting review. status: needs revision Cannot be approved because it is awaiting some work by the contributor. and removed status: pending triage Awaiting review. labels Jan 27, 2025
@AbnormalPoof
Copy link
Collaborator

Looks like this PR needs a rebase.

@MidyGamy MidyGamy changed the base branch from develop to main January 27, 2025 18:47
@AbnormalPoof AbnormalPoof removed the status: pending triage Awaiting review. label Jan 27, 2025
@MidyGamy MidyGamy force-pushed the in-data-locked-alt-inst branch from 98884b4 to 6216655 Compare January 28, 2025 02:30
@github-actions github-actions bot added size: large A large pull request with more than 100 changes. pr: documentation PR modifies documentation or README files. pr: github PR modifies GitHub metadata files. and removed size: medium A medium pull request with 100 or fewer changes. labels Jan 28, 2025
@AbnormalPoof
Copy link
Collaborator

FYI This PR needs to be based on the develop branch and not main.

@MidyGamy MidyGamy changed the base branch from main to develop January 28, 2025 02:37
@MidyGamy
Copy link
Author

well, I can't draft it anymore, trying to update the assets

@AbnormalPoof AbnormalPoof added status: pending triage Awaiting review. size: medium A medium pull request with 100 or fewer changes. and removed pr: documentation PR modifies documentation or README files. pr: github PR modifies GitHub metadata files. status: needs revision Cannot be approved because it is awaiting some work by the contributor. size: large A large pull request with more than 100 changes. labels Jan 28, 2025
@MidyGamy MidyGamy force-pushed the in-data-locked-alt-inst branch from c392b65 to d8b8c66 Compare January 28, 2025 02:52
@MidyGamy
Copy link
Author

I CAN'T REMEMBER HOW TO CHANGE THE SUBMODULE FROM THE MAIN REPO!!!

@MidyGamy MidyGamy force-pushed the in-data-locked-alt-inst branch 2 times, most recently from 5bfc7dd to d8b8c66 Compare January 28, 2025 04:33
@MidyGamy
Copy link
Author

I REMEMBERED!!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
pr: haxe PR modifies game code. size: medium A medium pull request with 100 or fewer changes. status: pending triage Awaiting review. type: enhancement Involves an enhancement or new feature.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

5 participants