111
This commit is contained in:
@@ -66,7 +66,7 @@ namespace Ichni.Menu
|
||||
|
||||
MenuManager.instance.songSelectionUIPage.difficultySelectionContainer.selectedButton?.Deselect();
|
||||
MenuManager.instance.songSelectionUIPage.difficultySelectionContainer.selectedButton = this;
|
||||
MenuManager.instance.songSelectionUIPage.currentSelectedDifficultyIndex = difficultyData.difficultyIndex;
|
||||
MenuInformationRecorder.instance.GetRecordOfThisChapter().difficultyIndex = difficultyData.difficultyIndex;
|
||||
|
||||
gameObject.GetComponent<AudioContainer>().PlaySoundFX("SelectDifficluty");
|
||||
|
||||
|
||||
@@ -23,12 +23,14 @@ namespace Ichni.Menu
|
||||
buttons[i].SetUp(difficulties[i]);
|
||||
}
|
||||
|
||||
if (MenuManager.instance.songSelectionUIPage.currentSelectedDifficultyIndex >= difficultyCount)
|
||||
SongSelectionRecord songSelectionRecord = MenuInformationRecorder.instance.GetRecordOfThisChapter();
|
||||
|
||||
if (songSelectionRecord.difficultyIndex >= difficultyCount)
|
||||
{
|
||||
MenuManager.instance.songSelectionUIPage.currentSelectedDifficultyIndex = difficultyCount - 1;
|
||||
songSelectionRecord.difficultyIndex = difficultyCount - 1;
|
||||
}
|
||||
|
||||
buttons[MenuManager.instance.songSelectionUIPage.currentSelectedDifficultyIndex].Select();
|
||||
buttons[songSelectionRecord.difficultyIndex].Select();
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -25,6 +25,13 @@ namespace Ichni.Menu
|
||||
return;
|
||||
}
|
||||
|
||||
if (MenuManager.instance.isEnteringGame)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
MenuManager.instance.isEnteringGame = true;
|
||||
|
||||
InformationTransistor.instance.SetInformation(
|
||||
ChapterSelectionManager.instance.currentChapter,
|
||||
MenuManager.instance.songSelectionUIPage.selectedSong,
|
||||
|
||||
@@ -67,6 +67,7 @@ namespace Ichni.Menu
|
||||
{
|
||||
StartCoroutine(SnapToItem(songItems[songIndex], true));
|
||||
}
|
||||
|
||||
closestTab = songItems[songIndex];
|
||||
|
||||
targetPosition = content.anchoredPosition;
|
||||
|
||||
@@ -44,13 +44,22 @@ namespace Ichni.Menu
|
||||
{
|
||||
if (MenuManager.instance.songSelectionUIPage.songListController.selectedTab == this)
|
||||
{
|
||||
if (MenuManager.instance.isEnteringGame)
|
||||
{
|
||||
return;
|
||||
}
|
||||
|
||||
MenuManager.instance.isEnteringGame = true;
|
||||
|
||||
InformationTransistor.instance.SetInformation(
|
||||
ChapterSelectionManager.instance.currentChapter,
|
||||
MenuManager.instance.songSelectionUIPage.selectedSong,
|
||||
MenuManager.instance.songSelectionUIPage.selectedDifficulty);
|
||||
|
||||
MenuAudioManager.instance.audioContainer.PlaySoundFX("EnterToGame");
|
||||
MenuAudioManager.instance.audioContainer.StopEvent("PlayPreview");
|
||||
MenuManager.instance.transitionUIPage.FadeIn();
|
||||
|
||||
Observable.Timer(TimeSpan.FromSeconds(0.6f)).Subscribe(_ =>
|
||||
{
|
||||
MenuManager.instance.TestEnterGame();
|
||||
|
||||
@@ -18,7 +18,7 @@ namespace Ichni.Menu
|
||||
public PlaySongUI playSongUI;
|
||||
public SongInfoUI songInfoUI;
|
||||
public DifficultySelectionContainer difficultySelectionContainer;
|
||||
public int currentSelectedDifficultyIndex;
|
||||
//public int currentSelectedDifficultyIndex;
|
||||
|
||||
protected override void Awake()
|
||||
{
|
||||
@@ -54,7 +54,7 @@ namespace Ichni.Menu
|
||||
|
||||
private void Start()
|
||||
{
|
||||
currentSelectedDifficultyIndex = 0;
|
||||
MenuInformationRecorder.instance.GetRecordOfThisChapter().difficultyIndex = 0;
|
||||
|
||||
Sequence framesSeq = DOTween.Sequence();
|
||||
framesSeq.Append(DOTween.To(() => framePositionOffset, x => framePositionOffset = x, 1f, 1f)
|
||||
|
||||
Reference in New Issue
Block a user