draw_get_alpha

Gets the current draw alpha value.

Syntax:

GML Code Example

draw_get_alpha()


Returns: Real


Description

This function returns the current value of the draw alpha, which will range between 0 (fully transparent) and 1 (fully opaque). The draw alpha affects the transparency of all draw functions, and can be set with the draw_set_alpha function.


Example:

GML Code Example

if draw_get_alpha() != 1
    {
    draw_set_alpha(1);
    }
 

The above code first checks the current draw alpha and then if it is not set to 1 it sets it to 1.





No Examples Submitted

Does this page need better examples? Be the first to Submit

No Edits Suggested

Is this page unclear or not descriptive enough? Suggest an edit to the page and with enough upvotes your changes will be made.

No Questions Have Been Ask

Do you have a question about this page? Ask it Here