- break_tester = make_turn_tester(opts.replay, world_db)
- obey_lines_in_file(io_db["path_record"], "record ", break_tester)
- # what to do next?
+ file = open(io_db["path_record"], "r")
+ prefix = "record file line "
+ line_n = 1
+ while world_db["turn"] < opts.replay:
+ server_test(io_db)
+ obey(file.readline().rstrip(), io_db, prefix + str(line_n))
+ line_n = line_n + 1
+ world_db["turn"] = world_db["turn"] + 1
+ while io_loop():
+ server_test(io_db)
+ obey(file.readline().rstrip(), io_db, prefix + str(line_n))
+ line_n = line_n + 1
+ file.close()