Archived

This topic is now archived and is closed to further replies.

epic709

Why choose square tiles and not hex ones?

Recommended Posts

epic709    122
Hi, What are the reasons - from a design perspective - to choose square (actually diamonds) tiles instead of six-sided hexagons for an isometric-view game? I choose the conventional diamond tiles because I thought they would be easier to implement. But somebody with experience pointed out that this wasn''t the case because both types tile very nicely and have only minor differences. Can somebody with even more experience point out why one is preferable than the other and in what situations? Thanks a lot. p/s: this is for a college project and the reasons really have to make sense.

Share this post


Link to post
Share on other sites
Null and Void    1088
Collision detection would be much harder with hex tiles (or at least slower) than with four sides ones, or at least, that is my take on it .

Null and Void
"In this house we obey the laws of thermodynamics!" --Homer Simpson

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
Null and Void: Did you even read the question? "From a design perspective"

Many tile-based games use squares (why you call them diamonds?) but you can move your units sub-square accurately also. Like Super Mario for an easy example (ok, it''s side-view but you get the point). So I really don''t see much difference between using square tiles or hex tiles. In a strategy game, it''s really same if Civilization was square or hex based. Completely. But I also prefer square tiles because easier implementation and faster drawing. I''ve played Steel Panthers (hex based) and I have no idea why it has hex based and not square based tiles. Maybe they wanted some originality?

Share this post


Link to post
Share on other sites
BitMaster    8651
Hex tiles are much better for strategic games. With square (that includes diamonds for now) tiles you have to notice that moving diagonal is moving the unit much further than a horizontal or vertical movement. With hex tiles you don''t have that problem: From one tile to the next is always the same distance.

I read an article about hex tiles a few months ago that had many explanations why hex tiles are better (for certain types of games). Unfortunately I can neither remember where nor what exactly they said...

And Anon: I think hex tiles are better. There are good reasons why strategic games (the whole xxx General series for example) have nearly always used hex based maps. After I played something hex based for a longer time and then play something like good old Civilization I really wish Civ had hex based tiles...

Share this post


Link to post
Share on other sites
ahw    263
LOL If you find one true wargame that uses something *else* that hex you can spank me It's because *real* wargames are played by simulationists, and military, to recreate epic conflicts, in the most realistic way possible. And to have a bit of realism, it's nice to at least have realistic movement.
If you use a square grid, the distance from the center of a square to the vertical and horizontal neighbours is 1, fine. But the distance to the diagonal neighbours is ... 1.414, which is bad. Because if units can move in all directions, they actually get an added 41 % movement in diagonals !!! It's a big difference ! In an hexagonal grid, you lose the advantage of having straight line movements (you apparently zigzag, instead), but you get the advantage that all neighbours are equidistant. Which is much better, overall, than having 41% bonus for diagonals...

In a real time game with units moving smoothly, this is not decisive, hence on most computer RTS you don't see any hex grids.
But on paper, most wargames are hex based (I don't know any that isn't) ... or without any form of grid (then you use rulers to measure movements).

As well, hexagonal grids are a pain in the as$ to draw (and to use in general), on a computer, hence the natural popularity of the squares. The diamonds seem to be a bit more popular because of the added depth, but they add problems ... so they are still not very common in RTS.

youpla :-P

(hey ! I just made your project or what ?)

Edited by - ahw on October 8, 2000 3:38:04 PM

Share this post


Link to post
Share on other sites
Null and Void    1088
I have to give in on that Anonymous Poster, I hadn''t seen that, oh well, that is my view on it anyway

I dislike tialing in general, most of my games (none are done though, so that may tell you something ) have very non-linear mapping systems.


Null and Void
"In this house we obey the laws of thermodynamics!" --Homer Simpson

Share this post


Link to post
Share on other sites
epic709    122
Bitmaster: could you please try harder to remember that article you read? It''ll make excellent reference material for my project.

So far the only thing I can see from a design perspective is that hex tiles are "fair" to the discerning strategist. But I''m sure that''s not the end of the story, right? Hope I can get more opinions on this.....

Does anybody know how hex tiles will affect things like how natural the end result is? My opinion is that square tiles are more realistic (when you don''t think about the distance thing) because a sprite would have 8 directions to move about instead of just 6. I remember playing Fallout and how the characters zig-zigged their way from one spot to the next. Does everybody agree with me here?

Share this post


Link to post
Share on other sites
MadKeithV    992
If you don''t have per-tile-movement, the choice is cosmetic. But try this: Implement a random maze map generator based on hexes - with an exit possible through each of the edges. If you generate a map with this system, it will be VERY hard to tell that the original generator was just a set of hexagonal tiles.
( Trust me, I used this technique in my PnP Roleplaying games, and it confused the hell out of my players because they were getting ALL the mapping wrong )


People might not remember what you said, or what you did, but they will always remember how you made them feel.
~ (V)^|) |<é!t|-| ~

Share this post


Link to post
Share on other sites
ahw    263
Ok, if you really wanna know, there is Amit Patel's homepage. Read it, love it

I'll dig my bookmarks to see if I have more.

I support MadKeithV as well : if you are not using tile based movement, then it's purely cosmetic.
Usually, you use hex grids because you are playing a turn based game. Real time games will use something easier to draw, in general.

youpla :-P

====edit====

I'd like to say that yes, movement is of prime importance in wargames, hence the importance of the gridding you use, if any. Hexagonal tiling comes from wargames (paper ones, not computer ones). All wargames I have ever seen are using hex grids, or continuous movement (no grid). If you use square grids, it's probably a board game, not a wargame

Wargamers are very picky people on little details like 41% bonus ... it's like this bug there is in Quake 2 where zigzagging furiously would make you go much faster ... for the reason I explained above.
As well, as explained in Amit Patel's gamepage ... with squares, you get 4 neighbours with a common edge, and 4 with only a common vertex, which is not very ... pleasant.
You'd want to check some games using square grids that don't allow diagonal movements .. ask yourself, why ?


Edited by - ahw on October 10, 2000 5:06:32 AM

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
The original post concerned isometric views, yes?

The diamond tiles used in an isometric veiw are close to hexagon in shape, so using hexagons instead is an option. I think Age of Wonders used this for their city walls. I suppose it can help with depth first calculations since you''d have one axis that corresponds directly with depth.

The only problem that I see is that on one of your axes you have a zig-zag pattern, which means any straight-edged walls will tend to split a hex. If you can take care of the half-hex problem then you''ll be ok.

You could avoid the half-hex problem by making one of the angles very sharp (30 degrees) but I think it would look poor.

Share this post


Link to post
Share on other sites
Chiroptera    122
Okay, we''ll assume that your tiles are discrete, that is you can''t be partially in one tile and partially in another.
Diamond isometric tiles are the same as squares, from a functional point of view. Implementing is a bit tricky, but there''s lots of help for that.

So, the differences. First, consider a fireball that affects a two space radius. If you''re using squares, you have to decide if you count the two spaces as cardinal direction steps, or try to work out an equation, or just affect everything even two diagonal spaces away. Each of these choices gives you a different shape, none of which much resemble a circle. Hexes, on the other hand, require no decision, and no computing. The hexes form concentric rings, which approximate circles a lot better than you can manage with squares.

On the other hand, hexes involve 60 degree angles. Most stuff in life comes in 90 degree angles, at least to a human way of thinking. It''s hard to reconcile these cleanly. If you have two roads, one going north-south, and the other east-west, one of them will either cut across the tiles, sometimes in the middle of a tile, sometimes on an edge, or else the road will have to zigzag NE, SE, NE, SE, etc. which doesn''t look natural.

One idea I''d had is to make a hex based game, but design the artwork such that things are built with six directions in mind, six sides to a building, roads come to 6-way interections, (Well, three more usually, but still..) and so forth...

Share this post


Link to post
Share on other sites
As i understand, the use of hex tiles or hex grids is used to determine the 6 basic directions and sides of individual units. These being:
-front
-front right flank
-front left flank
-rear right flank
-rear left flank
-and rear
Having every unit in games consist of these 6 sides allows for a more correct simulation of movement and actions. The next best option is to calculate everything using lines and pins (vector) although this can become cumbersome very quickly for the user and should only really be used as a last resort unless you can come up with a decent interface.

"So you're the one that designed that game are you?"
*Gulp* "Umm, yeah"

Share this post


Link to post
Share on other sites
epic709    122
Thanx 4 all the input guys! I think I have quite a list of differences right now. But if anybody still hasn't put in his 2 cents, feel free to do so.

I just realized that there are two types of hex tiles: the one described by Paul and the other one is that one rotated 90 degrees resulting in the tile having these 6 sides instead:

-front right flank
-front left flank
-left flank
-right flank
-rear right flank
-rear left flank

The only difference I can tell is that with this one, we zig-zag north and south while with Paul's version we zig-zag east and west. Anybody know of any more differences?

ahw: the only answer I can come up with is that diagonal movement would be unfair because you would move further in the same amount of steps as you would be moving along the hypothenus which is always longer than the horizontal and vertical sides. back to square one it seems...is this a trick question?

p/s: this is the longest thread I've ever got going since I joined GameDev. Help me make it longer!

Edited by - epic709 on October 13, 2000 3:26:00 PM

Edited by - epic709 on October 13, 2000 3:28:57 PM

Share this post


Link to post
Share on other sites
One other thing your bound to work out is that with larger critters two hextiles are usually used. This allows for more people to attack it by it''s larger surface area. although you''ll still have to work out how they move through hextiles. I used to use hexs when i DM''ed D&D for displaying party order, it works very neatly.

You might also be able to find a use for the diagonals in hextiles. I used them in D&D for pole weapons, this way you can calculate when someone''s too close to be hit by one.

"So you're the one that designed that game are you?"
*Gulp* "Umm, yeah"

Share this post


Link to post
Share on other sites
danbrown    255
In reply to Chiroptera, even if your movement is discrete there is no reason that damage/distance checks should be. Why not use the distance between the tile centers as an analogue value, so your fireball would do maximum damage in it''s own cell, and minimum damage at a certain radius. This way no-one gets an advantage by being on a diagonal, even with square tiles.

Personally, I wouldn''t use discrete values anyway, just using tiles (hex or square) to represent the environment. An example of a game that does this well is Dungeon Keeper, during fights creatures will crowd in a circle around the foe, but rooms are built using square tiles. It would have worked just as well with a hex map without affecting gameplay at all (apart from not being able to build straight bridges ).

Seeya,

Dan

Share this post


Link to post
Share on other sites
Skult    122
Hmmm... Well...

I''m not right sure at the moment, but - with diamonds - isn''t it possible to make units move 41% slower when moving diagonally?

Share this post


Link to post
Share on other sites
Guest Anonymous Poster   
Guest Anonymous Poster
You can simply choose not to have per-tile-movement and make accurate movement instead. I think it could work in a strategy game also (gimme one reason why not).

Or then you can have time value for each unit telling how much it can move per turn. And just substract 1.414 from it when moving diagonally.

Share this post


Link to post
Share on other sites