Nearest
class Nearest<T>(environment: Euclidean2DEnvironment<T>, pedestrian: Pedestrian2D<T>) : Filtered<T, Euclidean2DPosition>
Content copied to clipboard
Filtered strategy considering only the group steering action and the non-group steering action whose targets are nearest to the pedestrian's position. The two actions are combined using DistanceWeighted strategy.
Parameters
environment
the environment in which the pedestrian moves.
Content copied to clipboard
pedestrian
the owner of the steering action this strategy belongs to.
Content copied to clipboard
Constructors
Link copied to clipboard
fun <T> Nearest(environment: Euclidean2DEnvironment<T>, pedestrian: Pedestrian2D<T>)
Content copied to clipboard
Functions
Link copied to clipboard
open override fun computeNextPosition(actions: List<SteeringAction<T, Euclidean2DPosition>>): Euclidean2DPosition
Content copied to clipboard
Link copied to clipboard
open override fun computeTarget(actions: List<SteeringAction<T, Euclidean2DPosition>>): Euclidean2DPosition
Content copied to clipboard
Computes the target to reach starting from the steering actions the pedestrian obey to, in absolute coordinates.