RTS map format...

Blitz3D Forums/Blitz3D Programming/RTS map format...

How would you guys suggest I design the map structure for an RTS?

General question so im looking for some general answers :). Major details arent required but would be appreciated.

[edit] Its a 3d map.

I think it's going to depend a great deal on what features you need. Like: just terrain or do you also need lineal (it's a word, really) features like roads, rivers, fences, etc. and areal (again :) ) features like lakes, forests, terrain types. Also, what about buildings, etc.

Can you give some more details about what data you need in there?
M

yeah, serious features like found in WC3 would be great, and a huge/MASSIVE undertaking. Any thoughts?

I would use an image file. Combine with ReadPixelFast, the image file can be loaded into a specific buffer.

Similar to Loading Terrains, (which the image file can double up as,) except that the Blue and Green color values have a meaning too. For instance Blue may represent trees or a type of building, green may be used for trigger areas etc.

Thats not a bad idea Malice. Keep idea comming tho :), very helpful.

Use an array of types, then you can easily add more features to the terrain by adding more fields to the type.


Dim Terrain.tile(Wid,Dep)

Type tile

Field Height#

Field Walkable

End Type



This is what I have done in my RTS

Thanksjeppe, I think I will start with something like that and build on. Thanks everyone.