Game Development Reference
In-Depth Information
Keys —> “[Esc][Esc][Esc]�?, 0.0, 1.04, 1.07......................Result: Success
MouseClick —> 540, 396, INTEL, LEFT, 19.59......................Result: Success
CompareScreen —> “Region 1�?.....................................Result: Failure
MouseClick —> 216, 406, INTEL, LEFT, 0.0........................Result: Success
MouseDoubleClick —> 216, 406, INTEL, LEFT, 0.5..................Result: Success
MouseDoubleClick —> 216, 406, INTEL, LEFT, 0.78.................Result: Success
MouseDoubleClick —> 216, 406, INTEL, LEFT, 0.56.................Result: Success
MouseDoubleClick —> 216, 406, INTEL, LEFT, 0.51.................Result: Success
MouseClick —> 216, 406, INTEL, LEFT, 0.46.......................Result: Success
MouseDoubleClick —> 230, 420, INTEL, LEFT, 2.14.................Result: Success
MouseDoubleClick —> 230, 420, INTEL, LEFT, 0.51.................Result: Success
MouseDoubleClick —> 230, 420, INTEL, LEFT, 0.46.................Result: Success
MouseDoubleClick —> 230, 420, INTEL, LEFT, 0.5..................Result: Success
MouseDoubleClick —> 230, 420, INTEL, LEFT, 0.5..................Result: Success
MouseClick —> 81, 6, INTEL, LEFT, 5.12..........................Result: Success
CompareScreen —> “Region 2�?.....................................Result: Failure
************************************************************
* Log Ended on: Tue Dec 21 19:17:32 2004
************************************************************
The failures occurred in the two places where a portion of the Army Painter screen
was checked by the CompareScreen function. One way to diagnose the cause of this type
of problem is to run the automated test again and carefully watch what happens on
the screen. In this case, all of the mouse clicks happened while the game was still load-
ing, so they were ignored. After that the game just sat in the main menu, shown in
Figure 17.3, because all of the recorded test steps had already been played back.
You can also try to manually verify that there's no problem with the main menu timing
by clicking the Army Painter choice as soon as the menu comes up on the screen. If
that works correctly, you should be able to run the test faster than it was captured in
real time. It's a matter of making the right changes to the test file. VHT provides a Delay
function that you can add during capture by selecting it from the Record Bar. You can
also edit the test file to insert this command. An important feature of this command
is that it will delay for the specified number of second regardless of what the playback
Speed is set to. For this case select a relatively long delay, such as 15 seconds, to account
for target machines with slow CPUs or disk access times. Here's the portion of the test
code with a commented Delay command inserted:
ClickListView(1, “Dawn of War�?, DBLCLK, 0.0)
ActivateWindow(“Plat::Window {DB3DC0D7-BBA3-4d06-BCD8-40CD448B4AE3}�?, “Warhammer 40,000:
Dawn of War�?, NULL, 10.0)
Keys(“[Esc][Esc][Esc]�?, 0.0, 1.04, 1.07) ;Skip splash screens
Search WWH ::




Custom Search