Subversion Repositories Kolibri OS

Rev

Rev 5243 | Show entire file | Regard whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 5243 Rev 5291
Line 485... Line 485...
485
    0.6, 0.8, 1.0, 1.0,
485
    0.6, 0.8, 1.0, 1.0,
486
    1.0, 0.8, 0.6, 1.0,
486
    1.0, 0.8, 0.6, 1.0,
487
    0.6, 0.6, 0.6, 0.9,
487
    0.6, 0.6, 0.6, 0.9,
488
};
488
};
Line -... Line 489...
-
 
489
 
-
 
490
 
489
 
491
 
-
 
492
void game_textout(int x, int y, int font_index, char* s) {
-
 
493
    game_textout_adv(&game.framebuffer, x, y, font_index, DRAW_MODE_ALPHA, s);
-
 
494
};
-
 
495
 
-
 
496
void game_textout_at_center(int x, int y, int font_index, char *s) {
-
 
497
    x += (GAME_WIDTH - game.tex_font[font_index*64].w*strlen(s))/2; 
-
 
498
    game_textout_adv(&game.framebuffer, x, y, font_index, DRAW_MODE_ALPHA, s);
-
 
499
};
-
 
500
 
-
 
501
void game_textout_adv(rs_texture_t *dest, int x, int y, int font_index, int draw_mode, char* s) {
Line 490... Line 502...
490
void game_textout(int x, int y, int font_index, char* s) {
502
//void game_textout(int x, int y, int font_index, char* s) {
491
    
503
    
492
    int i = 0;
504
    int i = 0;
493
    while (*s) {
505
    while (*s) {
494
        if (*s != ' ') {
506
        if (*s != ' ') {
495
            texture_draw(&game.framebuffer, &game.tex_font[ 64*font_index + ((*s - 48) % 64) ], x+i*game.tex_font[64*font_index+0].w, y, DRAW_MODE_ALPHA);
507
            texture_draw(&game.framebuffer, &game.tex_font[ 64*font_index + ((*s - 48) % 64) ], x+i*game.tex_font[64*font_index+0].w, y, draw_mode);
496
        };
508
        };
497
        s++;
509
        s++;