SHOW:
|
|
- or go back to the newest paste.
1 | float ox = x * (float)Geometry.MapHexWidth; | |
2 | float oy = y * (float)Geometry.MapHexHeight; | |
3 | xcoord = (oy - ox) - proto.OffsetX; | |
4 | ycoord = ((cy + (cx / 2)) * Geometry.MapHexLineHeight) - proto.OffsetY; | |
5 | ||
6 | if (!(y == 0 && x == 0)) | |
7 | { | |
8 | if (x % 2 == 1) | |
9 | { | |
10 | - | ycoord -= 6; |
10 | + | ycoord -= Geometry.MapHexLineHeight/2; |
11 | } | |
12 | if (x > 1) | |
13 | { | |
14 | xcoord += (x/2)*Geometry.MapHexHeight; | |
15 | } | |
16 | } | |
17 | ||
18 | // Offset when drawing stuff... this is probably wrong... | |
19 | xcoord -= (Bitmaps[scenery].Width) | |
20 | ycoord -= (Bitmaps[scenery].Height) |