November 20th, 2007

mal burns, author


LSL pathfinding in Second Life. The pathfinding script stores the distance from each point to the exit as 2 hex digits in a string. Agents query the pathfinding script to ask where to move. Squares tell the pathfinding script that they've become an obstacle when they're clicked on. The pathfinding sets the distance from the obstacle to FF and then updates the squares around it. If any of these squares are updated, the update region expands and more squares are updated.