Draws a sprite at a given position, and tiles it to fill the entire view.


draw_sprite_tiled(sprite, subimg, x, y);

Argument Description
sprite The index of the sprite to draw.
subimg The subimg (frame) of the sprite to draw (image_index or -1 correlate to the current frame of animation in the object).
x The x coordinate of where to draw the sprite.
y The y coordinate of where to draw the sprite.

Returns: N/A


This function will take a sprite and then repeatedly tile it across the whole view (or room if no view is defined), starting from the coordinates that you give in the function. Tiling is based on the width and height of the sprite as defined by the sprite variables of the instance running the code.


draw_sprite_tiled(sprite_index, image_index, x, y);

This will draw the instances assigned sprite (sprite_index) and its current frame of animation (image_index) at the instances own x and y position, and tiled horizontally and vertically across the view.

Back: Drawing Sprites And Backgrounds
Next: draw_sprite_tiled_ext
© Copyright YoYo Games Ltd. 2015 All Rights Reserved