The coding bug.
I got the urge to start coding more and more, so I did some work on Rustbot. I didn't work on the actual game itself, but rather I worked on some tech that I can apply to it.
I wanted to have the level/map/land load dynamically as the player moves around, so that the entire world is not loaded all at once. So I wrote a program to take a giant 4096x4096 pixel heightmap and split it into 4096 64x64 pixel heightmap tiles. Then I created a new project wherein it only loads/displays the tile the player is in and the adjacent ones.
Figure 1 - The bright green tile contains the player (white dot) and the dark green are the adjacent tiles. |
Figure 1 above displays what I mean. So, when the player (the white dot) moves from one tile to another, it needs to ditch the tiles that were adjacent (but aren't anymore) and load the tiles that are.
Figure 2 - Player has moved right by one tile |
This is how we avoid load screens and annoying waits between levels. After this, I'll see about re-writing the object classes and get Rustbot off the ground again.
Speaking of... just how much sense, given what's been established gameplay, does the name "Rustbot" make?
No comments:
Post a Comment