PathEngine home previous: iObstacleSet::size()next: iObstacleSet::updateConnectedRegionPreprocessFor()
Contents, API Reference, Interfaces, iObstacleSet, temporarilyIgnoreAgent

iObstacleSet::temporarilyIgnoreAgent()

Description

Flags a specified agent as excluded from the obstacle set collision state, without invalidating cached state data.

Syntax

void temporarilyIgnoreAgent(iAgent* agent);

Parameters

agent The agent to ignore, which must currently be included in the obstacle set.

Remarks

The main use case for this method is to nest queries inside matching calls to iObstacleSet::temporarilyIgnoreAgent() and iObstacleSet::restoreTemporarilyIgnoredAgent(), for agents that need to be temporarily excluded from the query state.

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 obstacle set 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 obstacle set, (e.g. for iteration with iObstacleSet::getAgent(), testbed rendering, and so on), and are also not excluded when burning a collision context into the base mesh (with iMesh::burnContextIntoMesh()).

Temporarily ignoring agents is not currently supported on obstacle sets that are created with the 'markForPreprocessing' creation attribute.

See Also

iCollisionContext::temporarilyIgnoreAgent()

C# Mapping

void temporarilyIgnoreAgent(Agent agent);

Java Mapping

void temporarilyIgnoreAgent(Agent agent);

Documentation for PathEngine release 6.00 - Copyright © 2002-2016 PathEnginenext: iObstacleSet::updateConnectedRegionPreprocessFor()