mirror of
https://github.com/RHeavenStudio/HeavenStudio.git
synced 2025-06-13 11:37:40 +02:00
change operation order for input checks
This commit is contained in:
@ -169,23 +169,21 @@ namespace HeavenStudio.Games.Scripts_DJSchool
|
||||
public void OnHitSwipe(PlayerActionEvent caller, float beat)
|
||||
{
|
||||
game.shouldBeHolding = false;
|
||||
isHolding = false;
|
||||
swiping = true;
|
||||
SoundByte.PlayOneShotGame("djSchool/recordSwipe");
|
||||
anim.Play("Swipe", 0, 0);
|
||||
if (beat >= 1f || beat <= -1f) missed = true;
|
||||
if (!missed)
|
||||
{
|
||||
isHolding = false;
|
||||
|
||||
missed = false;
|
||||
shouldBeHolding = false;
|
||||
SoundByte.PlayOneShotGame("djSchool/recordSwipe");
|
||||
FlashFX(false);
|
||||
swiping = true;
|
||||
|
||||
BeatAction.New(this, new List<BeatAction.Action>()
|
||||
{
|
||||
new BeatAction.Action(beat, delegate { anim.Play("Swipe", 0, 0); }),
|
||||
new BeatAction.Action(beat + 4f, delegate { swiping = false; }),
|
||||
});
|
||||
//anim.Play("Swipe", 0, 0);
|
||||
game.djYellowScript.ChangeHeadSprite(DJYellow.DJExpression.UpSecond);
|
||||
game.djYellowScript.Reverse();
|
||||
game.smileBeat = caller.timer + caller.startBeat + 1f;
|
||||
@ -199,13 +197,10 @@ namespace HeavenStudio.Games.Scripts_DJSchool
|
||||
else
|
||||
{
|
||||
OnMissSwipeForPlayerInput(caller.timer + caller.startBeat + 1);
|
||||
SoundByte.PlayOneShotGame("djSchool/recordSwipe");
|
||||
BeatAction.New(this, new List<BeatAction.Action>()
|
||||
{
|
||||
new BeatAction.Action(beat, delegate { anim.Play("Swipe", 0, 0); }),
|
||||
new BeatAction.Action(beat + 4f, delegate { swiping = false; }),
|
||||
});
|
||||
//anim.Play("Swipe", 0, 0);
|
||||
tableAnim.speed = 1;
|
||||
tableAnim.DoScaledAnimationAsync("Student_Turntable_Swipe", 0.5f);
|
||||
|
||||
@ -304,7 +299,6 @@ namespace HeavenStudio.Games.Scripts_DJSchool
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
//Not sure but will do?
|
||||
private void OnDestroy()
|
||||
{
|
||||
|
Reference in New Issue
Block a user