T
Taylor Romey
Guest
I want to draw a circle that has a set alpha in the middle, and a different alpha near the edge. (Essentially a circle with faded edges)
I know "draw_circle_color" draws a circle with a different color in the middle than the edge, but doesn't deal with alpha. I have searched the help file for a function that does this and can't seem to find one.
I have tried using a for loop to draw individual circles of varying size and alpha to imitate the effect I'm looking for however it seems grossly inefficient. Considering that I'd like to have many of these circles drawn.
Does GMS2 have a function that can draw a circle like this?
I know "draw_circle_color" draws a circle with a different color in the middle than the edge, but doesn't deal with alpha. I have searched the help file for a function that does this and can't seem to find one.
I have tried using a for loop to draw individual circles of varying size and alpha to imitate the effect I'm looking for however it seems grossly inefficient. Considering that I'd like to have many of these circles drawn.
Code:
var i, n;
n = 100;
for(i=n;i>0;i--)
{
draw_set_alpha(1-(i/n));
draw_circle_color(x,y,(sprite_width/2)+(i*2),make_color_hsv(40,255*(1-(i/n)), 255),make_color_hsv(40,255*(1-(i/n)), 255),false);
}