Exemplo n.º 1
0
        public static SimpleColorSO SetupNewLightColourSOs(LightSwitchEventEffect light, String s, Color overrideMultiplierColour)
        {
            MultipliedColorSO mColorSO = light.GetField <MultipliedColorSO>(s);
            SimpleColorSO     baseSO   = mColorSO.GetField <SimpleColorSO>("_baseColor");

            SimpleColorSO newBaseSO = ScriptableObject.CreateInstance <SimpleColorSO>();// new SimpleColorSO();

            newBaseSO.SetColor(baseSO.color);

            MultipliedColorSO newMColorSO = ScriptableObject.CreateInstance <MultipliedColorSO>();

            if (overrideMultiplierColour == Color.clear)
            {
                newMColorSO.SetField("_multiplierColor", mColorSO.GetField <Color>("_multiplierColor"));
            }
            else
            {
                newMColorSO.SetField("_multiplierColor", overrideMultiplierColour);
            }
            newMColorSO.SetField("_baseColor", newBaseSO);

            light.SetField(s, newMColorSO);
            if (!light.name.Contains("chroma"))
            {
                light.name = light.name + "_chroma";
            }
            return(newBaseSO);
        }
Exemplo n.º 2
0
            public static LSEColourManager GetOrCreateLSEColourManager(LightSwitchEventEffect lse, BeatmapEventType type)
            {
                LSEColourManager lsecm;

                try {
                    lsecm = GetLSEColourManager(type);
                } catch (Exception e) {
                    ChromaLogger.Log(e);
                    return(null);
                }
                try {
                    if (lsecm != null)
                    {
                        lsecm.Initialize(lse, type);
                        return(lsecm);
                    }
                    else
                    {
                        lsecm = new LSEColourManager(lse, type);
                        lsecm.Initialize(lse, type);
                        LSEColourManagers.Add(lsecm);
                        return(lsecm);
                    }
                } catch (Exception e) {
                    ChromaLogger.Log(e);
                    return(lsecm);
                }
            }
Exemplo n.º 3
0
 private static void Prefix(LightSwitchEventEffect __instance, BeatmapEventData beatmapEventData, BeatmapEventType ____event)
 {
     if (beatmapEventData.type == ____event)
     {
         __instance.SetLastValue(beatmapEventData.value);
     }
 }
Exemplo n.º 4
0
 // 0 = off
 // 1 = blue on, 5 = red on
 // 2 = blue flash, 6 = red flash
 // 3 = blue fade, 7 = red fade
 private static void Prefix(LightSwitchEventEffect __instance, BeatmapEventData beatmapEventData, BeatmapEventType ____event)
 {
     if (beatmapEventData.type == ____event)
     {
         LightColorManager.ColorLightSwitch(__instance, beatmapEventData);
     }
 }
Exemplo n.º 5
0
        protected override void Init()
        {
            customColorLeft  = colorScheme.environmentColor0;
            customColorRight = colorScheme.environmentColor1;

            defaultBeatEffectDuration = Helper.GetValue <float>(beatEffectSpawner, "_effectDuration");

            customLights    = new LightEffectController[defaultLights.Length];
            lightshowLights = new LightEffectController[defaultLights.Length];

            managerWrapper = new LightWithIdManagerWrapper(lightWithIdManager);

            for (int i = 0; i < defaultLights.Length; i++)
            {
                LightSwitchEventEffect light = defaultLights[i];

                Helper.SetValue <LightWithIdManagerWrapper>(light, "_lightManager", managerWrapper);

                LightEffectController customLight    = LightEffectController.Create(managerWrapper, LightMode.Custom, light, timeSource);
                LightEffectController lightshowLight = LightEffectController.Create(managerWrapper, LightMode.CustomLightshow, light, timeSource);

                bocc.beatmapEventDidTriggerEvent += customLight.OnEvent;
                onLightModeUpdated += customLight.UpdateLightMode;

                CustomBeatmapEventManager.onCustomBeatmapEvent += lightshowLight.OnEvent;
                onLightModeUpdated += lightshowLight.UpdateLightMode;

                customLights[i]    = customLight;
                lightshowLights[i] = lightshowLight;
            }

            enabled = false;
        }
Exemplo n.º 6
0
        internal static IEnumerator Routine(LightSwitchEventEffect lse, BeatmapEventType type, Color colour, float delay)
        {
            BloomPrePassLight[] lights = lse.GetField <BloomPrePassLight[]>("_lights");
            Dictionary <int, List <BloomPrePassLight> > lightWavesByPosition = new Dictionary <int, List <BloomPrePassLight> >();

            for (int i = 0; i < lights.Length; i++)
            {
                List <BloomPrePassLight> wave;
                if (!lightWavesByPosition.TryGetValue(Mathf.FloorToInt(lights[i].transform.position.z), out wave))
                {
                    wave = new List <BloomPrePassLight>();
                    lightWavesByPosition.Add(Mathf.FloorToInt(lights[i].transform.position.z), wave);
                }
                wave.Add(lights[i]);
            }

            ChromaLogger.Log("Found " + lightWavesByPosition.Count + " waves!");

            List <List <BloomPrePassLight> > lightWaves = new List <List <BloomPrePassLight> >();

            foreach (KeyValuePair <int, List <BloomPrePassLight> > kv in lightWavesByPosition)
            {
                lightWaves.Add(kv.Value);
            }

            for (int i = 0; i < lightWaves.Count; i++)
            {
                for (int j = 0; j < lightWaves[i].Count; j++)
                {
                    lightWaves[i][j].color = colour;
                }
                yield return(new WaitForSeconds(delay));
            }
        }
Exemplo n.º 7
0
        private void InitializeSO(string id, int index)
        {
            LightSwitchEventEffect lightSwitchEventEffect = _lightSwitchEventEffect;

            FieldAccessor <LightSwitchEventEffect, ColorSO> .Accessor colorSOAcessor = FieldAccessor <LightSwitchEventEffect, ColorSO> .GetAccessor(id);

            MultipliedColorSO lightMultSO = (MultipliedColorSO)colorSOAcessor(ref lightSwitchEventEffect);

            Color         multiplierColor = _multiplierColorAccessor(ref lightMultSO);
            SimpleColorSO lightSO         = _baseColorAccessor(ref lightMultSO);

            _originalColors[index] = lightSO.color;

            MultipliedColorSO mColorSO = ScriptableObject.CreateInstance <MultipliedColorSO>();

            _multiplierColorAccessor(ref mColorSO) = multiplierColor;

            SimpleColorSO sColorSO;

            if (_simpleColorSOs[index] == null)
            {
                sColorSO = ScriptableObject.CreateInstance <SimpleColorSO>();
                sColorSO.SetColor(lightSO.color);
                _simpleColorSOs[index] = sColorSO;
            }
            else
            {
                sColorSO = _simpleColorSOs[index];
            }

            _baseColorAccessor(ref mColorSO) = sColorSO;

            colorSOAcessor(ref lightSwitchEventEffect) = mColorSO;
        }
Exemplo n.º 8
0
        // 0 = off
        // 1 = blue on, 5 = red on
        // 2 = blue flash, 6 = red flash
        // 3 = blue fade, 7 = red fade
#pragma warning disable SA1313 // Parameter names should begin with lower-case letter
        private static void Prefix(LightSwitchEventEffect __instance, BeatmapEventData beatmapEventData, BeatmapEventType ____event)
#pragma warning restore SA1313 // Parameter names should begin with lower-case letter
        {
            if (beatmapEventData.type == ____event)
            {
                LightColorManager.ColorLightSwitch(__instance, beatmapEventData);
            }
        }
Exemplo n.º 9
0
 public override void Activate(BeatmapEventData baseData, LightSwitchEventEffect lse, BeatmapEventType type)
 {
     BSLight[] lights = lse.GetField <BSLight[]>("_lights");
     for (int i = 0; i < lights.Length; i++)
     {
         lights[i].color = UnityEngine.Random.ColorHSV().ColorWithValue(1f);                                     //ColourManager.GetTechnicolour(true, time + lights[i].GetInstanceID(), ColourManager.TechnicolourStyle.PURE_RANDOM);
     }
 }
Exemplo n.º 10
0
 public static void ActivateTechnicolour(BeatmapEventData baseData, LightSwitchEventEffect lse, BeatmapEventType type)
 {
     BSLight[] lights = lse.GetField <BSLight[]>("_lights");
     for (int i = 0; i < lights.Length; i++)
     {
         lights[i].color = ColourManager.GetTechnicolour(baseData.value > 3, baseData.time + lights[i].GetInstanceID(), ColourManager.TechnicolourStyle.PURE_RANDOM);
     }
 }
Exemplo n.º 11
0
        /*
         * LSE ColourSO holders
         */

        internal static void LSEStart(LightSwitchEventEffect lse, BeatmapEventType type)
        {
            LSEColourManager lsecm = LSEColourManager.GetOrCreateLSEColourManager(lse, type);

            if (type == BeatmapEventType.Event1)
            {
                ChromaTesting.lse = lse; ChromaTesting.type = type;
            }
        }
Exemplo n.º 12
0
 private void Initialize(LightSwitchEventEffect lse, BeatmapEventType type)
 {
     this.lse  = lse;
     this.type = type;
     InitializeSOs(lse, "_lightColor0", ref _lightColor0, ref _lightColor0_Original, ref m_lightColor0);
     InitializeSOs(lse, "_highlightColor0", ref _highlightColor0, ref _highlightColor0_Original, ref m_highlightColor0);
     InitializeSOs(lse, "_lightColor1", ref _lightColor1, ref _lightColor1_Original, ref m_lightColor1);
     InitializeSOs(lse, "_highlightColor1", ref _highlightColor1, ref _highlightColor1_Original, ref m_highlightColor1);
 }
Exemplo n.º 13
0
        private void Refresh()
        {
            Color[] colors = Color;
            SetSOs(colors);

            LightSwitchEventEffect lightSwitchEventEffect = _lightSwitchEventEffect;

            _lightSwitchEventEffect.ProcessLightSwitchEvent(_prevValueAccessor(ref lightSwitchEventEffect), true);
        }
Exemplo n.º 14
0
 public override bool Activate(ref LightSwitchEventEffect light, ref BeatmapEventData data, ref BeatmapEventType eventType)
 {
     /*if (ChromaBehaviour.Instance is ChromaBehaviour chroma) {
      *  ChromaLogger.Log("Scalechange : " + Scale);
      *  chroma.eventNoteScale = Scale;
      *  return true;
      * }
      * return false;*/
     return(true);
 }
Exemplo n.º 15
0
 public static LSEColourManager GetLSEColourManager(LightSwitchEventEffect lse)
 {
     for (int i = 0; i < LSEColourManagers.Count; i++)
     {
         if (LSEColourManagers[i].lse == lse)
         {
             return(LSEColourManagers[i]);
         }
     }
     return(null);
 }
Exemplo n.º 16
0
        public override bool Activate(ref LightSwitchEventEffect light, ref BeatmapEventData data, ref BeatmapEventType eventType)
        {
            PlayerController playerController = GameObject.FindObjectOfType <PlayerController>();

            if (playerController != null)
            {
                playerController.transform.root.rotation = Quaternion.Euler(A.r * 360, A.g * 360, A.b * 360);
                return(true);
            }
            return(false);
        }
Exemplo n.º 17
0
 public override bool Activate(ref LightSwitchEventEffect light, ref BeatmapEventData data, ref BeatmapEventType eventType)
 {
     /*PlayerController playerController = GameObject.FindObjectOfType<PlayerController>();
      * if (playerController != null) {
      *  playerController.transform.root.rotation = Quaternion.Euler(A.r * 360, A.g * 360, A.b * 360);
      *  return true;
      * }
      * return false;*/
     ringStepMult = A.r + (A.g * 15f) + (A.b * 100f);
     return(true);
 }
Exemplo n.º 18
0
        public static void CreateAdditionalLightSwitchControllers()
        {
            LightSwitchEventEffect templateSwitchEffect = Resources.FindObjectsOfTypeAll <LightSwitchEventEffect>().FirstOrDefault();

            for (int i = 6; i < 16; i++)
            {
                LightSwitchEventEffect newSwitchEffect = ReflectionUtil.CopyComponent(templateSwitchEffect, typeof(LightSwitchEventEffect), typeof(LightSwitchEventEffect), templateSwitchEffect.gameObject) as LightSwitchEventEffect;
                newSwitchEffect.SetPrivateField("_lightsID", i);
                newSwitchEffect.SetPrivateField("_event", (BeatmapEventType)(i - 1));
            }
            UpdateEventTubeLightList();
        }
Exemplo n.º 19
0
        public override bool Activate(ref LightSwitchEventEffect light, ref BeatmapEventData data, ref BeatmapEventType eventType)
        {
            GameEnergyCounter counter = GameObject.FindObjectOfType <GameEnergyCounter>();

            if (counter != null)
            {
                ChromaLogger.Log("Changing health by " + HealthChangeAmount);
                counter.AddEnergy(HealthChangeAmount);
                return(true);
            }
            return(false);
        }
Exemplo n.º 20
0
        /// <summary>
        /// Creates Additional <see cref="LightSwitchEventEffect"/>s<br/>
        /// [May create redundant/duplicate <see cref="LightSwitchEventEffect"/>s!]<br/>
        /// [May cover <see cref="BeatmapEventType"/>s that aren't supposed to be supported anymore!]<br/>
        /// [Possible Semantic Error!]
        /// </summary>
        internal static void CreateAdditionalLightSwitchControllers(LightWithIdManager lightManager)
        {
            LightSwitchEventEffect templateSwitchEffect = Resources.FindObjectsOfTypeAll <LightSwitchEventEffect>().FirstOrDefault();

            for (int i = 6; i < 16; i++)
            {
                //This Component is spawned onto a base game object and not cleaned up by Custom Platforms (in good faith that the game does so for us by unloading the environment scene)
                LightSwitchEventEffect newSwitchEffect = ReflectionUtil.CopyComponent(templateSwitchEffect, typeof(LightSwitchEventEffect), typeof(LightSwitchEventEffect), templateSwitchEffect.gameObject) as LightSwitchEventEffect;
                newSwitchEffect.SetPrivateField("_lightManager", lightManager);
                newSwitchEffect.SetPrivateField("_lightsID", i);
                newSwitchEffect.SetPrivateField("_event", (BeatmapEventType)(i - 1));
            }
        }
Exemplo n.º 21
0
        static bool Prefix(LightSwitchEventEffect __instance, ref BeatmapEventData beatmapEventData, ref BeatmapEventType ____event)
        {
            if (beatmapEventData.type == ____event)
            {
                //CustomLightBehaviour customLight = CustomLightBehaviour.GetCustomLightColour(beatmapEventData);
                ChromaEvent customEvent = ChromaEvent.GetChromaEvent(beatmapEventData);
                if (customEvent != null)
                {
                    customEvent.Activate(ref __instance, ref beatmapEventData, ref ____event);
                    return(false);
                }
            }

            return(true);
        }
Exemplo n.º 22
0
        public static bool SimpleEventActivate(LightSwitchEventEffect lse, ref BeatmapEventData beatmapEventData, ref BeatmapEventType eventType)
        {
            if (!ChromaConfig.LegacyLighting)
            {
                return(false);
            }
            int id = beatmapEventData.value;

            switch (id)
            {
            case CHROMA_EVENT_LASER_RESET_STATE_ON:
                disablePositionReset = false;
                return(true);

            case CHROMA_EVENT_LASER_RESET_STATE_OFF:
                disablePositionReset = true;
                return(true);

            case CHROMA_EVENT_LASER_SPIN_DEFAULT:
                laserSpinDirection = 0;
                return(true);

            case CHROMA_EVENT_LASER_SPIN_INBOARD:
                laserSpinDirection = 1;
                return(true);

            case CHROMA_EVENT_LASER_SPIN_OUTBOARD:
                laserSpinDirection = -1;
                return(true);

            case CHROMA_EVENT_MAIN_LIGHTNING:
                if (!ChromaConfig.CustomSpecialEventsEnabled)
                {
                    return(true);
                }
                VFXLightning.InstanceOrDefault.TriggerLightning(false);
                return(true);

            case CHROMA_EVENT_AMBIENT_LIGHTNING:
                if (!ChromaConfig.CustomSpecialEventsEnabled)
                {
                    return(true);
                }
                VFXLightning.InstanceOrDefault.TriggerLightning(true);
                return(true);
            }
            return(false);
        }
Exemplo n.º 23
0
        private static bool Prefix(LightSwitchEventEffect __instance, BeatmapEventType ____event, Color color)
        {
            if (LightColorManager.LightIDOverride != null)
            {
                List <ILightWithId> lights = __instance.GetLights();
                int type = (int)____event;
                IEnumerable <int> newIds = LightColorManager.LightIDOverride.Select(n => LightIDTableManager.GetActiveTableValue(type, n) ?? n);
                foreach (int id in newIds)
                {
                    ILightWithId lightWithId = lights.ElementAtOrDefault(id);
                    if (lightWithId != null)
                    {
                        if (lightWithId.isRegistered)
                        {
                            lightWithId.ColorWasSet(color);
                        }
                    }
                    else
                    {
                        ChromaLogger.Log($"Type [{type}] does not contain id [{id}].", IPA.Logging.Logger.Level.Warning);
                    }
                }

                LightColorManager.LightIDOverride = null;

                return(false);
            }

            // Legacy Prop Id stuff
            if (LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride != null)
            {
                ILightWithId[] lights = LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride;
                for (int i = 0; i < lights.Length; i++)
                {
                    lights[i].ColorWasSet(color);
                }

                LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride = null;

                return(false);
            }

            return(true);
        }
Exemplo n.º 24
0
#pragma warning disable SA1313 // Parameter names should begin with lower-case letter
        private static bool Prefix(LightSwitchEventEffect __instance, BeatmapEventData beatmapEventData, BeatmapEventType ____event, LightWithIdManager ____lightManager)
#pragma warning restore SA1313 // Parameter names should begin with lower-case letter
        {
            if (TechnicolorConfig.Instance.TechnicolorEnabled && beatmapEventData.type == ____event &&
                beatmapEventData.value > 0 && beatmapEventData.value <= 7)
            {
                if (TechnicolorConfig.Instance.TechnicolorLightsGrouping == TechnicolorLightsGrouping.ISOLATED)
                {
                    ____lightManager.SetColorForId(__instance.lightsId, TechnicolorController.GetTechnicolor(beatmapEventData.value > 3, beatmapEventData.time, TechnicolorConfig.Instance.TechnicolorLightsStyle));

                    List <LightWithId>[] lightManagerLights = _lightsWithIdAccessor(ref ____lightManager);
                    List <LightWithId>   lights             = lightManagerLights[__instance.lightsId];
                    for (int i = 0; i < lights.Count; i++)
                    {
                        lights[i].ColorWasSet(TechnicolorController.GetTechnicolor(beatmapEventData.value > 3, beatmapEventData.time + lights[i].GetInstanceID(), TechnicolorConfig.Instance.TechnicolorLightsStyle));
                    }

                    return(false);
                }
                else if (TechnicolorController.TechniLightRandom.NextDouble() < TechnicolorConfig.Instance.TechnicolorLightsFrequency)
                {
                    bool blue = beatmapEventData.value <= 3;
                    switch (TechnicolorConfig.Instance.TechnicolorLightsGrouping)
                    {
                    case TechnicolorLightsGrouping.ISOLATED_GROUP:
                        // ternary operator gore
                        ____event.SetLightingColors(
                            blue ? (Color?)TechnicolorController.GetTechnicolor(false, beatmapEventData.time, TechnicolorConfig.Instance.TechnicolorLightsStyle) : null,
                            blue ? null : (Color?)TechnicolorController.GetTechnicolor(true, beatmapEventData.time, TechnicolorConfig.Instance.TechnicolorLightsStyle));
                        break;

                    case TechnicolorLightsGrouping.STANDARD:
                    default:
                        Color?t = TechnicolorController.GetTechnicolor(!blue, beatmapEventData.time, TechnicolorConfig.Instance.TechnicolorLightsStyle);
                        LightColorizer.SetAllLightingColors(blue ? null : t, blue ? t : null);
                        break;
                    }
                }
            }

            return(true);
        }
Exemplo n.º 25
0
            //We still need to do the first half of this even if the LSECM already exists as custom map colours exist and we need to be able to know the default colour
            private void InitializeSOs(LightSwitchEventEffect lse, string id, ref SimpleColorSO sColorSO, ref Color originalColour, ref MultipliedColorSO mColorSO)
            {
                MultipliedColorSO lightMultSO      = lse.GetField <MultipliedColorSO>(id);
                Color             multiplierColour = lightMultSO.GetField <Color>("_multiplierColor");
                SimpleColorSO     lightSO          = lightMultSO.GetField <SimpleColorSO>("_baseColor");

                originalColour = lightSO.color;

                if (mColorSO == null)
                {
                    mColorSO = ScriptableObject.CreateInstance <MultipliedColorSO>();
                    mColorSO.SetField("_multiplierColor", multiplierColour);

                    sColorSO = ScriptableObject.CreateInstance <SimpleColorSO>();
                    sColorSO.SetColor(originalColour);
                    mColorSO.SetField("_baseColor", sColorSO);
                }

                lse.SetField(id, mColorSO);
            }
Exemplo n.º 26
0
        internal static IEnumerator Routine(LightSwitchEventEffect lse, BeatmapEventType type, Color colourFrom, Color colourTo, float duration, float freq)
        {
            BloomPrePassLight[] lights = lse.GetField <BloomPrePassLight[]>("_lights");

            float time = 0;

            while (time < duration)
            {
                for (int i = 0; i < lights.Length; i++)
                {
                    lights[i].color = Color.Lerp(colourFrom, colourTo, time / duration);
                }
                yield return(new WaitForSeconds(freq));

                time += freq;
            }
            for (int i = 0; i < lights.Length; i++)
            {
                lights[i].color = colourTo;
            }
        }
Exemplo n.º 27
0
        public static void RecolourLight(ref LightSwitchEventEffect obj, Color red, Color blue)
        {
            if (obj.name.Contains("nightmare"))
            {
                return;
            }
            string[] sa = new string[] { "_lightColor0", "_highlightColor0", "_lightColor1", "_highlightColor1" };

            for (int i = 0; i < sa.Length; i++)
            {
                string s = sa[i];

                SimpleColorSO baseSO = SetupNewLightColourSOs(obj, s);

                Color newColour = i < sa.Length / 2 ? blue : red;
                if (newColour == Color.clear)
                {
                    continue;
                }

                baseSO.SetColor(newColour);
            }
        }
Exemplo n.º 28
0
        public static LightEffectController Create(
            LightWithIdManagerWrapper lightManager,
            LightMode activeOnMode,
            LightSwitchEventEffect baseLight,
            IAudioTimeSource timeSource
            )
        {
            int id = Helper.GetValue <int>(baseLight, "_lightsID");
            BeatmapEventType eventTypeForThisLight = Helper.GetValue <BeatmapEventType>(baseLight, "_event");

            int lastEventValue = Helper.GetValue <int>(baseLight, "_prevLightSwitchBeatmapEventDataValue");

            LightEffectController controller = new GameObject("TwitchFXLightEffectController").AddComponent <LightEffectController>();

            controller.timeSource            = timeSource;
            controller.lightManager          = lightManager;
            controller.activeOnMode          = activeOnMode;
            controller.id                    = id;
            controller.eventTypeForThisLight = eventTypeForThisLight;

            controller.lastEventData = new BeatmapEventData(0f, eventTypeForThisLight, lastEventValue);

            controller.enabled = baseLight.enabled;

            if (baseLight.enabled)
            {
                float highlightValue = Helper.GetValue <float>(baseLight, "_highlightValue");

                controller.transitionValue = highlightValue;

                controller.startColor = offColor;
                controller.endColor   = offColor;
            }

            return(controller);
        }
Exemplo n.º 29
0
        private static bool Prefix(LightSwitchEventEffect __instance, BeatmapEventType ____event, Color color)
        {
            if (LightColorManager.LightIDOverride != null)
            {
                List <ILightWithId> lights = __instance.GetLights();
                int type = (int)____event;
                IEnumerable <int> newIds = LightColorManager.LightIDOverride.Select(n => LightIDTableManager.GetActiveTableValue(type, n) ?? n);
                foreach (int id in newIds)
                {
                    if (lights[id].isRegistered)
                    {
                        lights[id].ColorWasSet(color);
                    }
                }

                LightColorManager.LightIDOverride = null;

                return(false);
            }

            // Legacy Prop Id stuff
            if (LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride != null)
            {
                ILightWithId[] lights = LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride;
                for (int i = 0; i < lights.Length; i++)
                {
                    lights[i].ColorWasSet(color);
                }

                LightSwitchEventEffectHandleBeatmapObjectCallbackControllerBeatmapEventDidTrigger.LegacyLightOverride = null;

                return(false);
            }

            return(true);
        }
Exemplo n.º 30
0
 public abstract bool Activate(ref LightSwitchEventEffect light, ref BeatmapEventData data, ref BeatmapEventType eventType);