draw_circle_colour

Draws a circle of a given size with a two-colour radial gradient.

Syntax:

draw_circle_colour(x, y, r, col1, col2, outline);


Argument Description
x The x coordinate of the center of the circle.
y The y coordinate of the center of the circle.
r The radius (distance from center to edge) of the circle in pixels.
col1 The colour at the center of the circle.
col2 The colour at the edge of the circle.
outline Whether the circle is an outline (true) or not (false). If true, col1 is irrelevant.


Returns: N/A


Description

With this function you can draw either an outline of a circle or a filled circle, and if it is filled you can define the interior and exterior fill colours. If these colours are not the same, you will get a gradient effect from one to the other and the colour settings will over-ride the base colour set with the function draw_set_colour. You can define how precise the drawing is with the function draw_set_circle_precision.


Example:

draw_circle_colour(x, y, 100, c_white, c_black, false);

This would draw a filled circle with its center at the executing instance's x and y position, with a radius of 100 pixels, from white in the center to black at the outside.


Back: Drawing Basic Forms
Next: draw_ellipse
© Copyright YoYo Games Ltd. 2018 All Rights Reserved