Difference between revisions of "Event Recorder"

From ScummVM :: Wiki
Jump to navigation Jump to search
(Created page with "Event recorder is a tool for regression testing of game engines. It is used to record gameplay and play it back after engine update, to find does new version of engine works as p...")
 
(5 intermediate revisions by 2 users not shown)
Line 1: Line 1:
Event recorder is a tool for regression testing of game engines. It is used to record gameplay and play it back after engine update, to find does new version of engine works as previous. Record and playback process may be started from command line or from GUI.  
Event Recorder is a tool for regression testing of game engines. It is used to record gameplays and to play them back after engine updates, to verify that the new engine version works the same. Record and playback processes may be started from the command line or from the GUI.


==Command line parameters==
==Command line parameters==
<pre>
--record-mode sets the mode the event recorder will be started with. Possible values are:
record: begin gameplay recording
playback: play back gameplay from previously created file
info: output information about the previously created record file to the console in machine readable format


--record-mode sets in what mode event recorder will be runned. Possible values is
    record: begin gameplay recording
    playback: playback gameplay from previously created file
    info: output to console information about previously created record file in machine readable format
--record-file-name name of file to record or playback from.
--record-file-name name of file to record or playback from.


--disable-display disable creation of sdl window and outputing of sdl context to screen. In playback mode output information of playback in machine-readable format to console.  
--disable-display disable creation of SDL window and SDL context to screen. In playback mode, output information of playback in machine-readable format to console.
</pre>


==Recorder dialog==
==Recorder dialog==
It is used to manage record files, start recording and playback. To open the recorder dialog you need to press shift in the launcher to show the alternative menu. After this you need to press the "Record..." button.
There is a list of gameplay records in the recorder dialog. After choosing one of them, some information about the record will appear in the right window. It includes the author's name and notes about the record (optionally).
There are a few buttons under that list. Their functions:


It is used to manage records files, start recording and playback. To open recorder dialog you need to press shift in launcher to show alternative menu. After this you need to press "Record..." button.
'''Edit''' - shows dialog to change information of selected record  (display name, author and record notes)
There is a list of gameplay records in recorder dialog. After choosing one of them, info about record will apear in right window. It includes author's name and notes about the record (optionally).
There are few buttons under that list. Their functions:
 
'''Edit''' - shows dialog to change information of selected record  (diaplay name, author and record notes)


'''Delete''' - remove selected record from filesystem
'''Delete''' - remove selected record from filesystem
Line 23: Line 24:
'''Cancel''' - return to launcher
'''Cancel''' - return to launcher


'''Record''' - start event recorder in recording mode
'''Record''' - start Event Recorder in recording mode


'''Playback''' - start event recorder in playback mode
'''Playback''' - start Event Recorder in playback mode


==Control window==
It is used to control the process of recording or playback and has different functions on these modes. It overlays the game screen and can be dragged.


==Control window==
It is used to control process of recording or playback and have different functions on this modes. It overlays the game screen and can be dragged.
===Playback functions:===
===Playback functions:===
'''Stop:''' halt playback and return to launcher
'''Stop:''' halt playback and return to launcher


'''Switch to game:''' halt recording and play in normal mode
'''Switch to game:''' halt recording and play in normal mode


'''Fast forward:''' remove all delays and playback as fast as possible
'''Fast forward:''' remove all delays and play it back as fast as possible


''Remark: in playback mode events recorder block all user input. To use control window you should press Ctrl+P to set pause in game''
''Remark: in playback mode the Event Recorder blocks all user input. To use the control window you should press Ctrl+P to pause the game''


===Record functions:===
===Record functions:===
'''Stop:''' halt recording and return to launcher
'''Edit notes:''' change info about the record (display name, author and notes)
==Todo==
==Known Issues==
* GUI dialogs are not visible during playback/recording.
'''How to reproduce''': Record any game and try to open up the GMM, it will not be visible.
* Events happening while the GUI is open are not recorded.
This is an issue for games which rely on our GUI (like for example Hugo). It will also break automated testing when the GUI was opened while recording (like for example the pause dialog in SCUMM games). The reason here is that you will have to close the GUI manually on playback because the user events leading to closing of the GUI are not recorded.
'''How to reproduce''': Record any game, bring up the GMM and close it by pressing ESC. Stop recording. Play the recording file. You will notice after the GMM is opened the recording will stay paused.
* Brining up the pause dialog in SCUMM games (like Monkey Island 2) cannot be reliably done.
'''How to reproduce''': Record a SCUMM game (like Monkey Island 2). Press space. You will notice that the pause dialog closes immediately most of the time.
(Right now you can check whether the dialog is open by checking whether the record timer in the top left is paused). This does not happen in normal play.


'''Stop:''' halt recording and return to launcher
* Audio callback sometimes not/very slowly called while recording(?)
 
'''How to reproduce''': Start Monkey Island 1 CD. Watch the whole intro sequence. Return to launcher. Start recording of Monkey Island 1 CD. You will notice that the LucasFilm logo is displayed for a long time.
 
'''Further notes''': The really oddity here is that when playing the recording everything seems to work and the logo's animation is played at normal timings. This causes the recording and playback to become out of sync (you can notice that because the screenshots taken differ and the recorder warns about it). A recording made by the procedure above can be obtained [http://lordhoto.users.sourceforge.net/monkeycd.r08 here] (recording was stopped after 42 minutes while the "Part One" screen was visible).
 
* Recorder GUI does not work on playback
 
This behavior is documented but at the very least confusing.
 
'''How to reproduce''': Play a recording. Try to press a button of the GUI in the top left. It will not work.
 
* Recorder GUI hides part of the screen


'''Edit notes:''' change info about record (display name, author and notes)
This is especially annoying in old SCUMM games where the dialog lines are shown at the top of the screen.


==Todo:==
'''How to reproduce''': Record/play a recording in for example Indy3. The GUI will make it impossible to read the beginning of the dialog lines.
** ''Sev: Recorder dialog could be dragged anywhere on the screen.''

Revision as of 19:16, 5 July 2013

Event Recorder is a tool for regression testing of game engines. It is used to record gameplays and to play them back after engine updates, to verify that the new engine version works the same. Record and playback processes may be started from the command line or from the GUI.

Command line parameters

--record-mode sets the mode the event recorder will be started with. Possible values are:
	record: begin gameplay recording
	playback: play back gameplay from previously created file
	info: output information about the previously created record file to the console in machine readable format

--record-file-name name of file to record or playback from.

--disable-display disable creation of SDL window and SDL context to screen. In playback mode, output information of playback in machine-readable format to console.

Recorder dialog

It is used to manage record files, start recording and playback. To open the recorder dialog you need to press shift in the launcher to show the alternative menu. After this you need to press the "Record..." button. There is a list of gameplay records in the recorder dialog. After choosing one of them, some information about the record will appear in the right window. It includes the author's name and notes about the record (optionally). There are a few buttons under that list. Their functions:

Edit - shows dialog to change information of selected record (display name, author and record notes)

Delete - remove selected record from filesystem

Cancel - return to launcher

Record - start Event Recorder in recording mode

Playback - start Event Recorder in playback mode

Control window

It is used to control the process of recording or playback and has different functions on these modes. It overlays the game screen and can be dragged.

Playback functions:

Stop: halt playback and return to launcher

Switch to game: halt recording and play in normal mode

Fast forward: remove all delays and play it back as fast as possible

Remark: in playback mode the Event Recorder blocks all user input. To use the control window you should press Ctrl+P to pause the game

Record functions:

Stop: halt recording and return to launcher

Edit notes: change info about the record (display name, author and notes)

Todo

Known Issues

  • GUI dialogs are not visible during playback/recording.

How to reproduce: Record any game and try to open up the GMM, it will not be visible.

  • Events happening while the GUI is open are not recorded.

This is an issue for games which rely on our GUI (like for example Hugo). It will also break automated testing when the GUI was opened while recording (like for example the pause dialog in SCUMM games). The reason here is that you will have to close the GUI manually on playback because the user events leading to closing of the GUI are not recorded.

How to reproduce: Record any game, bring up the GMM and close it by pressing ESC. Stop recording. Play the recording file. You will notice after the GMM is opened the recording will stay paused.

  • Brining up the pause dialog in SCUMM games (like Monkey Island 2) cannot be reliably done.

How to reproduce: Record a SCUMM game (like Monkey Island 2). Press space. You will notice that the pause dialog closes immediately most of the time. (Right now you can check whether the dialog is open by checking whether the record timer in the top left is paused). This does not happen in normal play.

  • Audio callback sometimes not/very slowly called while recording(?)

How to reproduce: Start Monkey Island 1 CD. Watch the whole intro sequence. Return to launcher. Start recording of Monkey Island 1 CD. You will notice that the LucasFilm logo is displayed for a long time.

Further notes: The really oddity here is that when playing the recording everything seems to work and the logo's animation is played at normal timings. This causes the recording and playback to become out of sync (you can notice that because the screenshots taken differ and the recorder warns about it). A recording made by the procedure above can be obtained here (recording was stopped after 42 minutes while the "Part One" screen was visible).

  • Recorder GUI does not work on playback

This behavior is documented but at the very least confusing.

How to reproduce: Play a recording. Try to press a button of the GUI in the top left. It will not work.

  • Recorder GUI hides part of the screen

This is especially annoying in old SCUMM games where the dialog lines are shown at the top of the screen.

How to reproduce: Record/play a recording in for example Indy3. The GUI will make it impossible to read the beginning of the dialog lines.

    • Sev: Recorder dialog could be dragged anywhere on the screen.