Adding a QTime variable (simulatedTime) is easy. That parameter is incremented by one for every tick, and a signal is sent.
Finally, the corresponding label is updated.
For every tick, the time is incremented by one second.
When running the program in test mode, there is no listener to the signals. This won't cause any crashes.
In the next blog post, I'll review the trafficClock objects. I hope that I'll be able to connect the signal directly fom trafficClock to trafficControl.
No comments:
Post a Comment