Add concept of time.

Now instead of only doing actions every n seconds for all objects, each actor
has its own internal concept of time. The act method takes the current time in
and decides whether to take actions based on that.