chiark / gitweb /
Revamp the triangular grid generation in Loopy, which I've been
authorSimon Tatham <anakin@pobox.com>
Thu, 11 Apr 2013 12:51:05 +0000 (12:51 +0000)
committerSimon Tatham <anakin@pobox.com>
Thu, 11 Apr 2013 12:51:05 +0000 (12:51 +0000)
commited82ef5c0e74de5ef743e61aebad59b2acea7a49
tree442f3ed9b6ce49d72c05ad73bd1fa37540f0db6e
parent8cfcbac02795801b712e16492bbfeead35896b0c
Revamp the triangular grid generation in Loopy, which I've been
meaning to revisit for a while. The new version generates more nicely
symmetric grids (best at even heights, but still improved even at odd
heights), and avoids any 'ears' on the grid (triangles at the corners
connected to only one other triangle, which tend to be boringly easy
places to start solving).

I've reused the grid-description-string mechanism invented for the
Penrose tilings as a versioning mechanism for the triangular grids, so
that old game descriptions should still be valid, and new triangular-
grid game descriptions begin with an "0_" prefix to indicate that they
are based on the new-style construction.

[originally from svn r9824]
grid.c