Yashar Ahmadov
Yashar Ahmadov

Reputation: 1636

AnyLogic Car library: Is there a way of checking if a route exists for a given destination?

I am using AnyLogic car library and have multiple roads and parking lots. However, not every parking slip is accessible from every road. I want to detect this beforehand if the car won't be able to make it to the destination and send them to somewhere else.

Currently when the car enters the carMoveTo37 block, it throws an error if there is no way of reaching the destination.

enter image description here

Is there any way of checking this before entering the carMoveTo block?

Upvotes: 0

Views: 132

Answers (1)

Benjamin
Benjamin

Reputation: 12803

Yes, you can simply use the bottom out-port as per the help: enter image description here

So simply reroute those cars via that port or do something else with them :)

Upvotes: 1

Related Questions