aboutsummaryrefslogtreecommitdiff
path: root/engines/sci/engine/kfile.cpp
AgeCommit message (Collapse)Author
2009-11-14Cleaned up the file handling functions and removed the C IO wrappers. ↵Filippos Karapetis
Apparently, the special case that these were meant to handle never occurs (i.e. reading and writing to the same file), and the current code works well enough to justify these extra sanity checks svn-id: r45902
2009-10-29Stop SQ4 floppy from updating the unused sq4sg.dir file when deleting a ↵Filippos Karapetis
saved game svn-id: r45507
2009-10-29- Implemented savegame deletion for SQ4 floppyFilippos Karapetis
- Added a more proper way to disable the "Change Directory" button, by checking its name, rather than the string it contains svn-id: r45504
2009-10-29Disable the "Delete" button for all versions of SQ4 floppy, and the "Change ↵Filippos Karapetis
Directory" button for all games (English and non-English versions) svn-id: r45503
2009-10-29Automatically create memory.drv (the file containing the LSL5 password) for ↵Filippos Karapetis
non-English versions of LSL5, so that the games don't abort if it can't be found. svn-id: r45502
2009-10-29Fixed the deletion of save games - the wrong save game would be deleted with ↵Filippos Karapetis
the previous code, as we sort the list by date svn-id: r45499
2009-10-16Fix for bug #2874489 - "SCI: Larry 3 crashes at startup"Filippos Karapetis
svn-id: r45169
2009-10-09Some const correctness changes; cleanupMax Horn
svn-id: r44850
2009-10-04SCI: Rename EngineState::segMan to _segManMax Horn
svn-id: r44629
2009-09-30Added a new special reg_t, SIGNAL_REG, for signaling when an error occurs ↵Filippos Karapetis
(usually), or to signal success in some special occasions svn-id: r44505
2009-09-30SCI: Make kFile error messages slightly more verboseWillem Jan Palenstijn
svn-id: r44497
2009-09-30Fixed a crash in KQ1SCI, when the user types something wrong - the game ↵Filippos Karapetis
tries to open a file with an empty file name, and an odd file mode svn-id: r44491
2009-09-29- Changed the unimplemented debug SCI kernel functions (InspectObj, ↵Filippos Karapetis
ShowSends, ShowObjs, ShowFree, StackUsage and Profiler) to be dummy functions - we have our own debugger, and don't use these functions for debugging - Removed the function number parameter from all kernel functions, as it's no longer needed, and removed the FAKE_FUNCT_NR hack - Removed kUnknown() and kStub() - Dummy/unknown kernel functions are no longer invoked, and a warning is shown instead, with the paremeters passed to them Note: there is an evil hack used for debugging scripts in invoke_selector(), which probably no longer works now svn-id: r44461
2009-09-27SCI: Remove directory prefix added by QfG3's char importWillem Jan Palenstijn
svn-id: r44423
2009-09-27SCI: Add workaround for file mask used by QfG3Willem Jan Palenstijn
svn-id: r44411
2009-09-27SCI: Major string handling update.Willem Jan Palenstijn
All string access to segments should now work with both raw and non-raw (reg_t) segments, using the new utility functions in segMan. There will likely be regressions. svn-id: r44388
2009-09-26SCI: Ignore size argument to FILEIO_WRITE_STRING.Willem Jan Palenstijn
This matches LSL5's expectations when saving the password. svn-id: r44385
2009-09-26SCI: Fix copy/paste errorWillem Jan Palenstijn
svn-id: r44382
2009-09-25Create a define for the special "signal" offset used throughout the engine, ↵Filippos Karapetis
and fixed the arbitrary 0 values from commit #44294, set when some math functions do invalid calculations svn-id: r44359
2009-09-25SCI: Remove EngineState::game_version, it was only used for saving anyway. ↵Max Horn
Also remove syncCStr() svn-id: r44358
2009-09-24Fix warnings.Johannes Schickel
svn-id: r44304
2009-09-23COMMON: Add "ignoreCase" parameter to matchString.Johannes Schickel
svn-id: r44265
2009-09-14SCI: Rename SegManager::kernelDeref*() methods to SegManager::deref*()Max Horn
svn-id: r44083
2009-09-14SCI: kernelDeref*() functions are now seSegmentManager methodsMax Horn
svn-id: r44082
2009-09-14SCI: Merge kernelDerefCharPtr and kernelDerefString and change it from a ↵Max Horn
macro to a function svn-id: r44081
2009-09-02Some renaming:Filippos Karapetis
getresourceManager -> getResourceManger resourceManager -> resMan segmentManager ->segMan svn-id: r43908
2009-09-02SCI: Renamed kernel_dereference_* to kernelDeref*, and added kernelDerefStringMax Horn
svn-id: r43907
2009-09-02SCI: funct_nr is not used in 99% of all opcodes -- hide it in those (to be ↵Max Horn
removed eventually) svn-id: r43905
2009-09-01- Reverted the *vga targets back to *sci, and used the extras field again ↵Filippos Karapetis
for VGA remakes - The extras field is now filled by the fallback detector for VGA games svn-id: r43893
2009-08-27Throw a warning when kGetSaveDir is called with a parameterMatthew Hoops
svn-id: r43774
2009-08-25When opening files, open the English language part of the filename. Fixes ↵Filippos Karapetis
some multilingual SCI1 games svn-id: r43730
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-07-06Replaced sciprintf() calls with printf, DebugPrintf, warning and error callsFilippos Karapetis
svn-id: r42167
2009-07-03Applied patch #2815937 - "SCI: ReadString fix to repair LSL5 password". This ↵Filippos Karapetis
fixes the problems with the LSL5 password for good svn-id: r42049
2009-06-07Replaced/removed KP_UINT, KP_SINT, SKPV and UKPV as well as the ↵Filippos Karapetis
VIEW_PRIORITY and PRIORITY_BAND_FIRST wrappers svn-id: r41338
2009-06-05Moved some more debug commands to ScummVM's coneole and removed some unused codeFilippos Karapetis
svn-id: r41198
2009-05-31The error() and warning() functions add ! and newline automatically. (I didn'tTorbjörn Andersson
look at debug() and debugC(), since I'm really bored with this now. :-) svn-id: r41061
2009-05-30- Removed debug_mode from the engine stateFilippos Karapetis
- Turned all SCIkwarn and SCIkdebug functions to ScummVM's debugC function - Placed some debug code in appropriate defines: DEBUG_PARSER, DEBUG_AVOIDPATH and DEBUG_SOUND - Removed the "debuglog" command and the "script_checkloads_flag" and "sci_debug_flags" variables svn-id: r41033
2009-05-29Changed SaveFileManager methods to take Common::String params (instead of ↵Max Horn
char pointers) svn-id: r41000
2009-05-29SCI: Revised code for listing savegamesMax Horn
svn-id: r40999
2009-05-28SCI: Fix potential dangling pointer more robustly,Willem Jan Palenstijn
by changing the executionStack implementation to a list. svn-id: r40971
2009-05-27SCI: Cleanup.Walter van Niftrik
svn-id: r40931
2009-05-26Turned some static tables into static const tables; added some FIXME ↵Max Horn
comments to global static vars that should be removed (many more exist in SCI, Tinsel, and some other engines) svn-id: r40908
2009-05-20removed trailing whitespacesMax Horn
svn-id: r40742
2009-05-19SCI: Changed K_FILEIO_FILE_EXISTS to check regular files too.Walter van Niftrik
svn-id: r40724
2009-05-18SCI: Got rid of EngineState::execution_stack_pos; overally, the resulting ↵Max Horn
code should be even stricter in detecting invalid VM stack access (and some bugs when loading saves might be fixed now...) svn-id: r40694
2009-05-18Changed errors to be fatal, as most of them are fatal conditions. Some of ↵Filippos Karapetis
them have been changed to warnings for now, as they occur in certain games (e.g. SQ4 floppy, SQ4 CD and KQ5 CD) svn-id: r40675
2009-04-11SCI: Renamed bp_flag -> breakpointFlag; replaced global send_calls_allocated ↵Max Horn
& send_calls vars by a local Common::Stack instance svn-id: r39930
2009-03-12SCI: Moved savegame specific stuff from state.h to a new header savegame.hMax Horn
svn-id: r39351
2009-02-28Add support for saving Common::String objects.Willem Jan Palenstijn
Use it to simplify SavegameMetadata handling. svn-id: r38959