Open main menu

Difference between revisions of "Advanced Engine Features"

m
CruisE has a getDebugger method now
(→‎Enhanced debug/error messages: Not implemented by...)
m (CruisE has a getDebugger method now)
Line 222: Line 222:
By implementing the Engine::errorString() method, your engine can add extra info whenever ScummVM is about to print an error message triggered by the error() function. This could be used to print out additional data describing the context, such as the ID of the active script when the error occurred, values of special flags, etc. -- anything that might help debug an error.
By implementing the Engine::errorString() method, your engine can add extra info whenever ScummVM is about to print an error message triggered by the error() function. This could be used to print out additional data describing the context, such as the ID of the active script when the error occurred, values of special flags, etc. -- anything that might help debug an error.
If your engine implements a debug console (which is very easy to do using just subclass GUI::Debugger, and then implement your custom debugger commands and variables), overload Engine::getDebugger() to return a point to it. If you do so, when error() is called, it will open that debug console instead of immediately exiting. This can be useful to perform some additional post-mortem analysis.
If your engine implements a debug console (which is very easy to do using just subclass GUI::Debugger, and then implement your custom debugger commands and variables), overload Engine::getDebugger() to return a pointer to it. If you do so, when error() is called, it will open that debug console instead of immediately exiting. This can be useful to perform some additional post-mortem analysis.


'''Relevant Engine API'''
'''Relevant Engine API'''
Line 229: Line 229:


'''Already implemented by:'''
'''Already implemented by:'''
[[AGOS]], [[Groovie]] (implementing both methods), [[Kyra]], [[Lure]], [[Parallaction]], [[Queen]], [[SAGA]], [[SCUMM]] (implementing both methods), [[Sky]], [[Sword2]]
[[AGOS]], [[CruisE]], [[Groovie]] (implementing both methods), [[Kyra]], [[Lure]], [[Parallaction]], [[Queen]], [[SAGA]], [[SCUMM]] (implementing both methods), [[Sky]], [[Sword2]]


'''Not implemented by:'''
'''Not implemented by:'''
[[AGI]], [[Cine]], [[Cruise]], [[Drascula]], [[Gob]], [[Igor]], [[M4]], [[MADE]], [[Sword1]]
[[AGI]], [[Cine]], [[Drascula]], [[Gob]], [[Igor]], [[M4]], [[MADE]], [[Sword1]]
960

edits