Simple tile-based pathfinding, useful for enemies, because it finds a path throughout the whole map, so rather than creating and storing a path for each enemy, you can just tell it where to go based on its location.
I wrote this myself. Use with credit. (I do my tilemaps where the upper left is 1, and reading like a book on)