Game Development Reference
In-Depth Information
audio playback may become choppy or where sounds are taking longer to load than
expected.
What the tool must provide. The tool should create a log file of all file activity
performed by the game while running. This log file should then be examined, and,
where applicable, it should flag files which should be positioned close to each other
on the storage media used for the game's assets.
Tool design. The streaming monitor requires a FileLog class to be constructed on
the game side, which will, in a similar manner to the sound log, store a log of file
activity and periodically flush this out to a file. The FileLog class will, in a similar
manner as our other tools, make use of static functions and data to store the log
of file activity. As well as a FileLog class, we will have a FileSystem class, which is
used to wrap up all file I/O functions used by the game. The game developer will
use the FileSystem class to open, read, and close files, and this class will, in turn,
call the appropriate FileLog function and platform file handling function.
There are two other components to the tool: a runtime visualization of which
files are being loaded and a postrun analysis tool. The runtime visualization tool
showsfileactivityasitoccursinthegame. Figure11.3 showshowthistoolmay
look. The postrun analysis tool is a separate application that reads in the file
activity log and will generate information on each file's usage, provide hints on how
game files should be stored on the game's storage media, and allow the user to step
through all the file activity that was performed. An example of this tool is shown
in Figure11.4 .
Figure 11.3. Runtime visualization of file activity.
 
Search WWH ::




Custom Search