forked from akanyan/mu3-mods
fix: various fixes
This commit is contained in:
@ -2,14 +2,19 @@
|
||||
using MU3.Game;
|
||||
using MU3.Sequence;
|
||||
using MU3.Util;
|
||||
using System.Collections;
|
||||
using UnityEngine;
|
||||
|
||||
namespace MU3;
|
||||
|
||||
class patch_UIResultTechScore: UIResultTechScore {
|
||||
private Animator animator_;
|
||||
private MU3UICounter counterFast_;
|
||||
private MU3UICounter counterLate_;
|
||||
|
||||
private static readonly int State_TechnicalScore_noLateFast_Loop = Animator.StringToHash("TechnicalScore_noLateFast_Loop");
|
||||
private static readonly int State_TechnicalScore_Loop = Animator.StringToHash("TechnicalScore_Loop");
|
||||
|
||||
private void cloneCounter(MU3UICounter counter, Color color, int value) {
|
||||
var otherValue = counter.CounterAsInt;
|
||||
var offset = 12;
|
||||
@ -27,7 +32,11 @@ class patch_UIResultTechScore: UIResultTechScore {
|
||||
cpy.CounterAsInt = value;
|
||||
}
|
||||
|
||||
private void drawCounters() {
|
||||
private IEnumerator drawCounters() {
|
||||
while(!AnimatorState.stateEquals(animator_, State_TechnicalScore_noLateFast_Loop) && !AnimatorState.stateEquals(animator_, State_TechnicalScore_Loop)) {
|
||||
yield return null;
|
||||
}
|
||||
|
||||
float posXf = counterFast_.gameObject.transform.localPosition.x + 5.0f;
|
||||
float posXl = counterLate_.gameObject.transform.localPosition.x + 5.0f;
|
||||
float posY = counterLate_.gameObject.transform.localPosition.y;
|
||||
@ -53,6 +62,6 @@ class patch_UIResultTechScore: UIResultTechScore {
|
||||
private extern void orig_drawTimingInclination(int numNotesFast, int numNotesLate);
|
||||
private void drawTimingInclination(int numNotesFast, int numNotesLate) {
|
||||
orig_drawTimingInclination(numNotesFast, numNotesLate);
|
||||
drawCounters();
|
||||
StartCoroutine(drawCounters());
|
||||
}
|
||||
}
|
||||
|
@ -29,15 +29,6 @@ class patch_PlayMusic: PlayMusic {
|
||||
}
|
||||
}
|
||||
|
||||
private extern void orig_Enter_PlayEnd();
|
||||
private void Enter_PlayEnd() {
|
||||
using IniFile iniFile = new("mu3.ini");
|
||||
|
||||
if(iniFile.getValue("Sequence", "QuickEnd", false) && !isPartyPlay()) {
|
||||
_nuclearSkip = true;
|
||||
}
|
||||
}
|
||||
|
||||
public extern bool orig_updateState(float deltaTime);
|
||||
public override bool updateState(float deltaTime = -1f) {
|
||||
var state = getCurrentState();
|
||||
@ -49,6 +40,7 @@ class patch_PlayMusic: PlayMusic {
|
||||
if(_nuclearSkip) {
|
||||
bool isTutorial = SingletonMonoBehaviour<GameEngine>.instance.sessionInfo.isTutorial;
|
||||
if(!isTutorial) {
|
||||
Singleton<Mod.State>.instance.SkipItemFrame = true;
|
||||
if(state < EState.CalcResult) {
|
||||
setNextState(EState.CalcResult);
|
||||
}
|
||||
|
@ -1,5 +1,4 @@
|
||||
using MonoMod;
|
||||
using MU3.Sequence;
|
||||
using MU3.Util;
|
||||
using System;
|
||||
using UnityEngine;
|
||||
|
@ -52,7 +52,7 @@ class patch_UserDetail: UserDetail {
|
||||
try {
|
||||
File.WriteAllText(path, entries.Aggregate("", (acc, s) => acc + s + "\n").Trim());
|
||||
} catch(Exception e) {
|
||||
UnityEngine.Debug.Log("Unable to write tab selection: " + e.ToString());
|
||||
UnityEngine.Debug.Log("[SortByInternal] Unable to write tab selection: " + e.ToString());
|
||||
}
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user