I need to know the syntax for FlexScript in order to extract the AGV (task executor) that is allocated to a control point.
What I am trying to do is have a blocking AGV that is causing another AGV to become blocked get redirected to another control point, so the blocked AGV can continue. I attempted the Agent Proximity method, and this worked well, until a situation occurred where the proximity radius inadvertently redirected the incorrect AGV due to the radius size and a nearby parallel path. (in the attached model AGV1, AGV2, and TaskExecutor1 are using this method)
So, I am attempting a different way, where when an AGV enters the blocked state it tries to get the AGV that is on the control point that is centerport connected to the control point that the AGV became blocked on. Then the AGV on that next control point needs to get redirected to a pre-defined control point further in the network.
There is a picture attached, and specifically from that picture I am trying to extract AGV4 so I can then apply the "redirect method" to redirect AGV4 to a further control point (ControlPoint12), so AGV3 can get to ControlPoint11. AGV4.redirect(redirectCP,REDIRECT_AND_WAIT);