i get around
i did this as a challenge to myself, but might turn it into a game later on huh.
i get around 310 FPS at 40 x 40 tiles. my max FPS is 915 FPS at 3 x 3 tiles. these all include the buffers ofcourse, so 3x3 isnt even playable (its 1 playable tile, 8 buffer ones surrounding it).
use the arrow keys to move around. i created a mockup map - 12 x 12 tiles. pretty tiny i know.. the other tiles will display an error tile. these are all tiles too though. the grey box shows what would be inside the viewable area, and outside it is the buffer.
ctrl + wheel up/down to make the area to be drawn wider/thinner.
shift + wheel up/down to make it higher/shorter
ctrl + shift + wheel up/down to make it bigger
what i really want to know
the point of this is to save the computer all the work of drawing the entire map. have i done a good job? or is the FPS impact far too much? (i guess what i mean is how efficient is this, as i dont have much to compare to in my experiances?)
bit of a lua question; how could i load the contents of a table from a file. for example, file X.file has the contents:
Code: Select all
{1,2,3,4}
a_table = loadfromfile("X.file")
resulting in
Code: Select all
a_table = {1,2,3,4}