map[i][v] == '-') {
        cellWeight = 1;
      } else if (this.map[i][v] == 'r') {
        cellWeight = 3;
      }

      ...

      graph[graph.length - 1].push(cellWeight);

    }
  }

  this.graph = new Graph(graph);
}
            </code></pre>
          </section>

          <section>
            <h2>Pedestrian path detection</h2>
            <pre><code>
getRoute(startX, startY) {
  let nextNode;

  while (!nextNode) {
    let rX = ~~(Math.random() * this.engine.map.length);
    let rY = ~~(Math.rand