[F] Seek resets speed
Build AquaMai / build (push) Has been cancelled Details

pull/69/head
Clansty 2024-10-16 18:11:17 +08:00
parent 1810bbe2d5
commit 953083a0bf
No known key found for this signature in database
GPG Key ID: 3A6BE8BAF2EDE134
2 changed files with 20 additions and 2 deletions

View File

@ -1,4 +1,5 @@
using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using AquaMai.Fix;
@ -51,6 +52,17 @@ public class PractiseMode
movie.player.SetSpeed(speed);
}
private static IEnumerator SetSpeedCoroutineInner()
{
yield return null;
SetSpeed();
}
public static void SetSpeedCoroutine()
{
SharedInstances.GameMainObject.StartCoroutine(SetSpeedCoroutineInner());
}
public static void SpeedUp()
{
speed += .05f;
@ -65,9 +77,9 @@ public class PractiseMode
public static void SpeedDown()
{
speed -= .05f;
if (speed < 0.5)
if (speed < 0.05)
{
speed = 0.5f;
speed = 0.05f;
}
SetSpeed();

View File

@ -91,14 +91,20 @@ public class PractiseModeUI : MonoBehaviour
if (InputManager.GetTouchPanelAreaDown(InputManager.TouchPanelArea.E8))
{
DebugFeature.Seek(-1000);
PractiseMode.SetSpeedCoroutine();
}
else if (InputManager.GetTouchPanelAreaDown(InputManager.TouchPanelArea.E2))
{
DebugFeature.Seek(1000);
PractiseMode.SetSpeedCoroutine();
}
else if (InputManager.GetTouchPanelAreaDown(InputManager.TouchPanelArea.B8) || InputManager.GetTouchPanelAreaDown(InputManager.TouchPanelArea.B1))
{
DebugFeature.Pause = !DebugFeature.Pause;
if (!DebugFeature.Pause)
{
PractiseMode.SetSpeedCoroutine();
}
}
else if (InputManager.GetTouchPanelAreaDown(InputManager.TouchPanelArea.B7) && PractiseMode.repeatStart == -1)
{