You can probably make use of the 'stopped' method of the World class. It is called on the currently active world automatically when the scenario goes from a running state to a stopped state.
You can probably make use of the 'stopped' method of the World class. It is called on the currently active world automatically when the scenario goes from a running state to a stopped state.
The stopped method in the world class returns void, so I can't use it in an if statement, but I don't know of any other way to call a method under a certain condition. Any ideas?