22 if (event.
time <= 0.0)
30 if (event.
time <= 0.0) {
39 event.check_for_trafficlight =
false;
43 auto state =
event.actor->GetState();
54 direction.
x = crosswalkEnd.
x - currentUnrealPos.
x;
55 direction.
y = crosswalkEnd.
y - currentUnrealPos.
y;
56 direction.
z = crosswalkEnd.
z - currentUnrealPos.
z;
bool check_for_trafficlight
event to wait for a while
bool GetWalkerPosition(ActorId id, carla::geom::Location &location)
get the walker current location
void PauseAgent(ActorId id, bool pause)
set an agent as paused for the crowd
This file contains definitions of common data structures used in traffic manager. ...
EventResult
result of an event
bool HasVehicleNear(ActorId id, float distance, carla::geom::Location direction)
return if the agent has a vehicle near (as neighbour)
EventResult operator()(WalkerEventIgnore &event)
Navigation * GetNavigation()
return the navigation object
SharedPtr< carla::client::TrafficLight > GetTrafficLightAffecting(carla::geom::Location UnrealPos, float max_distance=-1.0f)
return the trafficlight affecting that position
event to pause and check for near vehicles
bool GetWalkerCrosswalkEnd(ActorId id, carla::geom::Location &location)
get the point in the route that end current crosswalk
empty event that just ignores
SharedPtr< carla::client::TrafficLight > actor