示例#1
0
            private void load(TauRulesetConfigManager settings)
            {
                RelativeSizeAxes = Axes.Both;
                Size             = new Vector2(UNIVERSAL_SCALE);
                Anchor           = Anchor.Centre;
                Origin           = Anchor.Centre;

                Child = visualisation = new LogoVisualisation
                {
                    RelativeSizeAxes = Axes.Both,
                    FillMode         = FillMode.Fit,
                    FillAspectRatio  = 1,
                    Blending         = BlendingParameters.Additive,
                    Anchor           = Anchor.Centre,
                    Origin           = Anchor.Centre,
                    Colour           = Color4.Transparent
                };

                settings?.BindWith(TauRulesetSettings.ShowVisualizer, ShowVisualisation);
                ShowVisualisation.BindValueChanged(value => { visualisation.FadeTo(value.NewValue ? 1 : 0, 500); });
            }
示例#2
0
            private void load(TauRulesetConfigManager settings)
            {
                RelativeSizeAxes = Axes.Both;
                Size             = new Vector2(0.6f);
                Anchor           = Anchor.Centre;
                Origin           = Anchor.Centre;

                Child = visualisation = new LogoVisualisation
                {
                    RelativeSizeAxes = Axes.Both,
                    FillMode         = FillMode.Fit,
                    FillAspectRatio  = 1,
                    Blending         = BlendingParameters.Additive,
                    Anchor           = Anchor.Centre,
                    Origin           = Anchor.Centre,
                    Colour           = Color4.Transparent
                };

                ShowVisualisation = settings.GetBindable <bool>(TauRulesetSettings.ShowVisualizer);

                ShowVisualisation.ValueChanged += value => { visualisation.FadeTo(value.NewValue ? 1 : 0, 500); };
                ShowVisualisation.TriggerChange();
            }