public static boolean run_tick() {
    Sim_entity  ent;
    int num_started;
    boolean queue_empty;
    num_started = 0;
    int entities_size = entities.size();
    for (int i=0; i < entities_size; i++) {
      ent = (Sim_entity)entities.get(i);
      if (ent.get_state() == Sim_entity.RUNNABLE) {
	ent.restart();
	num_started++;
      }
    }
    // Wait for them all to halt
    for (int i=0; i<num_started; i++) {
      onestopped.p();
    }
    // Give everything else a chance
    if (simThread != null) {
      try { simThread.sleep(5); }
      catch(InterruptedException except) {}
    }
    // If there are more future events then deal with them
    if (future.size() > 0) {
      queue_empty = false;
      Sim_event first = future.pop();
      process_event(first);
      // Check if next events are at same time...
      boolean trymore = (future.size()>0);
      while (trymore) {
	Sim_event next = future.top();
	if (next.event_time() == first.event_time()) {
	  process_event(future.pop());
	  trymore = (future.size()>0);
	} else trymore = false;
      }
    } else {
      queue_empty = true;
      running = false;
      print_message("Sim_system: No more future events");
    }
    return queue_empty;
  }