-
Re: Square Isogrid?!
The angle is irrelevant here. The problem is with the coordinate system.
http://usera.ImageCave.com/adamhawker/isogrids.png
(the image has been resized automatically - right click, and select "open image" to view full size).
The grey rectangle represents the part of the map that the player will be able to see (obviously a computer screen is rectangular, and the OP is saying he doesn't want any blank space visible around the map).
If you're loading your map data from an array, a large portion of that array will be empty - as you can see from all those white squares.
Using a different coordinate system results in fewer blank spaces, and a smaller array.
However, I would not recommend this method, as it's a pain to do the maths for things like detecting which cell the mouse is overlapping.
-
Re: Square Isogrid?!
Nothing from alphabeta279 but this seems 'normal' enough.
I am working on such a thing (hence my inserts here) and just over-drew the grid.
I have a scrolling window and used your first img where the grey area represents the full area - 2000x2000
It works fine. I hadn't thought that IsoGrid's array would be significantly bigger. I have had one 'wonk' where at the start of the level the car (player) is very slow in the top-left area. Once it is out speed is fine. It is intermittent so I just figured it was me with too many apps open - or something local.
Any thoughts of resource consumption with the bigger array?
-
Re: Square Isogrid?!
Hi all, Muddymole is spot on and his diagram describes perfectly - to the best of my knowledge the isogrid only allows the rotated grid option, not the 'staggered grid'.
On top of the array size inefficiencies there are also implications for the code required - eg if I wanted to map the mouse to a square grid covering a certain region of the screen, then snap the cursor to the nearest cell, then if my grid size is as per his 'staggered grid' example it'll just work.
If however it is like the Rotated grid I need to manually create events like 'snap to grid if x columns is < 3 and y < 4', so it does become quite inefficient.