This commit is contained in:
SoulliesOfficial
2025-08-22 14:54:40 -04:00
parent 6aa498f6be
commit 70b2a43824
574 changed files with 173713 additions and 1884 deletions

View File

@@ -2,9 +2,9 @@ using System;
using System.Collections;
using System.Collections.Generic;
using Ichni.Menu;
using Ichni.RhythmGame;
using Ichni.UI;
using Sirenix.OdinInspector;
using UnityEngine;
namespace Ichni
{
@@ -25,9 +25,5 @@ namespace Ichni
instance = this;
}
public ChapterSelectionUnit GetChapterByName(string chapterName)
{
return chapters.Find(chapter => chapter.chapterName == chapterName);
}
}
}

View File

@@ -3,6 +3,7 @@ using System.Collections;
using System.Collections.Generic;
using System.Linq;
using AK.Wwise;
using Ichni.RhythmGame;
using Sirenix.OdinInspector;
using UnityEngine;
using UnityEngine.Serialization;
@@ -56,6 +57,49 @@ namespace Ichni.Menu
{
return (from song in songs where song.storyUnlockKey == key select song.songName).ToList();
}
public (int, int, int, int, int) GetChapterSaveInfo()
{
int beatmapCount = 0;
int finishedSongCount = 0;
int finishedBeatmapCount = 0;
int fullComboCount = 0;
int allPerfectCount = 0;
foreach (SongItemData song in songs)
{
if (GameSaveManager.instance.SongSaveModule.songStatusSaves.TryGetValue(song.songName, out var songStatus))
{
bool thisSongFinished = false;
foreach (BeatmapSave beatmapSave in songStatus.beatmapSaves)
{
beatmapCount++;
if (!beatmapSave.IsEmpty())
{
thisSongFinished = true;
finishedBeatmapCount++;
if (beatmapSave.isFullCombo)
{
fullComboCount++;
}
if (beatmapSave.isAllPerfect)
{
allPerfectCount++;
}
}
}
if (thisSongFinished)
{
finishedSongCount++;
}
}
}
return (beatmapCount, finishedSongCount, finishedBeatmapCount, fullComboCount, allPerfectCount);
}
}
[InlineProperty]