Advertisement

Dang roving objects in iso get lost..

Started by January 06, 2000 08:20 PM
0 comments, last by Sphet 24 years, 11 months ago
Ok.. so I''m working with diamond tiles for the time being and have them drawing just great -- I am drawing left to right, top to bottom. I can drop trees, walls, everything on them and it works great. The problem comes when I have an object moving around. If I move from two tiles adjacent to one another, as the object moves it begins to get clipped by the drawing of the ground plane on the next row down. I suppose I could move the object''s tile location to the lower row, but the calculations to do that would be problematic. Am I thinking this wrong? Should I be drawing ALL the ground plane first, then drawing ALL the next layer, then ALL the objects? I would have liked to draw all the tiles at a certain x,y position, then move on, instead of having to do multiple for loops. Am I missing something here? .. I suppose I could put an objects x/y offsets into the mouse map routine and then change it''s tile location based on that result, but .. hmm. Square tiles sound pretty good here but would still present some problems with having to do bounds checking before moving into a new tile location.. Any ideas?! Or am I fooling myself if I think I can do all my drawing in one pass. Also, do I draw from left to right, top to bottom, or should I be doing right to left top to bottom?
It sounds like you are drawing using rectangular coordinates. That''ll make your tiles overlap others as they are drawn downwards.

Instead, for sprites and such, draw them with an offset of the current map section you are drawing in iso-coordinates - not rectangular.

I suggest you offset all sprites from the bottom middle of the tile, with x going up and left from that point, and y going up and right. Never use just left or just right.
Does that make sense? If it doesn''t - blame the margarita''s - I had to fill up for my b-day!

You''re doing it right from left to right, top to bottom.





Jim Adams
Game-Designer/Author
tcm@pobox.com
http://www.lightbefallen.com
http://www.basicelectronics.com

This topic is closed to new replies.

Advertisement