Archived

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

Dickens

How to sort object drawing order when it is larger than the size of tile

Recommended Posts

Dickens    122
I am new in game developing, I have read the tut about isometric drawing in the gamedev.net however, all sprite is limited to the size of a tile (said 32 x 32), can anyone tell me if there is any method that can sort objects with much larger size said 256 x 256 or even 600 x 600 (said a castle). so that I can have a correct drawing order. Thks a lot.

Share this post


Link to post
Share on other sites
krez    443
i''m sure you could work that out, but why not just use several tiles for these large things?
draw your castle, and divide it into 32x32 chunks, then you problem is solved. plus, you can then make different castles based on te castle-part tiles you already have.

--- krez (krezisback@aol.com)

Share this post


Link to post
Share on other sites
Dickens    122
kerz:

Thanks for your suggestion, but not only the castle, the player and the monster in the game is also in a size of approx. 256 pixel, so if I cut it to small part, I need to cut all moving object to small size (said 32 pixel, such I need to draw 8 time to finish an object), therefore, I am still looking for methods that Interleaving large actors in Isometric environments.

Any suggestion?

Share this post


Link to post
Share on other sites
Thathmew    122
Assign each object has a rectangular footprint. This being the approximate area it covers if you are looking straight down from above it.
If you can assign each object such a rectangle, then you can relatively easily sort by these rectangles. You can also use them for collision detection, blocking, pathing, etc...
Since you''re operating with and isometric view only two edges of a rectangle face the camera. So when comparing two objects if either front edge of an object is in front of the correspond edge of the other object it is in front.
Hope this helps.
-m






mat williams
Lead Programmer, Designer
Zero Sum Software
www.zero-sum.com

Share this post


Link to post
Share on other sites