I made hexagon-grid based tile engine for remake of certain board game while ago(and forgot about it).
recently I rewrote whole thing again.
it's far from finished, but it's functioning enough to make walking demo.
click anywhere on the map and ChangeV will walk to that tile.
you can toggle unpassable wall with right mouse button.
added non-stop walking NPC.
added ChangeV as controllable character.
download ver.6a (added scrolling camera):
http://www.changevworld.com/jawsvsoft/e ... mo_v6a.zip
credit:
A* path finding routine.
I used info/sample from
http://www.policyalmanac.org/games/aStarTutorial.htm
and coderJeff's example
http://www.freebasic.net/forum/viewtopic.php?t=9952
I removed all pointer access and replaced them with array index and added more stuff and calculation.
It's not optimized, but it is working.
I reused graphics from my old board game.
hexagon board walking demo.
hexagon board walking demo.
Last edited by ChangeV on Jul 29, 2010 2:41, edited 5 times in total.