mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-12 21:47:39 +02:00
Upgrade renderer to the universal render pipeline
This commit is contained in:
@ -58,8 +58,16 @@ namespace RhythmHeavenMania
|
||||
sp.sortingOrder = 30000;
|
||||
this.gameObject.layer = 3;
|
||||
|
||||
string json = txt.text;
|
||||
Beatmap = JsonConvert.DeserializeObject<Beatmap>(json);
|
||||
if (txt != null)
|
||||
{
|
||||
string json = txt.text;
|
||||
Beatmap = JsonConvert.DeserializeObject<Beatmap>(json);
|
||||
}
|
||||
else
|
||||
{
|
||||
Beatmap = new Beatmap();
|
||||
Beatmap.bpm = 120f;
|
||||
}
|
||||
|
||||
SortEventsList();
|
||||
|
||||
@ -82,6 +90,10 @@ namespace RhythmHeavenMania
|
||||
SetCurrentGame(Beatmap.entities[0].datamodel.Split(0));
|
||||
SetGame(Beatmap.entities[0].datamodel.Split(0));
|
||||
}
|
||||
else
|
||||
{
|
||||
SetGame("noGame");
|
||||
}
|
||||
}
|
||||
|
||||
// LateUpdate works a bit better but causes a bit of bugs, so remind me to fix those eventually
|
||||
@ -223,6 +235,10 @@ namespace RhythmHeavenMania
|
||||
|
||||
SetGame(newGame);
|
||||
}
|
||||
else
|
||||
{
|
||||
SetGame("noGame");
|
||||
}
|
||||
|
||||
if (Beatmap.tempoChanges.Count > 0)
|
||||
{
|
||||
@ -285,13 +301,11 @@ namespace RhythmHeavenMania
|
||||
currentGameO.name = game;
|
||||
}
|
||||
|
||||
GameCamera.orthographic = true;
|
||||
|
||||
if (onGameSwitch)
|
||||
/*if (onGameSwitch)
|
||||
{
|
||||
if (GetGame(currentGame).GetComponent<Minigame>() != null)
|
||||
GetGame(game).GetComponent<Minigame>().OnGameSwitch();
|
||||
}
|
||||
}*/
|
||||
|
||||
SetCurrentGame(game);
|
||||
}
|
||||
@ -331,7 +345,9 @@ namespace RhythmHeavenMania
|
||||
public void SetCurrentGame(string game)
|
||||
{
|
||||
currentGame = game;
|
||||
CircleCursor.InnerCircle.GetComponent<SpriteRenderer>().color = Colors.Hex2RGB(GetGameInfo(currentGame).color);
|
||||
if (GetGameInfo(currentGame) != null) CircleCursor.InnerCircle.GetComponent<SpriteRenderer>().color = Colors.Hex2RGB(GetGameInfo(currentGame).color);
|
||||
else
|
||||
CircleCursor.InnerCircle.GetComponent<SpriteRenderer>().color = Color.white;
|
||||
}
|
||||
|
||||
private bool SongPosLessThanClipLength(float t)
|
||||
|
Reference in New Issue
Block a user