Sign in to follow this  

Isometric Zoning Math

Recommended Posts

The following screenshot is a Isometric Grid. What I want to do is be able to find out what zone each tile is in. So based upon the screenshot what math equation do I use to determine what zone a tile is in given the x,y coordinate?

Share this post

Link to post
Share on other sites

Your top row on that picture is wrong 5:24 should be 5:23

That could be a starting place to at least identify the Y
count of a systemaic cartesoan system of zones (stepping by
8 from the origin.

Likewise the X coordinates step by 4 across each zone.

If you organized the zone identifiers via a number system
then the ZONE address of any point would be:

ZX = (int)tilex / 4 (assumes rounding down to 0 for full fraction range)
ZY = (int)tiley / 8

This could then be combined into a single value

ZID = (ZX * YZONECOUNT) + ZY // YZONECOUNT being count of Y zone size of world

I prefer a Y major system but thats just a preference.

Share this post

Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this