Stretch Camera VFX Event + Fixes (#586)

* fixed blue bear bug

* glee club fix

* added stretch camera vfx event

* toss boys crouch fixed
This commit is contained in:
Rapandrasmus
2023-11-25 17:05:20 +01:00
committed by GitHub
parent 13db943ab5
commit 4f07d47bdb
9 changed files with 148 additions and 43 deletions

View File

@ -221,18 +221,6 @@ namespace HeavenStudio.Games
return default(SuperCurveObject.Path);
}
void OnDestroy()
{
foreach (var evt in scheduledInputs)
{
evt.Disable();
}
if (Conductor.instance.isPlaying || Conductor.instance.isPaused) return;
rightCrumbAppearThreshold = 15;
leftCrumbAppearThreshold = 30;
eatenTreats = 0;
}
private void Awake()
{
instance = this;
@ -357,7 +345,7 @@ namespace HeavenStudio.Games
if (_allEmotionsStretch.Count == 0) return;
UpdateEmotions();
var allEmosBeforeBeat = EventCaller.GetAllInGameManagerList("blueBear", new string[] { "stretchEmotion" }).FindAll(x => x.beat < beat);
if (allEmosBeforeBeat.Count == 0) return;
if ((EmotionStretchType)allEmosBeforeBeat[^1]["type"] == EmotionStretchType.StartCrying)
{
headAndBodyAnim.DoScaledAnimationAsync("CryIdle", 0.5f);

View File

@ -74,7 +74,7 @@ namespace HeavenStudio.Games.Scripts_GleeClub
anim.SetBool("Mega", true);
anim.Play("OpenMouth", 0, 0);
shouldMegaClose = true;
if (currentSound != null) SoundByte.KillLoop(currentSound, 0f);
if (currentSound != null) currentSound.Stop();
SoundByte.PlayOneShotGame("gleeClub/LoudWailStart");
currentSound = SoundByte.PlayOneShotGame("gleeClub/LoudWailLoop", -1, currentPitch, 1f, true);
BeatAction.New(game, new List<BeatAction.Action>()
@ -95,7 +95,7 @@ namespace HeavenStudio.Games.Scripts_GleeClub
anim.SetBool("Mega", false);
shouldMegaClose = false;
anim.Play("OpenMouth", 0, 0);
if (currentSound != null) SoundByte.KillLoop(currentSound, 0f);
if (currentSound != null) currentSound.Stop();
currentSound = SoundByte.PlayOneShotGame("gleeClub/WailLoop", -1, currentPitch, 1f, true);
}
@ -104,7 +104,7 @@ namespace HeavenStudio.Games.Scripts_GleeClub
if (!singing || disappeared) return;
singing = false;
anim.Play(mega ? "MegaCloseMouth" : "CloseMouth", 0, 0);
if (currentSound != null) SoundByte.KillLoop(currentSound, 0f);
if (currentSound != null) currentSound.Stop();
if (playSound) SoundByte.PlayOneShotGame("gleeClub/StopWail");
}
}

View File

@ -1065,8 +1065,7 @@ namespace HeavenStudio.Games
if (currentSpecialKid != null) currentSpecialKid.crouch = false;
currentSpecialKid = GetCurrentReceiver();
if (PlayerInput.CurrentControlStyle != InputController.ControlStyles.Touch)
GetCurrentReceiver().Crouch();
GetCurrentReceiver().Crouch();
GetSpecialBasedOnReceiver().SetActive(true);
switch (currentReceiver)

View File

@ -35,7 +35,6 @@ namespace HeavenStudio.Games.Scripts_TossBoys
DoAnimationScaledAsync("Whiff", 0.5f);
SoundByte.PlayOneShotGame("tossBoys/whiff");
}
crouch = false;
preparing = false;
}
@ -51,12 +50,6 @@ namespace HeavenStudio.Games.Scripts_TossBoys
crouch = true;
}
public void UnCrouch()
{
DoAnimationScaledAsync("Idle", 1f);
crouch = false;
}
public void PopBall()
{
DoAnimationScaledAsync("Slap", 0.5f);