From a663a9e7d85faf781dc236c2ac71c6514054c20c Mon Sep 17 00:00:00 2001 From: blank3times <105398129+blank3times@users.noreply.github.com> Date: Fri, 26 Jan 2024 17:55:12 -0800 Subject: [PATCH] Update monkey input temp results for clarity --- Assets/Scripts/Games/HoleInOne/HoleInOne.cs | 37 +++++++++++---------- 1 file changed, 19 insertions(+), 18 deletions(-) diff --git a/Assets/Scripts/Games/HoleInOne/HoleInOne.cs b/Assets/Scripts/Games/HoleInOne/HoleInOne.cs index b7d57b328..ce25465b6 100644 --- a/Assets/Scripts/Games/HoleInOne/HoleInOne.cs +++ b/Assets/Scripts/Games/HoleInOne/HoleInOne.cs @@ -18,7 +18,7 @@ namespace HeavenStudio.Games.Loaders { return new Minigame("holeInOne", "Hole in One", "6ab99e", false, false, new List() { - new GameAction("testanims", "Test Animation") + new GameAction("testanims", "Test Animation") // Delete this one when the game is more competent { function = delegate { HoleInOne.instance.DoTestAnim(eventCaller.currentEntity.beat); }, }, @@ -27,7 +27,7 @@ namespace HeavenStudio.Games.Loaders function = delegate { HoleInOne.instance.DoMandrill(eventCaller.currentEntity.beat); }, defaultLength = 4.0f, }, - new GameAction("monkey", "Monkey (sound only)") + new GameAction("monkey", "Monkey") { function = delegate { HoleInOne.instance.DoMonkey(eventCaller.currentEntity.beat); }, defaultLength = 3.0f, @@ -51,12 +51,12 @@ namespace HeavenStudio.Games public static HoleInOne instance; - // Start is called before the first frame update void Awake() { HoleInOne.instance = this; } + // Delete this one when the game is more competent public void DoTestAnim(double beat) { SoundByte.PlayOneShotGame("holeInOne/whale"); @@ -66,7 +66,7 @@ namespace HeavenStudio.Games public void DoMandrill(double beat) { //Mandrill Multisound - ScheduleInput(beat, 3f, InputAction_BasicPress, CatchSuccess, CatchSuccess1, CatchSuccess2); + // ScheduleInput(beat, 3f, InputAction_BasicPress, CatchSuccess, CatchSuccess1, CatchSuccess2); MultiSound.Play(new MultiSound.Sound[] { new MultiSound.Sound("holeInOne/mandrill1", beat), new MultiSound.Sound("holeInOne/mandrill2", beat + 1f), @@ -86,35 +86,36 @@ namespace HeavenStudio.Games public void DoMonkey(double beat) { //Monkey Multisound - ScheduleInput(beat, 2f, InputAction_BasicPress, CatchSuccess, CatchSuccess1, CatchSuccess2); + ScheduleInput(beat, 2f, InputAction_BasicPress, MonkeySuccess, MonkeyMiss, MonkeyWhiff); MultiSound.Play(new MultiSound.Sound[] { new MultiSound.Sound("holeInOne/monkey1", beat), - new MultiSound.Sound("holeInOne/monkey2", beat + 1f), - new MultiSound.Sound("holeInOne/hole1", beat + 2f), + new MultiSound.Sound("holeInOne/monkey2", beat + 1f) }); - // BeatAction.New(instance, new List() - // { - // new BeatAction.Action(beat, delegate { FarCrane.DoScaledAnimationAsync("Drop", 0.5f);}), - // new BeatAction.Action(beat + 1.0f, delegate { FarCrane.DoScaledAnimationAsync("Open", 0.5f);}), - // new BeatAction.Action(beat + 1.5f, delegate { FarCrane.DoScaledAnimationAsync("Lift", 0.5f);}), - // }); + BeatAction.New(instance, new List() + { + new BeatAction.Action(beat, delegate { MonkeyAnim.Play("MonkeyPrepare");}), + new BeatAction.Action(beat + 1.0f, delegate { MonkeyAnim.Play("MonkeyThrow");}), + }); } - public void CatchSuccess(PlayerActionEvent caller, float state) + public void MonkeySuccess(PlayerActionEvent caller, float state) { - SoundByte.PlayOneShotGame("holeInOne/whale"); + SoundByte.PlayOneShotGame("holeInOne/monkey3"); + MonkeyAnim.Play("MonkeySpin"); } - public void CatchSuccess1(PlayerActionEvent caller) + public void MonkeyMiss(PlayerActionEvent caller) { SoundByte.PlayOneShotGame("holeInOne/whale"); + MonkeyAnim.Play("MonkeySpin"); } - public void CatchSuccess2(PlayerActionEvent caller) + public void MonkeyWhiff(PlayerActionEvent caller) { - SoundByte.PlayOneShotGame("holeInOne/whale"); + SoundByte.PlayOneShotGame("holeInOne/mandrill4"); + MonkeyAnim.Play("MonkeyBop"); } } } \ No newline at end of file