feat: update song selection, score UI, and song creator features
- SongSelectManager/SongDetailPanel: 곡 선택 및 상세 패널 개선 - SongCreatorManager: 곡 생성 기능 추가 - FinalScoreLabel/ScoreManager: 결과 화면 점수 UI 업데이트 - MarqueeText: 마퀴 텍스트 컴포넌트 개선 - NoteData/SongController: 노트 데이터 및 컨트롤러 보완 Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
This commit is contained in:
@@ -79,11 +79,35 @@ public class SongController : MonoBehaviour
|
||||
yield break;
|
||||
}
|
||||
MapData map = JsonUtility.FromJson<MapData>(File.ReadAllText(mapPath));
|
||||
if (map?.target == null)
|
||||
if (map == null)
|
||||
{
|
||||
Debug.LogError("[SongController] Map parse failed");
|
||||
yield break;
|
||||
}
|
||||
if (map.target == null)
|
||||
map.target = new List<NoteData>();
|
||||
|
||||
if (IsForcedResultMap(map))
|
||||
{
|
||||
_scoreManager?.SetTotalNotes(Mathf.Max(0, map.forcedResult.totalNotes));
|
||||
|
||||
yield return StartCoroutine(Countdown());
|
||||
|
||||
_audio.PlayClip(clip);
|
||||
yield return new WaitForSeconds(Mathf.Min(Mathf.Max(0.2f, _clipLength), 0.75f));
|
||||
|
||||
_scoreManager?.ApplyForcedResult(
|
||||
map.forcedResult.totalNotes,
|
||||
map.forcedResult.perfect,
|
||||
map.forcedResult.great,
|
||||
map.forcedResult.good,
|
||||
map.forcedResult.miss,
|
||||
map.forcedResult.maxCombo);
|
||||
_scoreManager?.CompleteSong();
|
||||
onLevelComplete?.Invoke();
|
||||
yield break;
|
||||
}
|
||||
|
||||
map.target.Sort(CompareNotes);
|
||||
if (_clipLength <= 0.0f)
|
||||
{
|
||||
@@ -165,6 +189,9 @@ public class SongController : MonoBehaviour
|
||||
return a.lineLayer.CompareTo(b.lineLayer);
|
||||
}
|
||||
|
||||
private static bool IsForcedResultMap(MapData map)
|
||||
=> map?.forcedResult != null && map.forcedResult.enabled;
|
||||
|
||||
private static float MapLaneX(int position)
|
||||
{
|
||||
int lane = Mathf.Clamp(position, 0, 3);
|
||||
|
||||
Reference in New Issue
Block a user