• Hey Guest! Ever feel like entering a Game Jam, but the time limit is always too much pressure? We get it... You lead a hectic life and dedicating 3 whole days to make a game just doesn't work for you! So, why not enter the GMC SLOW JAM? Take your time! Kick back and make your game over 4 months! Interested? Then just click here!

Question about Nine Slice and draw calls.

So, the most recent beta release of Game Maker Studio 2 has a new feature called Nine Slice which allows you to essentially scale a "window" to any size using 9 sprites: 4 ordinal sprites, 4 cardinal sprites, and a middle sprite. Previously, you could accomplish this by writing a nested for loop of draw_sprites. This would mean that the larger you scaled your sprite, the more draw calls would occur per step. I was wondering if this new "built-in" Nine Slice feature also has more draw calls the larger you scale the sprite or if it only has one draw call per step.
 

Nidoking

Member
I just implemented it for one of my games and removed the for loops I was using to draw the sprites in favor of using just scaling. So in the code, it's just the one draw call, but I can't tell you how it's implemented internally. It's got to be more efficient than for loops in the Draw event, though.
 
Top