• 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!

Legacy GM DS_grid and procedural loading

R

Richard Mountain

Guest
I'm working on a game at the moment that uses a ds_grid to load the background, the issue is that I want the grid size to be 10k x 10k ( as an example ) if I want to loop through the entire grid and add specific tiles depending on the grid cell value, this takes a lot of time.

At the moment I have it so that it only loads the grid cells that are in view. However I'm struggling with working out how to load off screen tiles just before they come into view.
 

jo-thijs

Member
Not sure if tiles are such a good idea here.

I would personally have some object with a very high depth draw every "tile" inside the view by looping through the relevant indices in the grid.
The view position and dimensions are always decided by that time and you can access them using view_xview[view_current] and the like (view_current should not be replaced).
 
Top