存档重构,游戏内容解锁机制;教程完善(未完成)
This commit is contained in:
@@ -3,6 +3,7 @@ using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using DG.Tweening;
|
||||
using Ichni.RhythmGame;
|
||||
using Sirenix.OdinInspector;
|
||||
using SLSUtilities.WwiseAssistance;
|
||||
using TMPro;
|
||||
@@ -53,11 +54,21 @@ namespace Ichni.Menu
|
||||
{
|
||||
MenuManager.instance.songSelectionUIPage.selectedDifficulty = difficultyData;
|
||||
MenuManager.instance.songSelectionUIPage.songInfoUI.SetCharter(difficultyData.charterName);
|
||||
MenuManager.instance.songSelectionUIPage.songInfoUI.SetBeatmapInfo(
|
||||
MenuManager.instance.songSelectionUIPage.selectedSave.beatmapSaves[difficultyData.difficultyIndex]);
|
||||
if (MenuManager.instance.songSelectionUIPage.selectedSave.TryGetBeatmapSave(
|
||||
difficultyData.saveDifficultyId, out BeatmapSave beatmapSave))
|
||||
{
|
||||
MenuManager.instance.songSelectionUIPage.songInfoUI.SetBeatmapInfo(beatmapSave);
|
||||
}
|
||||
else
|
||||
{
|
||||
// 当前内容尚未创建该难度的记录时,UI 只显示空成绩,不在展示路径修改存档。
|
||||
MenuManager.instance.songSelectionUIPage.songInfoUI.SetBeatmapInfo(new BeatmapSave(0f, false, false));
|
||||
}
|
||||
|
||||
MenuInformationRecorder.instance.songSelectionRecords[ChapterSelectionManager.instance.currentChapter] =
|
||||
new SongSelectionRecord(MenuManager.instance.songSelectionUIPage.selectedSong, difficultyData);
|
||||
MenuInformationRecorder.instance.SetRecordForChapter(
|
||||
ChapterSelectionManager.instance.currentChapter,
|
||||
MenuManager.instance.songSelectionUIPage.selectedSong,
|
||||
MenuManager.instance.songSelectionUIPage.selectedSong.difficultyDataList.IndexOf(difficultyData));
|
||||
|
||||
if (container.selectedButton == this)
|
||||
{
|
||||
@@ -67,7 +78,6 @@ namespace Ichni.Menu
|
||||
|
||||
MenuManager.instance.songSelectionUIPage.difficultySelectionContainer.selectedButton?.Deselect();
|
||||
MenuManager.instance.songSelectionUIPage.difficultySelectionContainer.selectedButton = this;
|
||||
MenuInformationRecorder.instance.GetRecordOfThisChapter().difficultyIndex = difficultyData.difficultyIndex;
|
||||
|
||||
AudioManager.Post(AK.EVENTS.SELECTDIFFICULTY);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user