blob: 69702ad520557baf9bb50f49ec2e756126f48bc9 (
plain)
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
45
46
47
48
49
50
51
52
53
54
|
/*********************************/
/* YABS ( // */
/* main ( )/ */
/* by salade )(/ */
/* ________________ ( /) */
/* ()__)____________))))) :^} */
/*********************************/
#include <raylib.h>
#include "yabs_core.h"
#include "yabs_utils.h"
static yabs::core::gameState game_state = yabs::core::GAMEPLAY;
int main(void) {
// create window
InitWindow(YABS_SCREENWIDTH, YABS_SCREENHEIGHT, YABS_TITLE);
bool started = false;
// game loop
while (!WindowShouldClose()) {
switch (game_state) {
case (yabs::core::TITLE): {
if (IsKeyPressed(KEY_ENTER))
{
game_state = yabs::core::GAMEPLAY;
}
break;
}
case (yabs::core::PICK): {
break;
}
case (yabs::core::DEATH): {
break;
}
case (yabs::core::GAMEPLAY): {
if (!started)
{
started = true;
yabs::core::init_game();
}
break;
}
case (yabs::core::NEXT): {
break;
}
case (yabs::core::ENDING): {
break;
}
}
}
CloseWindow();
return (0);
}
|