Do a static cast when calling follow in Astar::FindPath
commite017c9febe84336c23302d9d8a6a87b4971ebdd1
authorcirdan <cirdansw@gmail.com>
Mon, 27 Jan 2014 20:55:53 +0000 (27 21:55 +0100)
committercirdan <cirdansw@gmail.com>
Mon, 27 Jan 2014 20:55:53 +0000 (27 21:55 +0100)
tree975db3726b236e50300a7bf7e809b9487b3e619a
parent73f61ae505987725e52183ec380fce6fbe52da97
Do a static cast when calling follow in Astar::FindPath

Astar::FindPath is likely to be called with a follow function
that does not take the Astar struct itself as first argument,
but a derived class, since a pathfinder will often want to add
custom functionality to Astar. Make the call to follow perform a
static cast on this to the expected type, to make things easier
for the caller.
src/pathfinder/yapf/astar.hpp