Header

Header

Friday 12 December 2014

ACSS InfoTech 2014-15 Day: 52

Today, I was finding a way to create a fade in effect for the text in my intro screen. Currently, I am working around this script for right now to see if it will work with my game:

draw_self();
image_speed = 0.15
 
if (showtext ==1)
{
    draw_rectangle_color(81,51,295,89,c_black, c_black, c_black, c_black, false);
    draw_rectangle_color(82,52,294,88,c_gray, c_gray, c_dkgray, c_dkgray, false);
    draw_set_color(c_black);
    draw_set_halign(fa_center);
    draw_set_font(fnt_default);
    draw_text(x+1,y-95+1,"Title Of Game")
        
    draw_set_color(c_white);
    draw_set_halign(fa_center);
    draw_set_font(fnt_default);
    draw_text(x,y-95,"Title Of Game")
}

Most of the script is setting/centering the text in the game and the other bit is drawing the text and having a speed set on when the text appears. I'll be working around this script next class so it will be compatible in the games I'm creating. 

No comments:

Post a Comment