Yeah, I realized that this has nothing to do with choice of dimension, whether isometric or square.
I realized that even in my 2D square-tiled "Snow Wars", formerly posted to you, having more than twenty or thirty objects in whole map (but that was rather whole map processing I think), had resulted into slowdown.
I wonder how did they made games like Dune 2000 (the same principle 2D square-tiled RTS) or Starcraft, without problems of slowdown, no matter how many objects you have in map. - cos in Dune 2000, you can train and train new units, have vast armies thru whole map and still it doesn't slowdown.
I guess there's needed some modification of processing whole maps including all data within.
The thing I do concerning drawing, is having terrain linear lists of numbers - it's classical method of tiling - each tile type has specific number, while the unit data in map is rather more complicated - but it has to be complicated, cos units need to carry far more data than terrain tiles.
My unit data list is number of lists within one list. Each of these lists within are whole units with all data they carry. most of it are dynamic data, cos they have to change during the game.
Main of these are X and Y positions (tile positions in map).
And now the problem I have is that I can't avoid looping the whole unit list to locate what should be drawn where in viewport display - the current display where you are currently scrolled in map. You still need to check what if the last unit with number 100 or 200 is located in top-left corner, which would have 0,0 - X,Y positions.
Of course it needs to be drawn if we are in viewport in which you can see position 0,0 - the top-left corner.
Are that, Jasmine, what you have posted, lesser loops within one loop?
100 loops and in each idx= 1 to 100?
And would that be faster than from 1 to 10000 for computers?
plus, concerning the baby steps processing, would not there be some delay visible in the units on the display during those 200 frames in those 50 objects per redraw?
I guess that would mean that my unit - 100-th unit in unit list, located at 0,0 would be processed last. Am I right? Or.... ...is it a matter of computer memory how many objects it can process at once?
I don't know these principles.
What is too much for computer, resulting in slowdown and what is without any delay?
They must have had done Dune2000 map processing somehow without any delay. But how?
Maybe pre-loading and loading maps on starting that takes some time, fixes this?
How then to preload it all and what if new units arrive that weren't formerly on the map from the start - and so no preloading occured upon them?
Jasmine:
Quote:
You could also then write a subroutine for sorting that small list of 100 objects only when it has changed.

But that's practically all the time, even movement of one unit from that list means change of the list, or not?