How can I make the interaction of the a statechart and a flowchart in anylogic?

83 Views Asked by At

I have 5 restaurants in my model and I want to simulate the impatience of clients in a specific queue,in order to lead the agent to another queue if the ServiceTimeRestaurant1 > MaxWaitingTime (variables that I create). I create these variables in Main and did the statechart in my agent page. But I can´t visualize that in the animation, probably because i was not able to create connections between the agent statechart and the flowchart.

Thank for all the help!

[![enter image description here](enter image description here)](https://i.stack.imgur.com/ghjFf.png)

I tried to, somehow, creat a connection, but I did not know who to use it correctly. I also don not know if it the best way to do that.

1

There are 1 best solutions below

0
Felipe On

one thing that is wrong with your code, which is all i can help you with is that

you should do

if(Boolean_mcDonalds == false) 

note that i used "==" instead of "="

maybe that will help... the rest is unknown

also you might probably do else if

if(something){

}else if(something else){

}