a_star 0.1.1

  • README.md
  • Installing
  • Versions
  • --

A* path finding with Dart #

A simple A* algorithm implemented in Dart. An example of path finding.

Last updated 2013-10.

No effort has been made to optimize this. Ported from [http://46dogs.blogspot.com/2009/10/star-pathroute-finding-javascript-code.html].

See LICENSE file for license details.

See running example at http://sethladd.github.io/dart-a-star/deploy/

Example #

import 'package:a_star/a_star.dart';
main() {
  String textMap = """
        sooooooo
        oxxxxxoo
        oxxoxooo
        oxoogxxx      
        """;
  Maze maze = new Maze.parse(textMap);
  Queue<Tile> solution = aStar(maze);
}

Reporting bugs #

Please file bugs at https://github.com/sethladd/dart-a-star/issues

Use this package as a library

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  a_star: ^0.1.1

2. Install it

You can install packages from the command line:

with pub:


$ pub get

Alternatively, your editor might support pub get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:a_star/a_star.dart';
  
Version Uploaded Documentation Archive
0.3.0 Nov 6, 2013 Go to the documentation of a_star 0.3.0 Download a_star 0.3.0 archive
0.2.0 Oct 14, 2013 Go to the documentation of a_star 0.2.0 Download a_star 0.2.0 archive
0.1.1 Oct 7, 2013 Go to the documentation of a_star 0.1.1 Download a_star 0.1.1 archive
0.1.0 Oct 7, 2013 Go to the documentation of a_star 0.1.0 Download a_star 0.1.0 archive
Awaiting analysis to complete.