Fixing missing variable declaration.
Moving replay.py to scripts/
Fix incorrect reference to opts.terminate_on_error