Game Development Community

Some questions about TGB and tile based games

by bigredron · in General Discussion · 11/08/2009 (8:25 pm) · 1 replies

Hi,
I have been playing with various other game creation tools over the years trying to find one that is powerful and easy enough to make a 2D RTS game similar to age of empires 2.
I want my game maps to be diamond shaped isometric and my terrain will be built with iso tiles 64x32px in size.

I have had a quick look at the TGB demo and see there is support for tile maps, but I cant see anyway to change from standard square grid to iso grid. I know the maths and concept behind isometrics, so thats not reall going to be a big problem for me providing I can code it via the scripting language (I hope).

My maps are going to be stored as some sort of array file saved externally (I will make an editor to do this). I want to load this map file at runtime and then build by world from that.

My initial questions are;

1. What is te best way to store multiple tiles. Do I have to store each tile as a seperate sprite, or do I load all my tiles into one tilemap and use those? If I use a tilemap can I select which frame to draw and where to position it on the frame during runtime?
2. Does TGB handle the drawing itself or do I have to code this myself? What I mean by this is if I have a map say 200 x 200 tiles in size, will the TGB engine automatically draw what is visible only on the screen? Will having 40000 tiles OUTSIDE the visible frame add any lag to the game?
3. Does the a* pathfinding work based on square tilemaps? If so how does one adapt this to isometric? Would I need to have a layer dedicated only to obstacles and use this for the pathfinding?
4. This is the important one. I need to be able to draw terrain transitions whenever different terrain types are adjacent to eachother. If, for example, I have a grass tile next to a sand tile, I want to blend the two together. The way I imagine this would work is I draw my base tile (grass) and then load the sand tile, apply the appropriate alpha mask to it and then draw the sand tile on top of the grass tile resulting in a blend between the two. Does TGB support this??? Or is there an easier way than this?

Thanks in advance. Looking forward to some positive answers.

NOTE: I am hoping to do this without modifying the source code itself as I am no C++ programmer. I am hoping to do all this via the torque script.

-Cameron

#1
11/12/2009 (6:41 pm)
Anyone? If this is in the wrong forum please let me know and I will repost somewhere more appropriate.