public void next() {
		if (!hasNext()) { return; }

		synchronized(model) {		
			// generate a new round:
			if (cursor == history.size()) {

				//long startTime = System.currentTimeMillis();
				List<Action> round = nextRound();
				for(Action action : model.cleanup()) {
					action.apply();
					round.add(action);
				}
				history.add(round);
				//long endTime = System.currentTimeMillis();
				//System.out.format("Elapsed agent time: %d%n", endTime - startTime);

				Map<Annotation, Agent> annotations = new HashMap<Annotation, Agent>();
				for(Agent agent : agents) {
					if (agent instanceof Annotated) {
						for(Annotation a : ((Annotated)agent).annotations()) {
							annotations.put(a, agent);
						}
					}
				}
				footnotes.add(annotations);
				cursor =  history.size();
				return;
			}

			// replay a historical round:
			List<Action> actions = history.get(cursor);
			for(int x = 0; x < actions.size(); x++) {
				actions.get(x).apply();
			}
			cursor++;
		}
	}