Under the earth, a stallion prays for death that will not come.
Ever see a heuristic-based pathfinding algorithm at work? It's surprisingly similar to story-planning.