-
Notifications
You must be signed in to change notification settings - Fork 1
/
beatmap.h
44 lines (37 loc) · 929 Bytes
/
beatmap.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
#pragma once
#include "raylib.h"
typedef struct Note {
Vector2 position;
int sliderVelocity;
float timing;
int isBlue;
int bigNote;
int isPressed;
Color noteColor;
} Note;
typedef struct Beatmap {
Note* notes;
int noteCount;
float hpDrain;
float od;
char* title;
char* artist;
char* difficultyName;
char* audioFileName;
char* backgroundFileName;
char* directory;
Texture2D background;
Music audio;
} Beatmap;
extern Beatmap* currentBeatmap;
extern float hitWindowGreat;
extern float hitWindowGood;
extern float hitWindowMiss;
Beatmap* LoadBeatmapFromFile(const char* filename);
void FreeBeatmap(Beatmap* beatmap);
void LoadBeatmapAudio(Beatmap* beatmap);
void LoadBeatmapBackground(Beatmap* beatmap);
int GetBeatmapInfoInt(char* line);
float GetBeatmapInfoFloat(char* line);
char* GetBeatmapInfoString(char* line);
void ResetGameplayVariables();