This commit is contained in:
AstrlJelly 2024-03-05 13:04:14 -05:00 committed by GitHub
parent dd0063aadb
commit 9b59d06b55
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
4 changed files with 13 additions and 17 deletions

View file

@ -178,8 +178,8 @@ namespace HeavenStudio.Games
fo.SetActive(true); fo.SetActive(true);
} }
private ColorEase bgColorEase = new(); private ColorEase bgColorEase = new(Color.white);
private ColorEase gradColorEase = new(); private ColorEase gradColorEase = new(Color.white);
//call this in update //call this in update
private void BackgroundColorUpdate() private void BackgroundColorUpdate()

View file

@ -13,9 +13,9 @@ namespace HeavenStudio.Games.Loaders
public static Minigame AddGame(EventCaller eventCaller) { public static Minigame AddGame(EventCaller eventCaller) {
RiqEntity BackgroundUpdater(string datamodel, RiqEntity e) RiqEntity BackgroundUpdater(string datamodel, RiqEntity e)
{ {
if (datamodel == "mrUpbeat/changeBG" && e.dynamicData.ContainsKey("toggle")) if (datamodel == "mrUpbeat/changeBG" && e.dynamicData.ContainsKey("toggle") && !e.dynamicData.ContainsKey("ease"))
{ {
e.dynamicData.Add("ease", (int)(e["toggle"] ? Util.EasingFunction.Ease.Instant : Util.EasingFunction.Ease.Linear)); e.CreateProperty("ease", (int)(e["toggle"] ? Util.EasingFunction.Ease.Instant : Util.EasingFunction.Ease.Linear));
e.dynamicData.Remove("toggle"); e.dynamicData.Remove("toggle");
return e; return e;
} }

View file

@ -457,7 +457,7 @@ namespace HeavenStudio.Games
{ {
canBop = false; canBop = false;
if (grampsTurns) grampsCanBop = false; if (grampsTurns) grampsCanBop = false;
ScheduleInput(beat, 1f, InputAction_Turn, JustRight, RightMiss, Empty); ScheduleInput(beat, 1f, InputAction_Turn, JustRight, RightMiss, null);
BeatAction.New(instance, new List<BeatAction.Action>() BeatAction.New(instance, new List<BeatAction.Action>()
{ {
@ -526,7 +526,7 @@ namespace HeavenStudio.Games
{ {
canBop = false; canBop = false;
if (grampsSits) grampsCanBop = false; if (grampsSits) grampsCanBop = false;
ScheduleInput(beat, 1f, InputAction_Down, JustSit, SitMiss, Empty); ScheduleInput(beat, 1f, InputAction_Down, JustSit, SitMiss, null);
BeatAction.New(instance, new List<BeatAction.Action>() BeatAction.New(instance, new List<BeatAction.Action>()
{ {
@ -601,7 +601,7 @@ namespace HeavenStudio.Games
{ {
canBop = false; canBop = false;
if (grampsPunches) grampsCanBop = false; if (grampsPunches) grampsCanBop = false;
ScheduleInput(beat, 1.5f, InputAction_Punch, JustPunch, PunchMiss, Empty); ScheduleInput(beat, 1.5f, InputAction_Punch, JustPunch, PunchMiss, null);
BeatAction.New(instance, new List<BeatAction.Action>() BeatAction.New(instance, new List<BeatAction.Action>()
{ {
@ -680,7 +680,7 @@ namespace HeavenStudio.Games
Gramps.DoScaledAnimationAsync("GrampsBop", 0.5f); Gramps.DoScaledAnimationAsync("GrampsBop", 0.5f);
} }
private ColorEase bgColorEase = new(); private ColorEase bgColorEase = new(defaultBGColor);
public void BackgroundColor(double beat, float length, Color startColor, Color endColor, int ease) public void BackgroundColor(double beat, float length, Color startColor, Color endColor, int ease)
{ {
@ -722,10 +722,10 @@ namespace HeavenStudio.Games
} }
public void RightSuccess() public void RightSuccess()
{ {
SoundByte.PlayOneShotGame("spaceDance/inputGood"); SoundByte.PlayOneShotGame("spaceDance/inputGood");
DancerP.DoScaledAnimationAsync("TurnRightDo", 0.5f); DancerP.DoScaledAnimationAsync("TurnRightDo", 0.5f);
} }
public void RightMiss(PlayerActionEvent caller) public void RightMiss(PlayerActionEvent caller)
{ {
@ -774,10 +774,10 @@ namespace HeavenStudio.Games
} }
public void PunchSuccess() public void PunchSuccess()
{ {
SoundByte.PlayOneShotGame("spaceDance/inputGood"); SoundByte.PlayOneShotGame("spaceDance/inputGood");
DancerP.DoScaledAnimationAsync("PunchDo", 0.5f); DancerP.DoScaledAnimationAsync("PunchDo", 0.5f);
} }
public void PunchMiss(PlayerActionEvent caller) public void PunchMiss(PlayerActionEvent caller)
{ {
@ -786,9 +786,5 @@ namespace HeavenStudio.Games
Hit.Play("HitPunch", -1, 0); Hit.Play("HitPunch", -1, 0);
Gramps.DoScaledAnimationAsync("GrampsMiss", 0.5f); Gramps.DoScaledAnimationAsync("GrampsMiss", 0.5f);
} }
public void Empty(PlayerActionEvent caller) { }
} }
} }

View file

@ -465,7 +465,7 @@ namespace HeavenStudio.Games
} }
} }
private ColorEase bgColorEase = new(); private ColorEase bgColorEase = new(defaultBGColor);
//call this in update //call this in update
private void BackgroundColorUpdate() private void BackgroundColorUpdate()