My own attempt at pathfinding

Also added Nix's pathfinding code.