What do I name these sorts of PRs?? Anyways fixes and stuff! (#592)

* blue bear and bop region fix

* fixed see saw bug

* I hate blue bear.

* Accuracy

* random things

* extended bgs

* karate man stuff

* ok

* star colors and senior gradient

* reworked blue bear emotions again

* head seperated in ringside

* fix

* blink fix

* blink fix again

* no cancel

* karate man right hand thing

* new sheet

* oops

* bop anim fix

* i have made a severe and continuous lapse in judgement

* fixed stuff

* fixed stuff in sneak y Psirits

* drumming practice new sprites and anims

* extended bg

* the blush was lower on z axis oops

* if you love it so much why dont u put a ringside on it

* blue bear change

* Double date !

* new karate joe heads + snow and double date bench fix

* ops

* fixed breakup anim thing

* story position fixes

* oops

* smile anim fix

* added jump option

---------

Co-authored-by: ev <85412919+evdial@users.noreply.github.com>
This commit is contained in:
Rapandrasmus
2023-12-12 17:54:04 +01:00
committed by GitHub
parent 87653b0d65
commit a72e2a154b
127 changed files with 53129 additions and 9172 deletions

View File

@ -18,30 +18,37 @@ namespace HeavenStudio.Games.Loaders
new GameAction("donut", "Donut")
{
preFunction = delegate { BlueBear.TreatSound(eventCaller.currentEntity.beat, false); },
function = delegate { BlueBear.instance.SpawnTreat(eventCaller.currentEntity.beat, false, eventCaller.currentEntity.beat); },
function = delegate { BlueBear.instance.SpawnTreat(eventCaller.currentEntity.beat, false, eventCaller.currentEntity.beat, eventCaller.currentEntity["long"], eventCaller.currentEntity["open"]); },
defaultLength = 3,
parameters = new()
{
new("long", false, "Mouth Hold"),
new("open", true, "Should Open Mouth")
}
},
new GameAction("cake", "Cake")
{
preFunction = delegate { BlueBear.TreatSound(eventCaller.currentEntity.beat, true); },
function = delegate { BlueBear.instance.SpawnTreat(eventCaller.currentEntity.beat, true, eventCaller.currentEntity.beat); },
function = delegate { BlueBear.instance.SpawnTreat(eventCaller.currentEntity.beat, true, eventCaller.currentEntity.beat, eventCaller.currentEntity["long"], eventCaller.currentEntity["open"]); },
defaultLength = 4,
},
new GameAction("setEmotion", "Emotion")
{
function = delegate { var e = eventCaller.currentEntity; BlueBear.instance.SetEmotion(e.beat, e["type"]); },
parameters = new List<Param>()
parameters = new()
{
new Param("type", BlueBear.EmotionType.ClosedEyes, "Emotion", "Which emotion should the blue bear use?")
new("long", false, "Mouth Hold"),
new("open", true, "Should Open Mouth")
}
},
new GameAction("stretchEmotion", "Long Emotion")
{
new GameAction("stretchEmotion", "Emotion")
{
function = delegate { var e = eventCaller.currentEntity; if (e["instant"] || e["type"] == (int)BlueBear.EmotionStretchType.NoEmotion) BlueBear.instance.SetEmotion(e.beat, e["type"]); },
defaultLength = 4,
resizable = true,
parameters = new List<Param>()
{
new Param("type", BlueBear.EmotionStretchType.LookUp, "Emotion", "Which emotion should the blue bear use?")
new Param("type", BlueBear.EmotionStretchType.NoEmotion, "Emotion", "Which emotion should the blue bear use?", new()
{
new((x, _) => (int)x != (int)BlueBear.EmotionStretchType.NoEmotion, new string[] { "instant" })
}),
new Param("instant", false, "Instant"),
}
},
new GameAction("wind", "Wind")
@ -49,6 +56,16 @@ namespace HeavenStudio.Games.Loaders
function = delegate { BlueBear.instance.Wind(); },
defaultLength = 0.5f
},
new GameAction("sigh", "Sigh")
{
function = delegate { BlueBear.instance.Sigh(); },
defaultLength = 0.5f
},
new GameAction("open", "Open Mouth")
{
function = delegate { BlueBear.instance.OpenMouth(); },
defaultLength = 0.5f
},
new GameAction("story", "Story")
{
defaultLength = 4,
@ -86,15 +103,9 @@ namespace HeavenStudio.Games
public class BlueBear : Minigame
{
public enum EmotionType
{
Neutral = 0,
ClosedEyes = 1,
Cry = 2,
Sigh = 3
}
public enum EmotionStretchType
{
NoEmotion = -1,
LookUp = 0,
Smile = 1,
StartCrying = 2,
@ -138,6 +149,7 @@ namespace HeavenStudio.Games
public Gradient cakeGradient;
private bool squashing;
[NonSerialized] public int shouldOpenMouthCount = 0;
public static BlueBear instance;
@ -271,7 +283,7 @@ namespace HeavenStudio.Games
private void Update()
{
headAndBodyAnim.SetBool("ShouldOpenMouth", foodHolder.childCount != 0);
headAndBodyAnim.SetBool("ShouldOpenMouth", shouldOpenMouthCount != 0 || _wantMouthOpen);
if (headAndBodyAnim.GetBool("ShouldOpenMouth"))
{
_emotionCancelledBeat = Conductor.instance.songPositionInBeatsAsDouble;
@ -280,12 +292,12 @@ namespace HeavenStudio.Games
if (PlayerInput.GetIsAction(InputAction_Left) && !IsExpectingInputNow(InputAction_Left.inputLockCategory))
{
SoundByte.PlayOneShotGame("blueBear/whiff", -1, SoundByte.GetPitchFromSemiTones(UnityEngine.Random.Range(-1, 2), false));
Bite(Conductor.instance.songPositionInBeatsAsDouble, true);
Bite(Conductor.instance.songPositionInBeatsAsDouble, true, false);
}
else if (PlayerInput.GetIsAction(InputAction_Right) && !IsExpectingInputNow(InputAction_Right.inputLockCategory))
{
SoundByte.PlayOneShotGame("blueBear/whiff", -1, SoundByte.GetPitchFromSemiTones(UnityEngine.Random.Range(-1, 2), false));
Bite(Conductor.instance.songPositionInBeatsAsDouble, false);
Bite(Conductor.instance.songPositionInBeatsAsDouble, false, false);
}
UpdateEmotions();
@ -302,6 +314,7 @@ namespace HeavenStudio.Games
private int _emotionIndex = 0;
private List<RiqEntity> _allEmotionsStretch = new();
private EmotionStretchType _lastEmotion = EmotionStretchType.LookUp;
private bool _firstEmotionFrame = true;
private void UpdateEmotions()
{
@ -317,41 +330,57 @@ namespace HeavenStudio.Games
_emotionIndex++;
_lastEmotion = (EmotionStretchType)_allEmotionsStretch[_emotionIndex - 1]["type"];
crying = _lastEmotion == EmotionStretchType.StartCrying;
_firstEmotionFrame = true;
if (_lastEmotion == EmotionStretchType.Smile)
{
headAndBodyAnim.DoScaledAnimationAsync("StopSmile", 0.5f);
}
UpdateEmotions();
return;
}
if (beat >= e.beat && beat < e.beat + e.length && !(_emotionCancelledBeat >= e.beat && _emotionCancelledBeat < e.beat + e.length))
if (beat >= e.beat && beat < e.beat + e.length && !(_emotionCancelledBeat >= e.beat))
{
_lastEmotion = (EmotionStretchType)e["type"];
crying = _lastEmotion == EmotionStretchType.StartCrying;
if (_firstEmotionFrame && _lastEmotion == EmotionStretchType.Smile)
{
headAndBodyAnim.DoScaledAnimationAsync("Smile", 0.5f);
_firstEmotionFrame = false;
}
float normalizedBeat = cond.GetPositionFromBeat(e.beat, e.length);
string animName = (EmotionStretchType)e["type"] switch
{
EmotionStretchType.LookUp => "OpenEyes",
EmotionStretchType.Smile => "Smile",
EmotionStretchType.Smile => "",
EmotionStretchType.StartCrying => "Sad",
EmotionStretchType.NoEmotion => "",
_ => throw new NotImplementedException(),
};
headAndBodyAnim.DoNormalizedAnimation(animName, normalizedBeat);
if (animName != "") headAndBodyAnim.DoNormalizedAnimation(animName, normalizedBeat);
}
}
private void HandleEmotions(double beat)
{
_allEmotionsStretch = EventCaller.GetAllInGameManagerList("blueBear", new string[] { "stretchEmotion" });
_allEmotionsStretch = EventCaller.GetAllInGameManagerList("blueBear", new string[] { "stretchEmotion" }).FindAll(x => !(x["instant"] || x["type"] == (int)EmotionStretchType.NoEmotion));
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)
var allEmosBeforeBeat = _allEmotionsStretch.FindAll(x => x.beat < beat);
if (allEmosBeforeBeat.Count != 0)
{
headAndBodyAnim.DoScaledAnimationAsync("CryIdle", 0.5f);
}
else if ((EmotionStretchType)allEmosBeforeBeat[^1]["type"] == EmotionStretchType.Smile)
{
headAndBodyAnim.DoScaledAnimationAsync("SmileIdle", 0.5f);
if ((EmotionStretchType)allEmosBeforeBeat[^1]["type"] == EmotionStretchType.StartCrying)
{
headAndBodyAnim.DoScaledAnimationAsync("CryIdle", 0.5f);
}
else if ((EmotionStretchType)allEmosBeforeBeat[^1]["type"] == EmotionStretchType.Smile)
{
headAndBodyAnim.DoScaledAnimationAsync("SmileIdle", 0.5f);
}
}
}
@ -377,7 +406,7 @@ namespace HeavenStudio.Games
{
if (e.beat + e.length - 1 > gameswitchBeat && e.beat < gameswitchBeat)
{
SpawnTreat(e.beat, e.datamodel == "blueBear/cake", gameswitchBeat);
SpawnTreat(e.beat, e.datamodel == "blueBear/cake", gameswitchBeat, e["long"], e["open"]);
}
}
}
@ -387,16 +416,27 @@ namespace HeavenStudio.Games
windAnim.DoScaledAnimationAsync("Wind", 0.5f);
}
public void Bite(double beat, bool left)
public void Sigh()
{
headAndBodyAnim.DoScaledAnimationAsync("Sigh", 0.5f);
}
public void OpenMouth()
{
_wantMouthOpen = true;
}
public void Bite(double beat, bool left, bool longBite)
{
_emotionCancelledBeat = beat;
_wantMouthOpen = false;
if (crying)
{
headAndBodyAnim.DoScaledAnimationAsync(left ? "CryBiteL" : "CryBiteR", 0.5f);
headAndBodyAnim.DoScaledAnimationAsync((longBite ? "Long" : "") + (left ? "CryBiteL" : "CryBiteR"), 0.5f);
}
else
{
headAndBodyAnim.DoScaledAnimationAsync(left ? "BiteL" : "BiteR", 0.5f);
headAndBodyAnim.DoScaledAnimationAsync((longBite ? "Long" : "") + (left ? "BiteL" : "BiteR"), 0.5f);
}
}
@ -455,41 +495,43 @@ namespace HeavenStudio.Games
}
}
public void SetEmotion(double beat, int emotion)
private bool _wantMouthOpen = false;
public void SetEmotion(double beat, int emotion, bool ableToStopSmile = true)
{
_emotionCancelledBeat = beat;
_wantMouthOpen = false;
crying = false;
switch (emotion)
{
case (int)EmotionType.Neutral:
case (int)EmotionStretchType.NoEmotion:
headAndBodyAnim.DoScaledAnimationAsync("Idle", 0.5f);
if (_allEmotionsStretch.Count == 0 || _lastEmotion != EmotionStretchType.Smile) return;
headAndBodyAnim.DoScaledAnimationAsync("StopSmile", 0.5f);
crying = false;
break;
case (int)EmotionType.ClosedEyes:
case (int)EmotionStretchType.LookUp:
headAndBodyAnim.DoScaledAnimationAsync("EyesClosed", 0.5f);
crying = false;
break;
case (int)EmotionType.Cry:
case (int)EmotionStretchType.StartCrying:
headAndBodyAnim.DoScaledAnimationAsync("CryIdle", 0.5f);
crying = true;
break;
case (int)EmotionType.Sigh:
headAndBodyAnim.DoScaledAnimationAsync("Sigh", 0.5f);
crying = false;
case (int)EmotionStretchType.Smile:
headAndBodyAnim.DoScaledAnimationAsync("SmileIdle", 0.5f);
break;
default:
break;
}
}
public void SpawnTreat(double beat, bool isCake, double gameSwitchBeat)
public void SpawnTreat(double beat, bool isCake, double gameSwitchBeat, bool longBite, bool shouldOpen)
{
var objectToSpawn = isCake ? cakeBase : donutBase;
var newTreat = GameObject.Instantiate(objectToSpawn, foodHolder);
var treatComp = newTreat.GetComponent<Treat>();
treatComp.startBeat = beat;
treatComp.hold = longBite;
treatComp.shouldOpen = shouldOpen;
if (shouldOpen) shouldOpenMouthCount++;
newTreat.SetActive(true);

View File

@ -13,10 +13,12 @@ namespace HeavenStudio.Games.Scripts_BlueBear
const float barelyDistX = 1.5f;
const float barelyDistY = -6f;
const float barelyHeight = 4f;
const float rotSpeed = 360f * 3;
const float rotSpeed = 280f;
public bool isCake;
public double startBeat;
[NonSerialized] public bool hold = false;
[NonSerialized] public bool shouldOpen = true;
double flyBeats;
private Path path;
@ -42,6 +44,11 @@ namespace HeavenStudio.Games.Scripts_BlueBear
Update();
}
private void OnDestroy()
{
if (shouldOpen) game.shouldOpenMouthCount--;
}
private void Update()
{
var cond = Conductor.instance;
@ -55,7 +62,7 @@ namespace HeavenStudio.Games.Scripts_BlueBear
}
float rot = isCake ? rotSpeed : -rotSpeed;
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (rot * Time.deltaTime * cond.pitchedSecPerBeat));
transform.rotation = Quaternion.Euler(0, 0, transform.rotation.eulerAngles.z + (rot * Time.deltaTime / cond.pitchedSecPerBeat));
}
void EatFood()
{
@ -68,7 +75,7 @@ namespace HeavenStudio.Games.Scripts_BlueBear
SoundByte.PlayOneShotGame("blueBear/chompDonut");
}
game.Bite(Conductor.instance.songPositionInBeatsAsDouble, isCake);
game.Bite(Conductor.instance.songPositionInBeatsAsDouble, isCake, hold);
game.EatTreat();
SpawnCrumbs();

View File

@ -15,6 +15,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
private double pathStartBeat = double.MinValue;
private Conductor conductor;
private GameObject shadow;
private bool _jump;
void Awake()
{
@ -37,8 +38,9 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
shadow.transform.localScale = Vector3.one * Mathf.Clamp(((transform.position.y) - game.shadowDepthScaleMin) / (game.shadowDepthScaleMax - game.shadowDepthScaleMin), 0f, 1f);
}
public void Init(double beat)
public void Init(double beat, bool shouldJump)
{
_jump = shouldJump;
game.ScheduleInput(beat, 1f, DoubleDate.InputAction_FlickPress, Just, Miss, Empty);
path = game.GetPath("BasketBallIn");
UpdateLastRealPos();
@ -80,7 +82,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
UpdateLastRealPos();
pathStartBeat = conductor.songPositionInBeatsAsDouble;
path = game.GetPath("BasketBallJust");
game.Kick();
game.Kick(true, false, true, _jump);
SoundByte.PlayOneShotGame("doubleDate/kick");
}

View File

@ -23,22 +23,65 @@ namespace HeavenStudio.Games.Loaders
},
new GameAction("soccer", "Soccer Ball")
{
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueSoccerBall(e.beat); },
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueSoccerBall(e.beat, e["b"]); },
preFunctionLength = 1f,
defaultLength = 2f,
parameters = new()
{
new("b", false, "Weasels Jump")
}
},
new GameAction("basket", "Basket Ball")
{
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueBasketBall(e.beat); },
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueBasketBall(e.beat, e["b"]); },
preFunctionLength = 1f,
defaultLength = 2f,
parameters = new()
{
new("b", false, "Weasels Jump")
}
},
new GameAction("football", "Football")
{
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueFootBall(e.beat); },
preFunction = delegate { var e = eventCaller.currentEntity; DoubleDate.QueueFootBall(e.beat, e["b"]); },
preFunctionLength = 1f,
defaultLength = 2.5f,
parameters = new()
{
new("b", true, "Weasels Jump")
}
},
new GameAction("blush", "Blush")
{
function = delegate { DoubleDate.instance.GirlBlush(); }
},
new GameAction("toggleGirls", "Girls Presence")
{
function = delegate { DoubleDate.instance.ToggleGirls(eventCaller.currentEntity["b"]); },
defaultLength = 0.5f,
parameters = new()
{
new("b", false, "Present?")
}
},
new GameAction("stare", "Boy Stare")
{
function = delegate { DoubleDate.instance.ToggleStare(eventCaller.currentEntity["b"]); },
defaultLength = 0.5f,
parameters = new()
{
new("b", true, "Should stare?")
}
},
new GameAction("time", "Time of Day")
{
function = delegate { DoubleDate.instance.SetTime(eventCaller.currentEntity["d"]); },
defaultLength = 0.5f,
parameters = new()
{
new("d", DoubleDate.DayTime.Noon, "Time")
}
}
},
new List<string>() {"rvl", "normal"},
"rvldate", "en",
@ -67,8 +110,21 @@ namespace HeavenStudio.Games
[SerializeField] DoubleDateWeasels weasels;
[SerializeField] Animator treeAnim;
[SerializeField] GameObject clouds;
[SerializeField] private GameObject girlObj;
[SerializeField] private GameObject girlWeaselObj;
[SerializeField] private GameObject girlWeaselShockObj;
[SerializeField] private Material doubleDateCellAnim;
[SerializeField] private SpriteRenderer bgSquare;
[SerializeField] private SpriteRenderer bgGradient;
[SerializeField] private Sprite bgIntro;
[SerializeField] private Sprite bgLong;
private Color squareColor;
[Header("Variables")]
[SerializeField] private Color _skyColor;
[SerializeField] private Color noonColor;
[SerializeField] private float _animSpeed = 1.25f;
[SerializeField] public float cloudSpeed;
[SerializeField] public float cloudDistance;
[SerializeField] public float floorHeight;
@ -92,6 +148,7 @@ namespace HeavenStudio.Games
{
public double beat;
public BallType type;
public bool jump;
}
public static PlayerInput.InputAction InputAction_TouchPress =
@ -114,9 +171,67 @@ namespace HeavenStudio.Games
}
}
public void CheckGirlsPresence(double beat)
{
var allEvents = EventCaller.GetAllInGameManagerList("doubleDate", new string[] { "toggleGirls" }).FindAll(x => x.beat < beat);
if (allEvents.Count == 0) return;
allEvents.Sort((x, y) => x.beat.CompareTo(y.beat));
ToggleGirls(allEvents[^1]["b"]);
}
public void CheckBoyStare(double beat)
{
var allEvents = EventCaller.GetAllInGameManagerList("doubleDate", new string[] { "stare" }).FindAll(x => x.beat < beat);
if (allEvents.Count == 0) return;
allEvents.Sort((x, y) => x.beat.CompareTo(y.beat));
ToggleStare(allEvents[^1]["b"]);
}
public enum DayTime
{
Day,
Noon
}
private void DayTimeCheck(double beat)
{
var allEvents = EventCaller.GetAllInGameManagerList("doubleDate", new string[] { "time" }).FindAll(x => x.beat < beat);
if (allEvents.Count == 0) return;
allEvents.Sort((x, y) => x.beat.CompareTo(y.beat));
SetTime(allEvents[^1]["d"]);
}
public void SetTime(int time)
{
if (time == (int)DayTime.Noon)
{
doubleDateCellAnim.SetColor("_Color", noonColor);
bgSquare.color = squareColor;
bgGradient.sprite = bgLong;
return;
}
doubleDateCellAnim.SetColor("_Color", Color.white);
bgSquare.color = _skyColor;
bgGradient.sprite = bgIntro;
}
public override void OnPlay(double beat)
{
queuedBalls.Clear();
CheckGirlsPresence(beat);
CheckBoyStare(beat);
DayTimeCheck(beat);
}
public override void OnGameSwitch(double beat)
{
CheckGirlsPresence(beat);
CheckBoyStare(beat);
DayTimeCheck(beat);
}
private void OnDestroy() {
@ -131,6 +246,8 @@ namespace HeavenStudio.Games
{
instance = this;
SetupBopRegion("doubleDate", "bop", "autoBop");
doubleDateCellAnim.SetColor("_Color", noonColor);
squareColor = bgSquare.color;
}
private void Start() {
@ -154,13 +271,13 @@ namespace HeavenStudio.Games
switch (ball.type)
{
case BallType.Soccer:
SpawnSoccerBall(ball.beat);
SpawnSoccerBall(ball.beat, ball.jump);
break;
case BallType.Basket:
SpawnBasketBall(ball.beat);
SpawnBasketBall(ball.beat, ball.jump);
break;
case BallType.Football:
SpawnFootBall(ball.beat);
SpawnFootBall(ball.beat, ball.jump);
break;
}
}
@ -176,11 +293,11 @@ namespace HeavenStudio.Games
}
if (PlayerInput.GetIsAction(InputAction_TouchPress))
{
boyAnim.DoScaledAnimationAsync("Ready", 1f);
boyAnim.DoScaledAnimationAsync("Ready", _animSpeed);
}
if (PlayerInput.GetIsAction(InputAction_TouchRelease) && !IsExpectingInputNow(InputAction_FlickPress))
{
boyAnim.DoScaledAnimationAsync("UnReady", 1f);
boyAnim.DoScaledAnimationAsync("UnReady", _animSpeed);
}
if (PlayerInput.GetIsAction(InputAction_FlickPress) && !IsExpectingInputNow(InputAction_FlickPress))
{
@ -190,6 +307,26 @@ namespace HeavenStudio.Games
clouds.transform.position = Vector3.left * ((Time.realtimeSinceStartup * cloudSpeed) % cloudDistance);
}
public void GirlBlush()
{
girlAnim.DoScaledAnimationAsync("GirlBlush", _animSpeed);
}
public void ToggleGirls(bool active)
{
girlObj.SetActive(active);
girlWeaselObj.SetActive(active);
girlWeaselShockObj.SetActive(active);
}
private bool _isStaring = false;
public void ToggleStare(bool active)
{
boyAnim.SetBool("Stare", active);
_isStaring = active;
}
public void ToggleBop(bool go)
{
canBop = go;
@ -213,10 +350,10 @@ namespace HeavenStudio.Games
{
if (canBop)
{
boyAnim.DoScaledAnimationAsync("IdleBop", 1f);
boyAnim.DoScaledAnimationAsync(_isStaring ? "IdleBop2" : "IdleBop", _animSpeed);
}
if (Conductor.instance.songPositionInBeatsAsDouble > lastGirlGacha)
girlAnim.DoScaledAnimationAsync("GirlBop", 1f);
girlAnim.DoScaledAnimationAsync("GirlBop", _animSpeed);
weasels.Bop();
}
@ -224,12 +361,12 @@ namespace HeavenStudio.Games
{
if (hit)
{
boyAnim.DoScaledAnimationAsync("Kick", 0.5f);
boyAnim.DoScaledAnimationAsync("Kick", _animSpeed);
if (jump)
{
weasels.Jump();
lastGirlGacha = Conductor.instance.songPositionInBeatsAsDouble + 0.5f;
girlAnim.DoScaledAnimationAsync("GirlLookUp", 0.5f);
girlAnim.DoScaledAnimationAsync("GirlLookUp", _animSpeed);
}
else if (weaselsHappy) weasels.Happy();
if (!forceNoLeaves)
@ -239,48 +376,50 @@ namespace HeavenStudio.Games
new BeatAction.Action(Conductor.instance.songPositionInBeatsAsDouble + 1f, delegate
{
leaves.Play();
treeAnim.DoScaledAnimationAsync("TreeRustle", 1f);
treeAnim.DoScaledAnimationAsync("TreeRustle", _animSpeed);
})
});
}
}
else
{
boyAnim.DoScaledAnimationAsync("Barely", 0.5f);
boyAnim.DoScaledAnimationAsync("Barely", _animSpeed);
weasels.Surprise();
}
}
public static void QueueSoccerBall(double beat)
public static void QueueSoccerBall(double beat, bool shouldJump)
{
if (GameManager.instance.currentGame != "doubleDate")
{
queuedBalls.Add(new QueuedBall()
{
beat = beat,
type = BallType.Soccer
type = BallType.Soccer,
jump = shouldJump
});
}
else
{
instance.SpawnSoccerBall(beat);
instance.SpawnSoccerBall(beat, shouldJump);
}
SoundByte.PlayOneShotGame("doubleDate/soccerBounce", beat, forcePlay: true);
}
public static void QueueBasketBall(double beat)
public static void QueueBasketBall(double beat, bool shouldJump)
{
if (GameManager.instance.currentGame != "doubleDate")
{
queuedBalls.Add(new QueuedBall()
{
beat = beat,
type = BallType.Basket
type = BallType.Basket,
jump = shouldJump
});
}
else
{
instance.SpawnBasketBall(beat);
instance.SpawnBasketBall(beat, shouldJump);
}
MultiSound.Play(new MultiSound.Sound[]
{
@ -289,19 +428,20 @@ namespace HeavenStudio.Games
}, forcePlay: true);
}
public static void QueueFootBall(double beat)
public static void QueueFootBall(double beat, bool shouldJump)
{
if (GameManager.instance.currentGame != "doubleDate")
{
queuedBalls.Add(new QueuedBall()
{
beat = beat,
type = BallType.Football
type = BallType.Football,
jump = shouldJump
});
}
else
{
instance.SpawnFootBall(beat);
instance.SpawnFootBall(beat, shouldJump);
}
MultiSound.Play(new MultiSound.Sound[]
{
@ -310,28 +450,28 @@ namespace HeavenStudio.Games
}, forcePlay: true);
}
public void SpawnSoccerBall(double beat)
public void SpawnSoccerBall(double beat, bool shouldJump)
{
SoccerBall spawnedBall = Instantiate(soccer, instance.transform).GetComponent<SoccerBall>();
spawnedBall.Init(beat);
spawnedBall.Init(beat, shouldJump);
}
public void SpawnBasketBall(double beat)
public void SpawnBasketBall(double beat, bool shouldJump)
{
Basketball spawnedBall = Instantiate(basket, instance.transform).GetComponent<Basketball>();
spawnedBall.Init(beat);
spawnedBall.Init(beat, shouldJump);
}
public void SpawnFootBall(double beat)
public void SpawnFootBall(double beat, bool shouldJump)
{
Football spawnedBall = Instantiate(football, instance.transform).GetComponent<Football>();
spawnedBall.Init(beat);
spawnedBall.Init(beat, shouldJump);
}
public void MissKick(double beat, bool hit = false)
{
lastGirlGacha = Conductor.instance.songPositionInBeatsAsDouble + 1.5f;
girlAnim.DoScaledAnimationAsync("GirlSad", 0.5f);
girlAnim.DoScaledAnimationAsync("GirlSad", _animSpeed);
if (hit)
{
lastHitWeasel = Conductor.instance.songPositionInBeatsAsDouble;

View File

@ -15,6 +15,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
private double pathStartBeat = double.MinValue;
private Conductor conductor;
private GameObject shadow;
private bool _jump;
void Awake()
{
@ -37,8 +38,9 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
shadow.transform.localScale = Vector3.one * Mathf.Clamp(((transform.position.y) - game.shadowDepthScaleMin) / (game.shadowDepthScaleMax - game.shadowDepthScaleMin), 0f, 1f);
}
public void Init(double beat)
public void Init(double beat, bool shouldJump)
{
_jump = shouldJump;
game.ScheduleInput(beat, 1.5f, DoubleDate.InputAction_FlickPress, Just, Miss, Empty);
path = game.GetPath("FootBallInNoHit"); // there's a second path for footballs that hit the weasels, use that if the weasels haven't been hit recently
UpdateLastRealPos();
@ -96,7 +98,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
UpdateLastRealPos();
pathStartBeat = conductor.songPositionInBeatsAsDouble;
path = game.GetPath("FootBallJust");
game.Kick(true, true, jump: true);
game.Kick(true, true, jump: _jump);
SoundByte.PlayOneShotGame("doubleDate/footballKick");
}

View File

@ -15,6 +15,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
private double pathStartBeat = double.MinValue;
private Conductor conductor;
private GameObject shadow;
private bool _jump;
void Awake()
{
@ -37,8 +38,9 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
shadow.transform.localScale = Vector3.one * Mathf.Clamp(((transform.position.y) - game.shadowDepthScaleMin) / (game.shadowDepthScaleMax - game.shadowDepthScaleMin), 0f, 1f);
}
public void Init(double beat)
public void Init(double beat, bool shouldJump)
{
_jump = shouldJump;
game.ScheduleInput(beat, 1f, DoubleDate.InputAction_FlickPress, Just, Miss, Empty);
path = game.GetPath("SoccerIn");
UpdateLastRealPos();
@ -80,7 +82,7 @@ namespace HeavenStudio.Games.Scripts_DoubleDate
UpdateLastRealPos();
pathStartBeat = conductor.songPositionInBeatsAsDouble;
path = game.GetPath("SoccerJust");
game.Kick();
game.Kick(true, false, true, _jump);
SoundByte.PlayOneShotGame("doubleDate/kick");
}

View File

@ -260,7 +260,7 @@ namespace HeavenStudio.Games.Loaders
new Param("fxType", KarateMan.BackgroundFXType.None, "FX Type", "The background effect to be displayed"),
new Param("type", KarateMan.NoriMode.None, "Flow Bar type", "The type of Flow bar to use", new List<Param.CollapseParam>()
{
new Param.CollapseParam((x, _) => (int)x != (int)KarateMan.NoriMode.None, new string[] { "startColor" })
new Param.CollapseParam((x, _) => (int)x != (int)KarateMan.NoriMode.None, new string[] { "type" })
}),
new Param("hitsPerHeart", new EntityTypes.Float(0f, 20f, 0f), "Hits Per Heart", "How many hits will it take for each heart to light up? (0 will do it automatically.)"),
new Param("toggle", true, "Enable Combos", "Allow the player to combo? (Contextual combos will still be allowed even when off)"),
@ -340,7 +340,7 @@ namespace HeavenStudio.Games.Loaders
{
function = delegate {
var e = eventCaller.currentEntity;
KarateMan.instance.UpdateMaterialColour(e["colorA"], e["colorB"], e["colorC"]);
KarateMan.instance.UpdateMaterialColour(e["colorA"], e["colorB"], e["colorC"], e["colorD"], e["star"]);
},
defaultLength = 0.5f,
parameters = new List<Param>()
@ -348,6 +348,11 @@ namespace HeavenStudio.Games.Loaders
new Param("colorA", new Color(1,1,1,1), "Joe Body Color", "The color to use for Karate Joe's body"),
new Param("colorB", new Color(0.81f,0.81f,0.81f,1), "Joe Highlight Color", "The color to use for Karate Joe's highlights"),
new Param("colorC", new Color(1,1,1,1), "Item Color", "The color to use for the thrown items"),
new Param("star", KarateMan.StarColorOption.ItemColor, "Star Color Options", "", new()
{
new((x, _) => (int)x == (int)KarateMan.StarColorOption.Custom, new string[] { "colorD" })
}),
new Param("colorD", new Color(1,1,1,1), "Star Color", "The color to use for star particles"),
},
},
new GameAction("particle effects", "Particle Effects")
@ -480,7 +485,7 @@ namespace HeavenStudio.Games
Gradient,
Radial,
Blood,
//ManMan?
SeniorGradient
}
public enum ShadowType
@ -555,6 +560,8 @@ namespace HeavenStudio.Games
public Color BodyColor = Color.white;
public Color HighlightColor = new Color(0.81f, 0.81f, 0.81f);
public Color ItemColor = Color.white;
[NonSerialized] public bool useItemColorForStar = true;
public Color StarColor = Color.white;
[Header("Word")]
public Animator Word;
@ -765,9 +772,9 @@ namespace HeavenStudio.Games
}
if (obj != null) {
UpdateMaterialColour(obj["colorA"], obj["colorB"], obj["colorC"]);
UpdateMaterialColour(obj["colorA"], obj["colorB"], obj["colorC"], obj["colorD"], obj["star"]);
} else {
UpdateMaterialColour(Color.white, new Color(0.81f, 0.81f, 0.81f), Color.white);
UpdateMaterialColour(Color.white, new Color(0.81f, 0.81f, 0.81f), Color.white, Color.white, (int)StarColorOption.ItemColor);
}
// init modifier(s)
@ -1139,11 +1146,19 @@ namespace HeavenStudio.Games
IsComboEnable = combo;
}
public void UpdateMaterialColour(Color mainCol, Color highlightCol, Color objectCol)
public enum StarColorOption
{
ItemColor,
Custom
}
public void UpdateMaterialColour(Color mainCol, Color highlightCol, Color objectCol, Color starCol, int starColOption)
{
BodyColor = mainCol;
HighlightColor = highlightCol;
ItemColor = objectCol;
StarColor = starCol;
useItemColorForStar = starColOption == 0;
}
public void SetParticleEffect(double beat, int type, bool instant, float windStrength, float particleStrength)

View File

@ -141,7 +141,7 @@ namespace HeavenStudio.Games.Scripts_KarateMan
{
if (!KarateMan.instance.IsExpectingInputNow(KarateMan.InputAction_Press))
{
Punch(1, PlayerInput.CurrentControlStyle == InputController.ControlStyles.Touch);
Punch(_lastPunchedHeavy ? 2 : 1, PlayerInput.CurrentControlStyle == InputController.ControlStyles.Touch, _lastPunchedHeavy);
SoundByte.PlayOneShotGame("karateman/swingNoHit", forcePlay: true);
}
}
@ -215,7 +215,9 @@ namespace HeavenStudio.Games.Scripts_KarateMan
lastChargeTime = double.MinValue;
}
public bool Punch(int forceHand = 0, bool touchCharge = false)
private bool _lastPunchedHeavy = false;
public bool Punch(int forceHand = 0, bool touchCharge = false, bool punchedHeavy = false)
{
if (GameManager.instance.currentGame != "karateman") return false;
var cond = Conductor.instance;
@ -225,6 +227,7 @@ namespace HeavenStudio.Games.Scripts_KarateMan
unPrepareTime = double.MinValue;
lastChargeTime = double.MinValue;
inKick = false;
_lastPunchedHeavy = punchedHeavy;
switch (forceHand)
{

View File

@ -617,6 +617,9 @@ namespace HeavenStudio.Games.Scripts_KarateMan
else
SoundByte.PlayOneShotGame("karateman/potHit", forcePlay: true);
p = Instantiate(HitParticles[3], HitPosition[1].position, Quaternion.identity, game.ItemHolder);
var main = p.main;
if (game.useItemColorForStar) main.startColor = new(game.ItemColor);
else main.startColor = new(game.StarColor);
p.Play();
break;
@ -757,7 +760,7 @@ namespace HeavenStudio.Games.Scripts_KarateMan
var joe = KarateMan.instance.Joe;
if (state <= -1f || state >= 1f)
{
bool straight = joe.Punch(ItemPunchHand());
bool straight = joe.Punch(ItemPunchHand(), false, ItemPunchHand() == 2);
startBeat = Conductor.instance.songPositionInBeatsAsDouble;
CurrentCurve = ItemCurves[6];
curveTargetBeat = 1f;
@ -790,7 +793,7 @@ namespace HeavenStudio.Games.Scripts_KarateMan
return;
}
}
bool straight = joe.Punch(ItemPunchHand());
bool straight = joe.Punch(ItemPunchHand(), false, ItemPunchHand() == 2);
DoHitExpression(startBeat + 1f);
ItemHitEffect(straight);
status = FlyStatus.Hit;

View File

@ -457,7 +457,7 @@ namespace HeavenStudio.Games
On = 1,
}
private Dictionary<double, int> bopRegion = new();
protected Dictionary<double, int> bopRegion = new();
public bool BeatIsInBopRegion(double beat)
{
@ -488,10 +488,16 @@ namespace HeavenStudio.Games
protected void SetupBopRegion(string gameName, string eventName, string toggleName, bool isBool = true)
{
var allEvents = EventCaller.GetAllInGameManagerList(gameName, new string[] { eventName });
if (allEvents.Count == 0) return;
allEvents.Sort((x, y) => x.beat.CompareTo(y.beat));
foreach (var e in allEvents)
{
if (bopRegion.ContainsKey(e.beat))
{
Debug.Log("Two bops on the same beat, ignoring this one");
continue;
}
if (isBool)
{
bopRegion.Add(e.beat, e[toggleName] ? 1 : 0);

View File

@ -104,6 +104,7 @@ namespace HeavenStudio.Games
[Header("Components")]
[SerializeField] Animator wrestlerAnim;
[SerializeField] Animator reporterAnim;
[SerializeField] Animator reporterHeadAnim;
[SerializeField] Animator audienceAnim;
[SerializeField] Animator wrestlerNewspaperAnim;
[SerializeField] Animator reporterNewspaperAnim;
@ -233,6 +234,11 @@ namespace HeavenStudio.Games
}
}
private bool canDoMissExpression()
{
return (reporterHeadAnim.IsPlayingAnimationNames(new string[] { "BlinkHead", "ExtendBlink", "ExcitedBlink", "Idle", "ExtendIdle", "Excited", "Miss", "Late" }) || reporterHeadAnim.IsAnimationNotPlaying()) && !reporterHeadAnim.GetCurrentAnimatorStateInfo(0).IsName("Flinch");
}
void Update()
{
var cond = Conductor.instance;
@ -248,7 +254,7 @@ namespace HeavenStudio.Games
wrestlerAnim.DoScaledAnimationAsync("YeMiss", 0.25f);
SoundByte.PlayOneShotGame($"ringside/confusedanswer");
if (reporterAnim.IsPlayingAnimationNames("IdleReporter")) reporterAnim.Play("IdleLate", 0, 0);
if (canDoMissExpression()) reporterHeadAnim.DoScaledAnimationAsync("Miss", 0.5f);
}
}
if ( PlayerInput.CurrentControlStyle == InputController.ControlStyles.Touch
@ -258,7 +264,8 @@ namespace HeavenStudio.Games
SoundByte.PlayOneShotGame($"ringside/muscles2");
wrestlerAnim.DoScaledAnimationAsync("BigGuyTwo", 0.5f);
reporterAnim.Play("FlinchReporter", 0, 0);
if (canDoMissExpression()) reporterAnim.Play("FlinchReporter", 0, 0);
if (canDoMissExpression()) reporterHeadAnim.Play("Flinch", 0, 0);
SoundByte.PlayOneShotGame("ringside/barely");
}
if (PlayerInput.GetIsAction(InputAction_Alt) && !IsExpectingInputNow(InputAction_Alt) && !shouldNotInput)
@ -267,7 +274,8 @@ namespace HeavenStudio.Games
int randomPose = UnityEngine.Random.Range(1, 7);
wrestlerAnim.Play($"Pose{randomPose}", 0, 0);
reporterAnim.Play("FlinchReporter", 0, 0);
if (canDoMissExpression()) reporterAnim.Play("FlinchReporter", 0, 0);
if (canDoMissExpression()) reporterHeadAnim.Play("Flinch", 0, 0);
SoundByte.PlayOneShotGame($"ringside/yell{UnityEngine.Random.Range(1, 7)}Raw");
wrestlerTransform.localScale = new Vector3(1.1f, 1.1f, 1f);
BeatAction.New(instance, new List<BeatAction.Action>()
@ -374,6 +382,7 @@ namespace HeavenStudio.Games
int currentQuestion = questionVariant;
if (currentQuestion == (int)QuestionVariant.Random) currentQuestion = UnityEngine.Random.Range(1, 4);
reporterAnim.DoScaledAnimationAsync("WubbaLubbaDubbaThatTrue", 0.4f);
reporterHeadAnim.DoScaledAnimationAsync("Wubba", 0.4f);
List<MultiSound.Sound> qSounds = new List<MultiSound.Sound>();
if (alt)
{
@ -412,7 +421,7 @@ namespace HeavenStudio.Games
if (currentQuestion == (int)QuestionVariant.Random) currentQuestion = UnityEngine.Random.Range(1, 4);
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(beat - 0.5f, delegate { reporterAnim.DoScaledAnimationAsync("WubbaLubbaDubbaThatTrue", 0.4f); }),
new BeatAction.Action(beat - 0.5f, delegate { reporterAnim.DoScaledAnimationAsync("WubbaLubbaDubbaThatTrue", 0.4f); reporterHeadAnim.DoScaledAnimationAsync("Wubba", 0.4f); }),
});
ThatTrue(beat - 1, currentQuestion);
}
@ -428,7 +437,7 @@ namespace HeavenStudio.Games
ScheduleInput(beat, 2f, InputAction_BasicPress, JustQuestion, Miss, Nothing);
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(beat + 0.5f, delegate { reporterAnim.DoScaledAnimationAsync("ThatTrue", 0.5f); }),
new BeatAction.Action(beat + 0.5f, delegate { reporterAnim.DoScaledAnimationAsync("ThatTrue", 0.5f); reporterHeadAnim.DoScaledAnimationAsync("IsThat", 0.5f); }),
new BeatAction.Action(beat + 1.5f, delegate { canBop = false; }),
new BeatAction.Action(beat + 2.5f, delegate { canBop = true; })
});
@ -439,6 +448,7 @@ namespace HeavenStudio.Games
int currentQuestion = questionVariant;
if (currentQuestion == (int)QuestionVariant.Random) currentQuestion = UnityEngine.Random.Range(1, 4);
reporterAnim.DoScaledAnimationAsync("Woah", 0.5f);
reporterHeadAnim.DoScaledAnimationAsync("Woah", 0.5f);
float youBeat = 0.65f;
if (currentQuestion == (int)QuestionVariant.Third) youBeat = 0.7f;
MultiSound.Play(new MultiSound.Sound[]
@ -454,7 +464,7 @@ namespace HeavenStudio.Games
ScheduleInput(beat, 3f, InputAction_FlickPress, JustBigGuySecond, MissBigGuyTwo, Nothing);
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(beat + 2f, delegate { reporterAnim.Play("True", 0, 0); }),
new BeatAction.Action(beat + 2f, delegate { reporterAnim.Play("True", 0, 0); reporterHeadAnim.Play("Extend", 0, 0); }),
new BeatAction.Action(beat + 2.25f, delegate { canBop = false; }),
new BeatAction.Action(beat + 3.5f, delegate { canBop = true; })
});
@ -521,9 +531,10 @@ namespace HeavenStudio.Games
}
}
else wrestlerAnim.Play("Idle", 0, 1);
reporterAnim.DoUnscaledAnimation("IdleReporter");
shouldNotInput = false;
canBop = true;
reporterAnim.Play("IdleReporter", 0, 0);
if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0);
}),
});
if (!keepZoomedOut)
@ -702,9 +713,17 @@ namespace HeavenStudio.Games
public void ReporterBlink()
{
if (reporterAnim.GetCurrentAnimatorStateInfo(0).IsName("IdleReporter"))
if (reporterHeadAnim.GetCurrentAnimatorStateInfo(0).IsName("Idle"))
{
reporterAnim.DoUnscaledAnimation("BlinkReporter");
reporterHeadAnim.DoScaledAnimationAsync("BlinkHead", 0.5f);
}
else if (reporterHeadAnim.GetCurrentAnimatorStateInfo(0).IsName("ExtendIdle"))
{
reporterHeadAnim.DoScaledAnimationAsync("ExtendBlink", 0.5f);
}
else if (reporterHeadAnim.GetCurrentAnimatorStateInfo(0).IsName("Excited"))
{
reporterHeadAnim.DoScaledAnimationAsync("ExcitedBlink", 0.5f);
}
float randomTime = UnityEngine.Random.Range(0.3f, 1.8f);
Invoke("ReporterBlink", randomTime);
@ -716,12 +735,11 @@ namespace HeavenStudio.Games
{
wrestlerAnim.DoScaledAnimationAsync("Cough", 0.5f);
SoundByte.PlayOneShotGame($"ringside/cough");
reporterAnim.Play("ExtendMiss", 0, 0);
reporterHeadAnim.DoScaledAnimationAsync("Late", 0.5f);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleMiss", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0); }),
});
return;
}
@ -731,16 +749,20 @@ namespace HeavenStudio.Games
public void SuccessQuestion(PlayerActionEvent caller)
{
wrestlerAnim.DoScaledAnimationAsync("Ye", 0.5f);
reporterAnim.Play("ExtendSmile", 0, 0);
reporterHeadAnim.Play("ExtendSmile", 0, 0);
SoundByte.PlayOneShotGame($"ringside/ye{UnityEngine.Random.Range(1, 4)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { SoundByte.PlayOneShotGame("ringside/yeCamera"); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { FadeFlashColor(Color.white, new Color(1, 1, 1, 0), 0.5f); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { flashObject.SetActive(true); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("SmileReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate
{
SoundByte.PlayOneShotGame("ringside/yeCamera");
FadeFlashColor(Color.white, new Color(1, 1, 1, 0), 0.5f);
flashObject.SetActive(true);
reporterAnim.Play("IdleReporter", 0, 0);
reporterHeadAnim.Play("Smile", 0, 0);
}),
new BeatAction.Action(caller.startBeat + caller.timer + 0.6f, delegate { flashObject.SetActive(false); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0); }),
});
}
@ -778,12 +800,12 @@ namespace HeavenStudio.Games
}
else
{
reporterAnim.Play("ExtendMiss", 0, 0);
reporterHeadAnim.Play("Late", 0, 0);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleMiss", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0); }),
});
}
return;
@ -797,24 +819,28 @@ namespace HeavenStudio.Games
wrestlerAnim.DoScaledAnimationAsync("BigGuyTwo", 0.5f);
if (!missedBigGuy)
{
reporterAnim.Play("ExtendSmile", 0, 0);
reporterHeadAnim.Play("ExtendSmile", 0, 0);
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { SoundByte.PlayOneShotGame("ringside/musclesCamera"); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("SmileReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { FadeFlashColor(Color.white, new Color(1, 1, 1, 0), 0.5f); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { flashObject.SetActive(true); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate
{
SoundByte.PlayOneShotGame("ringside/musclesCamera");
reporterAnim.Play("IdleReporter", 0, 0);
reporterHeadAnim.Play("Smile", 0, 0);
FadeFlashColor(Color.white, new Color(1, 1, 1, 0), 0.5f);
flashObject.SetActive(true);
}),
new BeatAction.Action(caller.startBeat + caller.timer + 0.6f, delegate { flashObject.SetActive(false); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0); }),
});
}
else
{
reporterAnim.Play("ExtendMiss", 0, 0);
reporterHeadAnim.Play("Miss", 0, 0);
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleMiss", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { if (reporterHeadAnim.IsAnimationNotPlaying()) reporterHeadAnim.Play("Idle", 0, 0); }),
});
}
}
@ -828,7 +854,7 @@ namespace HeavenStudio.Games
int randomPose = UnityEngine.Random.Range(1, 7);
wrestlerAnim.Play($"Pose{randomPose}", 0, 0);
SoundByte.PlayOneShotGame($"ringside/yell{UnityEngine.Random.Range(1, 7)}Raw");
reporterAnim.Play("IdleMiss", 0, 0);
reporterHeadAnim.Play("Late", 0, 0);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
@ -848,10 +874,12 @@ namespace HeavenStudio.Games
if (reporterShouldHeart)
{
reporterAnim.Play("HeartReporter", 0, 0);
reporterHeadAnim.Play("Heart", 0, 0);
}
else
{
reporterAnim.Play("ExcitedReporter", 0, 0);
reporterHeadAnim.Play("Excited", 0, 0);
}
hitPose = true;
SoundByte.PlayOneShotGame($"ringside/yell{UnityEngine.Random.Range(1, 7)}");
@ -870,12 +898,12 @@ namespace HeavenStudio.Games
public void Miss(PlayerActionEvent caller)
{
reporterAnim.Play("ExtendMiss", 0, 0);
reporterHeadAnim.Play("Late", 0, 0);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleMiss", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterHeadAnim.Play("Idle", 0, 0); }),
});
}
@ -886,12 +914,12 @@ namespace HeavenStudio.Games
public void MissBigGuyTwo(PlayerActionEvent caller)
{
reporterAnim.Play("ExtendMiss", 0, 0);
reporterHeadAnim.Play("Late", 0, 0);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
BeatAction.New(instance, new List<BeatAction.Action>()
{
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleMiss", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.5f, delegate { reporterAnim.Play("IdleReporter", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { reporterHeadAnim.Play("Idle", 0, 0); }),
new BeatAction.Action(caller.startBeat + caller.timer + 0.9f, delegate { wrestlerAnim.Play("Idle", 0, 0); }),
});
}
@ -899,7 +927,7 @@ namespace HeavenStudio.Games
public void MissPose(PlayerActionEvent caller)
{
shouldNotInput = true;
reporterAnim.Play("IdleMiss", 0, 0);
reporterHeadAnim.Play("Late", 0, 0);
SoundByte.PlayOneShotGame($"ringside/huhaudience{UnityEngine.Random.Range(0, 2)}");
}

View File

@ -157,6 +157,7 @@ namespace HeavenStudio.Games.Scripts_SeeSaw
if (!hasChangedAnimMidAir) anim.Play("Jump_InOut_Tuck", 0, 0);
hasChangedAnimMidAir = true;
}
transform.position = GetPathPositionFromBeat(currentPath, Math.Max(startBeat, currentBeat), startBeat);
break;
case JumpState.HighInIn:
if (currentBeat >= startBeat + 1 && !hasChangedAnimMidAir && see)