RhythmGame 1.4.3
Loading...
Searching...
No Matches
Lr2Gauge.h
Go to the documentation of this file.
1//
2// Created by bobini on 10.09.23.
3//
4
5#ifndef RHYTHMGAME_LR2GAUGE_H
6#define RHYTHMGAME_LR2GAUGE_H
7
8#include "BmsGauge.h"
9#include "TimingWindows.h"
10
11#include <QObject>
12#include <functional>
13namespace gameplay_logic::rules {
14class Lr2Gauge : public BmsGauge
15{
16 bool permanentDeath;
17 std::function<double(double, Judgement)> judgementValueFactory;
18
19 public:
20 explicit Lr2Gauge(
21 QString gaugeName,
22 double gaugeMax,
23 double initialValue,
24 double threshold,
25 bool permanentDeath,
26 bool courseGauge,
27 std::function<double(double, Judgement)> judgementValueFactory,
28 QObject* parent = nullptr);
29 void addHit(std::chrono::nanoseconds offsetFromStart,
30 std::chrono::nanoseconds hitOffset,
31 Judgement judgement) override;
32 void addMineHit(std::chrono::nanoseconds offsetFromStart,
33 double penalty) override;
34
35 static auto getGauges(double total, int noteCount)
36 -> std::vector<std::unique_ptr<BmsGauge>>;
37
38 static auto getDanGauges(const QHash<QString, double>& initialValues) -> std::vector<std::unique_ptr<BmsGauge>>;
39};
40
41} // namespace gameplay_logic::rules
42
43#endif // RHYTHMGAME_LR2GAUGE_H
int64_t offsetFromStart
Definition BmsReplayData.cpp:38
Definition BmsGauge.h:40
bool courseGauge
Whether the gauge is a course gauge.
Definition BmsGauge.h:53
double gaugeMax
The maximum possible value of the gauge.
Definition BmsGauge.h:61
double threshold
The threshold value of the gauge.
Definition BmsGauge.h:67
Definition Lr2Gauge.h:15
void addMineHit(std::chrono::nanoseconds offsetFromStart, double penalty) override
Definition Lr2Gauge.cpp:308
static auto getDanGauges(const QHash< QString, double > &initialValues) -> std::vector< std::unique_ptr< BmsGauge > >
Definition Lr2Gauge.cpp:218
void addHit(std::chrono::nanoseconds offsetFromStart, std::chrono::nanoseconds hitOffset, Judgement judgement) override
Definition Lr2Gauge.cpp:9
static auto getGauges(double total, int noteCount) -> std::vector< std::unique_ptr< BmsGauge > >
Definition Lr2Gauge.cpp:49
Judgement
The possible judgements for note hits.
Definition Judgement.h:18
Namespace for logic that affects how the game plays exactly.
Definition BmsGauge.cpp:7