1
This commit is contained in:
@@ -0,0 +1,27 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using Ichni.Menu;
|
||||
using Ichni.UI;
|
||||
using Sirenix.OdinInspector;
|
||||
using UnityEngine;
|
||||
|
||||
namespace Ichni
|
||||
{
|
||||
public partial class ChapterSelectionManager : SerializedMonoBehaviour
|
||||
{
|
||||
public static ChapterSelectionManager instance;
|
||||
|
||||
public ChapterSelectionUIPage chapterSelectionUIPage;
|
||||
public List<ChapterSelectionUnit> chapters;
|
||||
|
||||
}
|
||||
|
||||
public partial class ChapterSelectionManager
|
||||
{
|
||||
private void Awake()
|
||||
{
|
||||
instance = this;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 8aa09572a86d1ab47af92aa372e1f90d
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
@@ -1,6 +1,8 @@
|
||||
using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using System.Linq;
|
||||
using AK.Wwise;
|
||||
using Sirenix.OdinInspector;
|
||||
using UnityEngine;
|
||||
|
||||
@@ -14,16 +16,37 @@ namespace Ichni.Menu
|
||||
public string chapterSubtitle;
|
||||
public Color themeColor;
|
||||
public Sprite avatar;
|
||||
public Switch chapterSwitch;
|
||||
|
||||
[ListDrawerSettings(ShowFoldout = true)]
|
||||
public List<SongItemData> songs = new List<SongItemData>();
|
||||
|
||||
[Button]
|
||||
public void SetUpDefaultDifficulties()
|
||||
{
|
||||
foreach (SongItemData song in songs)
|
||||
{
|
||||
if(song.difficultyDataList.All(d => d.difficultyName != "Easy"))
|
||||
{
|
||||
song.difficultyDataList.Add(new DifficultyData("Easy","", "",
|
||||
new Color(0f, 0.7f, 0.2f, 1f)));
|
||||
}
|
||||
|
||||
if (song.difficultyDataList.All(d => d.difficultyName != "Hard"))
|
||||
{
|
||||
song.difficultyDataList.Add(new DifficultyData("Hard", "", "",
|
||||
new Color(1f, 0.2f, 0.2f, 1f)));
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
[InlineProperty]
|
||||
[Serializable]
|
||||
public class SongItemData
|
||||
{
|
||||
[HideLabel, FoldoutGroup("$songName", true)]
|
||||
[FoldoutGroup("$songName", true)]
|
||||
public string songName;
|
||||
|
||||
[FoldoutGroup("$songName")]
|
||||
@@ -36,7 +59,7 @@ namespace Ichni.Menu
|
||||
public bool isNewSong;
|
||||
|
||||
[FoldoutGroup("$songName")]
|
||||
public AK.Wwise.Switch songSwitch;
|
||||
public Switch songSwitch;
|
||||
|
||||
[FoldoutGroup("$songName")]
|
||||
public Sprite albumIconCover;
|
||||
@@ -52,16 +75,6 @@ namespace Ichni.Menu
|
||||
|
||||
[FoldoutGroup("$songName")]
|
||||
public List<DifficultyData> difficultyDataList;
|
||||
|
||||
[Button]
|
||||
[FoldoutGroup("$songName")]
|
||||
public void AddDefaultDifficulties()
|
||||
{
|
||||
difficultyDataList.Add(
|
||||
new DifficultyData("Easy","", "", new Color(0f, 0.7f, 0.2f, 1f)));
|
||||
difficultyDataList.Add(
|
||||
new DifficultyData("Hard","", "", new Color(1f, 0.2f, 0.2f, 1f)));
|
||||
}
|
||||
}
|
||||
|
||||
[Serializable]
|
||||
@@ -2,25 +2,39 @@ using System;
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using AK.Wwise;
|
||||
using Ichni.UI;
|
||||
using Sirenix.OdinInspector;
|
||||
using UnityEngine;
|
||||
using UnityEngine.SceneManagement;
|
||||
using UnityEngine.Serialization;
|
||||
|
||||
namespace Ichni.Menu
|
||||
namespace Ichni
|
||||
{
|
||||
public partial class MenuManager : MonoBehaviour
|
||||
{
|
||||
public static MenuManager instance;
|
||||
|
||||
[FormerlySerializedAs("preparePage")] public PrepareUIPage prepareUIPage;
|
||||
}
|
||||
|
||||
public partial class MenuManager
|
||||
{
|
||||
AsyncOperation asyncOperation;
|
||||
|
||||
private void Awake()
|
||||
{
|
||||
instance = this;
|
||||
Application.targetFrameRate = 120;
|
||||
/*asyncOperation = SceneManager.LoadSceneAsync("GameScene");
|
||||
asyncOperation.allowSceneActivation = false;*/
|
||||
}
|
||||
|
||||
private void Start()
|
||||
{
|
||||
asyncOperation = SceneManager.LoadSceneAsync("GameScene");
|
||||
asyncOperation.allowSceneActivation = false;
|
||||
}
|
||||
}
|
||||
|
||||
public partial class MenuManager : MonoBehaviour
|
||||
public partial class MenuManager
|
||||
{
|
||||
public Sprite testSprite;
|
||||
public Switch testChapterSwitch;
|
||||
@@ -37,7 +51,7 @@ namespace Ichni.Menu
|
||||
"Trader",
|
||||
Color.red, testSprite,testChapterSwitch, testMusicSwitch);
|
||||
|
||||
SceneManager.LoadScene("GameScene");
|
||||
asyncOperation.allowSceneActivation = true;
|
||||
}
|
||||
|
||||
[Button]
|
||||
|
||||
8
Assets/Scripts/Menu/SongSelection.meta
Normal file
8
Assets/Scripts/Menu/SongSelection.meta
Normal file
@@ -0,0 +1,8 @@
|
||||
fileFormatVersion: 2
|
||||
guid: b7a92293064a12b44b29a26166706d0a
|
||||
folderAsset: yes
|
||||
DefaultImporter:
|
||||
externalObjects: {}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
18
Assets/Scripts/Menu/SongSelection/SongSelectionManager.cs
Normal file
18
Assets/Scripts/Menu/SongSelection/SongSelectionManager.cs
Normal file
@@ -0,0 +1,18 @@
|
||||
using System.Collections;
|
||||
using System.Collections.Generic;
|
||||
using UnityEngine;
|
||||
|
||||
public class SongSelectionManager : MonoBehaviour
|
||||
{
|
||||
// Start is called before the first frame update
|
||||
void Start()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
// Update is called once per frame
|
||||
void Update()
|
||||
{
|
||||
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,11 @@
|
||||
fileFormatVersion: 2
|
||||
guid: 726b9313110aee54fbba1c1891bdaa1a
|
||||
MonoImporter:
|
||||
externalObjects: {}
|
||||
serializedVersion: 2
|
||||
defaultReferences: []
|
||||
executionOrder: 0
|
||||
icon: {instanceID: 0}
|
||||
userData:
|
||||
assetBundleName:
|
||||
assetBundleVariant:
|
||||
Reference in New Issue
Block a user