-
Notifications
You must be signed in to change notification settings - Fork 1
/
neptune.h
70 lines (62 loc) · 1.87 KB
/
neptune.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
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
/*-------------------------------------------------------------------------------+
| ~+ * + |
| ' | _ _ ___________ _____ _ _ _ _ _____ |
| () .-.,="``"=. - o - | \ | || ___| ___ \_ _| | | | \ | || ___| |
| '=/_ \ | | \| || |__ | |_/ / | | | | | | \| || |__ |
| * | '=._ | | . ` || __|| __/ | | | | | | . ` || __| |
| \ `=./`, ' | |\ || |___| | | | | |_| | |\ || |___ |
| + . '=.__.=' `=' * \_| \_/\____/\_| \_/ \___/\_| \_/\____/ |
| BY: @G_Sansigolo |
+-------------------------------------------------------------------------------*/
#ifndef neptune
#define neptune
static jo_font *my_font;
/**
* set_background()
* plot background image
*/
void set_background(char* filename, char* folder){
jo_img bg;
bg.data = NULL;
jo_tga_loader(&bg, folder, filename, JO_COLOR_Green);
jo_set_background_sprite(&bg, 0, 0);
jo_free_img(&bg);
}
/**
* d()
* draw text on the screen
*/
void d(char* text, int line){
if (line == 1)
jo_font_printf(my_font, 90, (23)*7.9, 1.0f, text);
else
jo_font_printf(my_font, 12, (21+(2*line))*7.9, 1.0f, text);
}
/**
* h()
* draw text on the screen
*/
void h(char* text, int color){
if (color)
jo_font_printf(my_font, 12, (23)*7.9, 1.0f, text);
}
/**
* d_n()
* draw text on the screen
*/
void d_n(char* text, int line){
if (line == 1)
jo_font_printf(my_font, 12, (23)*7.9, 1.0f, text);
else
jo_font_printf(my_font, 12, (21+(2*line))*7.9, 1.0f, text);
}
/**
* clear_screen()
* clean screen without using jo_clear_screen
*/
void clear_screen() {
d_n("",1);
d("",2);
d("",3);
}
#endif