コード例 #1
0
        private void load(AudioManager audio, OsuColour colours)
        {
            sampleOn  = audio.Samples.Get(@"UI/check-on");
            sampleOff = audio.Samples.Get(@"UI/check-off");

            activeColour = colours.ForModType(Mod.Type);
        }
コード例 #2
0
        private void load(OsuColour colours, OverlayColourProvider?colourProvider)
        {
            inactiveBackgroundColour = colourProvider?.Background5 ?? colours.Gray3;
            activeBackgroundColour   = colours.ForModType(mod.Type);

            inactiveForegroundColour = colourProvider?.Background2 ?? colours.Gray5;
            activeForegroundColour   = Interpolation.ValueAt <Colour4>(0.1f, Colour4.Black, activeForegroundColour, 0, 1);
        }
コード例 #3
0
ファイル: ModPanel.cs プロジェクト: omkelderman/osu
        private void load(AudioManager audio, OsuColour colours, ISamplePlaybackDisabler?samplePlaybackDisabler)
        {
            sampleOn  = audio.Samples.Get(@"UI/check-on");
            sampleOff = audio.Samples.Get(@"UI/check-off");

            activeColour = colours.ForModType(Mod.Type);

            if (samplePlaybackDisabler != null)
            {
                ((IBindable <bool>)samplePlaybackDisabled).BindTo(samplePlaybackDisabler.SamplePlaybackDisabled);
            }
        }