From f0fd6f5edec6a212dec357f1e2c6554724302081 Mon Sep 17 00:00:00 2001 From: minenice55 Date: Fri, 19 Aug 2022 19:46:37 -0400 Subject: [PATCH] make Karate Man init from new entities --- Assets/Scripts/Games/KarateMan/KarateMan.cs | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/Assets/Scripts/Games/KarateMan/KarateMan.cs b/Assets/Scripts/Games/KarateMan/KarateMan.cs index db393812..2e1547e2 100644 --- a/Assets/Scripts/Games/KarateMan/KarateMan.cs +++ b/Assets/Scripts/Games/KarateMan/KarateMan.cs @@ -705,14 +705,15 @@ namespace HeavenStudio.Games if (e.beat > beat) break; SetBgAndShadowCol(e.beat, e.length, e.type, e.type2, e.colorA, e.colorB, e.type3); + SetBgTexture(e.type4, e.type5, e.colorC, e.colorD); } - var bgtex = GameManager.instance.Beatmap.entities.FindAll(en => en.datamodel == "karateman/set background texture"); - for (int i = 0; i < bgtex.Count; i++) + var camfx = GameManager.instance.Beatmap.entities.FindAll(en => en.datamodel == "karateman/special camera"); + for (int i = 0; i < camfx.Count; i++) { - var e = bgtex[i]; + var e = camfx[i]; if (e.beat > beat) break; - SetBgTexture(e.type, e.type2, e.colorA, e.colorB); + DoSpecialCamera(e.beat, e.length, e.toggle); } // has issues when creating a new hitx entity so this is deactivated for now // var hitx = GameManager.instance.Beatmap.entities.FindAll(en => en.datamodel == "karateman/hitX"); @@ -756,7 +757,10 @@ namespace HeavenStudio.Games //😢 if (fx != (int) BackgroundFXType.Fade) + { + bgColourLast = bgColour; oldShadowColour = GetShadowColor(true); + } if (textureFilterType == (int) ShadowType.Tinted) filterColour = Color.LerpUnclamped(bgColour, ShadowBlendColor, 0.45f);