Sunday, March 6, 2011

DotNetFish - Horseshoes and Hand Grenades

I've been able to make a little progress this weekend. To start with, I changed the datatype of the edge points from a Point, to a list of bytes. This was necessary because eventually you might see tiles that have mroe than two edge points, and it was also needed for the next change I made, which was the edge tile will now check the surrounding tiles to see if they have any edges it needs to line up with.

This change makes the map look quite a bit better, as most of the tiles connect properly. However, I still have quite a few tiles that are showing up as an error tile. This is where the old saying that close only counts in horseshoes and hand grenades. I'm close, but that's not good enough for me. I really would like to have 99.999% of the tiles be correct. This calls for me to implement one final feature of the generator process, and that is pathfinding.  Here is what I plan to do


  1. Go to the next error tile
  2. Check to see if this error tile is actually an edge tile, if not then set it to water or land
  3. If it is an edge tile, find a path from the edge connector around it to the closest edge tile that has an open edge. 
  4. Convert the tiles along the path into edge tiles 

Before                           After


Orange Tiles are Edge Tiles, Red lines are edge connection points


I ran a test this morning, and I think that this is the last large change I need to make in order to get the map looking good.

I also sat down for a few minutes, and thought a bit about the road map for release .01 and release .02. I made a significant change to .01, in that I moved the ability to cast for fish into .02. I did this because there is a whole host of logic that needs to be implemented related to casting, such as fish and their behavior, lake depth, etc. I'd rather be able to get .01 out without those features.

No comments:

Post a Comment