コード例 #1
0
        public bool MatchingFilters(BeatmapCharacteristicDifficulty difficulty, Beatmap mapData)
        {
            bool npsCondition    = NPS.HasValue ? MapTools.GetNotesPerSecond(mapData.Metadata.BPM, difficulty.Duration, difficulty.Notes) >= NPS.Value : true;
            bool ratingCondition = Rating.HasValue ? mapData.Stats.Rating >= Rating.Value * 100 : true;

            return(UsingFilters ? npsCondition && ratingCondition : true);
        }
        public string GetInfoText(double bpm)
        {
            int    minutes        = (int)length / 60;
            int    seconds        = (int)length - minutes * 60;
            double notesPerSecond = MapTools.GetNotesPerSecond(bpm, duration, notes);
            string lengthInfo     = minutes + " minutes " + seconds + " seconds ";

            if (length <= 60)
            {
                lengthInfo = (int)length + " seconds ";
            }

            return
                ("Length: " + lengthInfo + "\n" +
                 "Note jump speed: " + njs + "\n" +
                 "Notes per second: " + notesPerSecond + "\n" +
                 "Bombs: " + bombs + "\n" +
                 "Notes: " + notes + "\n" +
                 "Obstacles: " + obstacles);
        }