aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/console.cpp
AgeCommit message (Collapse)Author
2009-09-22SCI: Add new type SegmentRef which ultimately will allow us to distinguish ↵Max Horn
between raw and 'reg_t' memory blocks in client code svn-id: r44244
2009-09-22SCI: SegmentObj's now set their type in constructor; replace central ↵Max Horn
SegmentObj::createSegmentObj call in SegManager::allocSegment by several explicit 'new' statements; some extra cleanup svn-id: r44242
2009-09-21SCI: Replace IntMapper Script::_objIndices and Common::Array ↵Max Horn
Script::_objects by a HashMap -- goodbye, class IntMapper svn-id: r44240
2009-09-21SCI: Rename Object::flags and pos to _flags and _pos; tweak scriptObjInit0 ↵Max Horn
and scriptObjInit11 to be more similar svn-id: r44234
2009-09-17SCI: Add EngineState::_kernel member for convenienceMax Horn
svn-id: r44173
2009-09-17SCI: Add a global getSciVersion() function and make use of itMax Horn
svn-id: r44170
2009-09-17SCI: Rename selector_map_t -> SelectorCache and _selectorMap -> _selectorCacheMax Horn
svn-id: r44152
2009-09-17SCI: Move parts of struct ScriptState into a new struct DebugStateMax Horn
svn-id: r44151
2009-09-17Changed the way object selectors are accessed, by removing the relevant ↵Filippos Karapetis
defines and adding appropriate methods to the Object structure svn-id: r44138
2009-09-17SCI: Rename MemObject -> SegmentObjMax Horn
svn-id: r44130
2009-09-16SCI: Rename Script class members, change Script from struct to classMax Horn
svn-id: r44126
2009-09-14SCI: Misc cleanupMax Horn
svn-id: r44093
2009-09-12- Made obj_get and obj_get_name methods of SegManager (getObject and ↵Filippos Karapetis
getObjectName, respectively) - Renamed alloc_List -> allocateList, alloc_Node->allocateNode, alloc_hunk_entry->allocateHunkEntry, free_hunk_entry->freeHunkEntry, for consistency svn-id: r44039
2009-09-07SCI: Replace GET_SEGMENT_ANY and GET_OBJECT_SEGMENT macros by new segman methodsMax Horn
svn-id: r43999
2009-09-06SCI: Replace "IntMapper *id_seg_map" in SegManager with a ↵Max Horn
Common::HashMap<int,int> This simplifies the code considerably. Also changed the savegame format accordingly, which required me to bump the format version to 10. Old saves should still load fine. svn-id: r43986
2009-09-06SCI: cleanupMax Horn
svn-id: r43982
2009-09-06SCI: Cleanup for some SegManager internalsMax Horn
- rename segGet and getSegment to getScriptSegment; the two can be distinguished by the parameter count. - rename type SCRIPT_GET to ScriptLoadType to conform with our code formatting conventions - rename get_class_address to getClassAddress - some cleanup svn-id: r43981
2009-09-06SCI: Rename resManager -> resMan; segManager -> segManMax Horn
svn-id: r43980
2009-09-04Removed the bilinear and trilinear FreeSCI scalers, and only left the ↵Filippos Karapetis
unfiltered scaler in (to be replaced by ScummVM's scaler code). We really don't need bilinear and trilinear filtered scaling in the engine, as ScummVM's filters already perform bilinear and trilinear filtered scaling, if requested svn-id: r43938
2009-09-02Some renaming:Filippos Karapetis
getresourceManager -> getResourceManger resourceManager -> resMan segmentManager ->segMan svn-id: r43908
2009-09-01Re-enabled custom graphics options, and read the cursor, view, pic and text ↵Filippos Karapetis
filtering algorithm options from the ScummVM ini file (options "cursor_filter", "view_filter", "pic_filter" and "text_filter", 0 - unfiltered, 1 - bilinear filtering, 2 - trilinear filtering) svn-id: r43894
2009-08-31Some adjustments to the output of the "selector" and "selectors" console ↵Filippos Karapetis
commands svn-id: r43858
2009-08-30SCI: CleanupWalter van Niftrik
svn-id: r43811
2009-08-27Stop loading opcodes from vocab.998. They are the same in all SCI games and ↵Filippos Karapetis
are hardcoded anyway (plus, vocab.998 is unreliable in some games, e.g. QFG3, or completely missing in others). Also hardcoded the opcode names for the script debugger, the only place they're actually used. The only place where vocab.998 is loaded on demand is when using the "opcodes" console command (for debug/verification purposes) svn-id: r43775
2009-08-25- Replaced more cases of EngineState parametersFilippos Karapetis
- Made some version comparisons for old SCI0 versions easier to read - Removed the GET_SEL32SV macro svn-id: r43729
2009-08-25- Simplified the parameters of some functionsFilippos Karapetis
- Replaced some EngineState parameters - The SCI version is now obtained from the resource manager or the segment manager, thereby simplifying several functions - Plugged 2 leaks in the fallback detector - Renamed the segment manager and resource manager to "segmentManager" and "resourceManager" in all places, for consistency svn-id: r43722
2009-08-17- Simplified some functions to accept only the parts of the EngineState they ↵Filippos Karapetis
need as parameters, instead of the whole EngineState - Moved the class table in the Segment manager - it's the only class using it directly - Removed the sci11 flag from save games (we already know this, we don't need to store it) - Moved script_get_segment() and get_class_address() inside the segment manager class - Removed the script_locate_by_segment wrapper - Simplified script_lookup_export() a lot by removing some paranoia checks - Added some WIP code for automatically determining the game id in the fallback detector (still not working) - General cleanup svn-id: r43458
2009-08-15SCI: Added enum for map and volume versions. Removed res_version setting fromWalter van Niftrik
detection.cpp (should be detectable). Cleanup. svn-id: r43390
2009-08-10SCI: Added several debug command aliases.Walter van Niftrik
svn-id: r43229
2009-08-10SCI: Fix vmvars debug command.Walter van Niftrik
svn-id: r43219
2009-07-18SCI: Fix disasm_addr option parsingWillem Jan Palenstijn
svn-id: r42598
2009-07-18SCI: don't leave debugger after btWillem Jan Palenstijn
svn-id: r42589
2009-07-18SCI: Fix stepping in debuggerWillem Jan Palenstijn
svn-id: r42587
2009-07-11Moved the kernel and the vocabulary outside of the engine state (they're ↵Filippos Karapetis
static data, which never changes during a game) svn-id: r42398
2009-07-11Fixed regression in the script parser from commit 42260Filippos Karapetis
svn-id: r42371
2009-07-08- Moved printObject inside the Console classFilippos Karapetis
- Enabled the parts where disassemble() is called svn-id: r42263
2009-07-08Some cleanup for the script debugger code:Filippos Karapetis
- Renamed struct DebugState to ScriptState and r_amp_rest to restAdjust inside EngineState. Changed restAdjust to be a uint16 (actually it is a uint16, but it was being casted back and forth from an unsigned integer, so this clears up its type and size) - Moved the script state variables from inside the run_vm() into the ScriptState struct, so that they can be accessed by the console commands and the script debugger all the time, and removed the weird isValid code svn-id: r42260
2009-07-07Removed the superfluous sci_version_types array (it's essentially the same ↵Filippos Karapetis
as the versionNames array) svn-id: r42216
2009-07-07Prevent a crash when the engine errors out before the game state is initializedFilippos Karapetis
svn-id: r42201
2009-07-06Replaced sciprintf() calls with printf, DebugPrintf, warning and error callsFilippos Karapetis
svn-id: r42167
2009-07-05Removed validity check for atoi, which prevented console commands from ↵Filippos Karapetis
interacting with resources with id 0 svn-id: r42117
2009-07-04Added a new console command, "selector", which attempts to find a selector ↵Filippos Karapetis
by name svn-id: r42093
2009-07-03- Pushed debugstate into debug.hFilippos Karapetis
- When an error occurs, manipulate the execution stack before error() opens the console inside getDebugger(), like FreeSCI did. Added another method for obtaining the SCI console for use by the engine itself. svn-id: r42062
2009-07-02Moved some more debug state related variables in the DebugState structFilippos Karapetis
svn-id: r42044
2009-07-02Moved all the debug state variables in a separate struct and re-enabled ↵Filippos Karapetis
several places where they're used svn-id: r42043
2009-06-21CleanupFilippos Karapetis
svn-id: r41727
2009-06-15Added aliases for the script/breakpoint related commands and added the ↵Filippos Karapetis
debugflag related commands to the help screen svn-id: r41538
2009-06-08Moved some more debug commands to ScummVM's consoleFilippos Karapetis
svn-id: r41364
2009-06-07SCI: Got rid of g_EngineStateMax Horn
svn-id: r41359
2009-06-07SCI: Moved resource36 handling into resource manager.Walter van Niftrik
svn-id: r41349