0

I wanted to change the state of the agent(s) by a cyclic event(reset) as shown. What command should I used to trigger the transition(resetHome) every 24hrs after the first initial 12 hours?

Maëlan
  • 3,586
  • 1
  • 15
  • 35

1 Answers1

0

Switch it to a msg-based transition, set the expected keyword to "myTrigger" (or whatever you like).

In the event, write DeliveryAddressStaechart.fireEvent("MyTrigger");

This will trigger the transition if (and only if) is in the DefaultHomeAddress state.

PS: You should never use condition-based transitions, not good practice

Benjamin
  • 10,603
  • 3
  • 16
  • 28