File tree Expand file tree Collapse file tree 4 files changed +10
-13
lines changed
include/RhythmGameUtilities Expand file tree Collapse file tree 4 files changed +10
-13
lines changed Original file line number Diff line number Diff line change 5
5
namespace RhythmGameUtilities
6
6
{
7
7
8
- typedef enum Difficulty
9
- {
8
+ using Difficulty = enum : uint8_t {
10
9
// Easy Difficulty
11
10
Easy,
12
11
@@ -18,7 +17,7 @@ typedef enum Difficulty
18
17
19
18
// Expert Difficulty
20
19
Expert
21
- } DifficultyType ;
20
+ };
22
21
23
22
inline auto ToString (Difficulty difficulty) -> std::string
24
23
{
Original file line number Diff line number Diff line change 5
5
namespace RhythmGameUtilities
6
6
{
7
7
8
- typedef enum NamedSection
9
- {
8
+ using NamedSection = enum : uint8_t {
10
9
// / Song information
11
10
Song,
12
11
@@ -15,7 +14,7 @@ typedef enum NamedSection
15
14
16
15
// / Track events
17
16
Events
18
- } NamedSectionType ;
17
+ };
19
18
20
19
inline auto ToString (NamedSection namedSection) -> std::string
21
20
{
Original file line number Diff line number Diff line change 5
5
namespace RhythmGameUtilities
6
6
{
7
7
8
- typedef enum TypeCode
9
- {
8
+ using TypeCode = enum : uint8_t {
10
9
// / BPM Marker
11
10
BPM_Marker,
12
11
@@ -18,7 +17,7 @@ typedef enum TypeCode
18
17
19
18
// / Event Marker
20
19
EventMarker
21
- } TypeCodeType ;
20
+ };
22
21
23
22
inline auto ToString (TypeCode typeCode) -> std::string
24
23
{
Original file line number Diff line number Diff line change 16
16
namespace RhythmGameUtilities
17
17
{
18
18
19
- typedef struct
19
+ using KeyValuePairInternal = struct
20
20
{
21
21
char *key;
22
22
char *values[10 ];
23
23
int valueCount;
24
- } KeyValuePairInternal ;
24
+ };
25
25
26
- typedef struct
26
+ using ChartSectionInternal = struct
27
27
{
28
28
char *name;
29
29
KeyValuePairInternal *lines;
30
30
int lineCount;
31
- } ChartSectionInternal ;
31
+ };
32
32
33
33
std::regex CHART_SECTION_PATTERN (R"( \[([a-z]+)\]\s*\{([^\}]+)\})" ,
34
34
std::regex_constants::icase);
You can’t perform that action at this time.
0 commit comments