vibrio.types#
Custom types used with Lazer and LazerAsync.
- class vibrio.types.HitStatistics(count_300: int, count_100: int, count_50: int, count_miss: int, combo: int)#
Dataclass representing an osu! play in terms of individual hit statistics.
- combo: int#
- count_100: int#
- count_300: int#
- count_50: int#
- count_miss: int#
- class vibrio.types.OsuDifficultyAttributes(mods: list[OsuMod], star_rating: float, max_combo: int, aim_difficulty: float, speed_difficulty: float, speed_note_count: float, flashlight_difficulty: float, slider_factor: float, approach_rate: float, overall_difficulty: float, drain_rate: float, hit_circle_count: int, slider_count: int, spinner_count: int)#
osu!standard difficulty attributes, as produced by osu!lazer’s internal difficulty calculation.
See also
Lazer.calculate_difficultyLazerAsync.calculate_difficulty
- aim_difficulty: float#
- approach_rate: float#
- drain_rate: float#
- flashlight_difficulty: float#
- hit_circle_count: int#
- max_combo: int#
- overall_difficulty: float#
- slider_count: int#
- slider_factor: float#
- speed_difficulty: float#
- speed_note_count: float#
- spinner_count: int#
- star_rating: float#
- class vibrio.types.OsuMod(value, names=None, *values, module=None, qualname=None, type=None, start=1, boundary=None)#
Enum representing the osu!standard mods as two-letter string codes.
- AUTOPILOT = 'AP'#
- AUTOPLAY = 'AT'#
- DOUBLE_TIME = 'DT'#
- EASY = 'EZ'#
- FLASHLIGHT = 'FL'#
- HALF_TIME = 'HT'#
- HARD_ROCK = 'HR'#
- HIDDEN = 'HD'#
- NIGHTCORE = 'NC'#
- NO_FAIL = 'NF'#
- PERFECT = 'PF'#
- RELAX = 'RX'#
- SPUN_OUT = 'SO'#
- SUDDEN_DEATH = 'SD'#
- TOUCH_DEVICE = 'TD'#
- class vibrio.types.OsuPerformanceAttributes(total: float, aim: float, speed: float, accuracy: float, flashlight: float, effective_miss_count: float)#
osu!standard performance attributes, as produced by osu!lazer’s internal performance calculation.
See also
Lazer.calculate_difficultyLazerAsync.calculate_difficulty
- accuracy: float#
- aim: float#
- effective_miss_count: float#
- flashlight: float#
- speed: float#
- total: float#
The play’s total pp amount.
- class vibrio.types.SerializableDataclass#
Abstract base for dataclasses supporting serialization to and deserialization from a dictionary.
This base class is intended for cross-compatible use with return types from C# code, so key names are expected in camel case during deserialization and are normalized to remove underscores during serialization.
Methods
from_dict(data)Instantiates a dataclass from the provided dictionary.
to_dict()Serializes dataclass values to a dictionary.
- classmethod from_dict(data: dict[str, Any]) Self#
Instantiates a dataclass from the provided dictionary.
- to_dict() dict[str, Any]#
Serializes dataclass values to a dictionary.