PathEngine home | previous: | next: |
Flags a specified agent as excluded from the context collision state, without invalidating cached state data.
void temporarilyIgnoreAgent(iAgent& agent); |
agent | The agent to ignore, which must currently be included in the context. |
The main use case for this method is to nest queries inside matching calls to
For example, this can be useful to prevent a target agent's collision shape from blocking queries made by an attacking agent.
The 'temporarily' in the name of this method refers to this most common expected use-case for the
method, but there is no actual 'time limit' for ignoring agents in this way.
Agents should not be removed from the context whilst flagged as temporarily ignored, however,
and the mechanism is designed for ignoring relatively small numbers of agents and so it may not be efficient
to mark a lot of agents as ignored in this way.
Note that temporarily ignored agents are still considered to be 'included' in the context,
(e.g. for iteration with
Note, also, that this method relates specifically to the agent as included directly in the collision context
on which the method is called,
and does not affect any obstacle sets which are added 'underneath' the collision context.
(If the agent being ignored is also added to such an obstacle set
then marking the agent as ignored in the collision context will not prevent the agent
from affecting collision and pathfinding state.)
void temporarilyIgnoreAgent(Agent agent); |
Documentation for PathEngine release 6.04 - Copyright © 2002-2024 PathEngine | next: |