aboutsummaryrefslogtreecommitdiff
path: root/sword2
AgeCommit message (Collapse)Author
2005-02-21removed lots of unnecessary seek()s and read()s by keeping the datafiles' ↵Robert Göffringmann
index tables in memory instead of accessing them over and over again, which caused major slowdowns with cd accesses. Also, the caching of datafiles depends on the memory usage now, not on the number of screens that the player entered in the meantime. The old behaviour made the engine run out of memory on the PS2. svn-id: r16843
2005-02-20More BS2 restructuring.Torbjörn Andersson
The various game settings are no longer stored in the Gui class. They are stored in the class that use them. Code that doesn't belong in the Gui class, e.g. the "restart" code, has been moved out of it. Afterwards, the Gui class had been reduced to nothing more than a handful of trivial methods for invoking the in-game dialogs. So the entire Gui class has been removed. svn-id: r16827
2005-02-19This is the second part of the BS2 restructuring. There are two newTorbjörn Andersson
classes: Screen and Mouse. Screen handles most of the drawing, except the mouse cursor and in-game menus. The old Graphics class is no more. I've also fixed some "reverse stereo" regressions from the first part of the restructuring. I'm not sure what the next step will be, but hopefully it will be smaller than this one was. svn-id: r16812
2005-02-18Forgot to check if preFetchCompSpeech() could find the speech file. Now itTorbjörn Andersson
will work even if the file is missing. (This only affects the cutscene player.) svn-id: r16806
2005-02-08Now there are two file handles for the music: one for each CD. This is notTorbjörn Andersson
the same thing as one for each music stream. If both music streams are playing music from the same CD, they will both take turns at using the same file handle. The only case where both file handles are used is when music from one CD is fading in while music from the other CD is fading out. Which of course can only happen if you play the game from hard disk. If the game has to ask for the other CD, it kills the music immediately. The reason for doing this is that there was some concern about whether having two file handles open to the same file was portable or not. I don't think that question was ever fully answered, so I avoid the situation. svn-id: r16753
2005-02-07Fixed crash that would happen if the game tried to play music from CD1 andTorbjörn Andersson
CD2 at the same time. There will eventually be a better fix for this, I hope. svn-id: r16750
2005-01-28Fix compilation with mpeg2 disabledMax Horn
svn-id: r16680
2005-01-28Use class Mutex instead of MutexRefMax Horn
svn-id: r16679
2005-01-28Began what I hope is the final major restructuring of the BS2 engine.Torbjörn Andersson
In this first step, I have moved all opcode functions into functions.cpp, instead of having them scattered all over the place. To get things to compile again, I had to rewrite the overly complicated sound effects handling. It's much simpler now. The next step will be to move any non-trivial code out of the opcode functions and into the appropriate object. This, I hope, will make it easier to create well-separated objects, instead of the current mess. I also want to tear down the artificial boundary between the main directory and the "driver" directory. We already have a cross-platform layer; there's no need to have yet another one. (Actually, the rewriting of the sound effects code took one first step in this direction.) At the final stage, I'd like to get rid of the "drivers" directory completely, but I'll probably need some help with that if I want to preserve the CVS history of the code. Things will probably be a bit bumpy along the way, but I seem to have reached a point of relative stability again, which is why I'm commiting this now. svn-id: r16668
2005-01-25Corrected the comment: the savegame filename does not include the path atTorbjörn Andersson
this stage. (So 128 characters is probably excessive, even if the SCUMM engine uses 256.) svn-id: r16634
2005-01-25Added a "value step" parameter to the Slider widget class so that clickingTorbjörn Andersson
beside the slider handle can move it more than one step. (When the volume range was 0-14 or 0-16 this wasn't needed, but now it's 0-255.) svn-id: r16633
2005-01-20Fixed bug that I must have introduced during one of my cleanups. TheTorbjörn Andersson
original code read "LLogic.Logic_up( (*params*65536)+2);". I don't know where this opcode is actually used, though. svn-id: r16600
2005-01-17Updated copyright header, as discussed on the mailing list.Torbjörn Andersson
svn-id: r16580
2005-01-11On Fingolfin's suggestion I put back the inclusion of util.h into Rect, forTorbjörn Andersson
MIN() and MAX(). I then removed util.h from a bunch of files which I don't think need it any more. (Please let me know if I got too blood-thirsty!) This reverts some of the changes I made this morning. svn-id: r16541
2005-01-11Use Fingolfin's new WAV code.Torbjörn Andersson
svn-id: r16540
2005-01-11This is probably not the optimal fix, but at least ScummVM compiles again.Torbjörn Andersson
svn-id: r16538
2005-01-10system.h was being included in tons of places, without any good reason; ↵Max Horn
reduced this (total dependencies on system.h went down from 193 to 85 files) svn-id: r16527
2005-01-09Mark some places which probably should use loadWAVFromStream(); maybe some ↵Max Horn
of the engine maintainers can look into using it svn-id: r16503
2005-01-06Fixed typo (in comment)Torbjörn Andersson
svn-id: r16441
2005-01-04Applied patch #1088948, with minor modificationsTorbjörn Andersson
svn-id: r16421
2005-01-01Updated copyright year.Torbjörn Andersson
svn-id: r16397
2004-12-27Use the mixer to handle sound volumesMax Horn
svn-id: r16349
2004-12-27Reducing header dependencies a bitMax Horn
svn-id: r16347
2004-12-27Don't use pointers to int. We don't know what size an "int" is.Torbjörn Andersson
Also, failing the script checksum test is no longer a fatal error. There has been a report that could mean there is a German version with incorrect checksums. Whether or not this change will make it playable is an entirely different matter, of course. svn-id: r16341
2004-12-27Fix volume regression my previous checkin causedMax Horn
svn-id: r16337
2004-12-27Use the same volume ranges as most of the rest of ScummVM (i.e. 0-255)Max Horn
svn-id: r16333
2004-12-27Added 'sound types' to the mixer - for now, only plain (for the premixer), ↵Max Horn
SFX and music; volume is now controlled based on the sound type svn-id: r16330
2004-12-21Added Russian narration message.Eugene Sandulenko
svn-id: r16227
2004-12-11Fix dumb CE compilerNicolas Bacca
svn-id: r16026
2004-12-09Pass subdirectories to gamedetector functionsRobert Göffringmann
svn-id: r16002
2004-12-05Clean up OSystem::EventMax Horn
svn-id: r15990
2004-11-29Fix music volumeEugene Sandulenko
svn-id: r15960
2004-11-28Changed parameter order of SoundMixer::playInputStream to match that of playRawMax Horn
svn-id: r15950
2004-11-27Make use of our String class instead of juggling with char pointers; added ↵Max Horn
File::exists method svn-id: r15913
2004-11-27AudioStream::read() has been removed quite some time ago, now making sure ↵Max Horn
that change is reflected everywhere svn-id: r15911
2004-11-27Moved Engine::getSavePath() to class SaveFileManager; removed the ↵Max Horn
'directory' parameter from SaveFileManager::openSavefile and listSavefiles (they always use getSavePath() now, which is what we did anyway) svn-id: r15901
2004-11-26SpellingMax Horn
svn-id: r15890
2004-11-24Fix a`ll engines. They work, though current fix is just temporary.Eugene Sandulenko
There are plans to add some brains to GameDetector class, which will let us avoid passing detector to init() method. svn-id: r15873
2004-11-23Added Engine::init() method; added return value to Engine::go()Max Horn
svn-id: r15865
2004-11-20Removing walkthrough stuff again (talked to aquadran about this, he had no ↵Max Horn
objections) svn-id: r15849
2004-11-19added walkthroughPaweł Kołodziejski
svn-id: r15835
2004-11-16CleanupTorbjörn Andersson
svn-id: r15826
2004-11-15I think this is the kind of constructor/go changes _sev was talking aboutTorbjörn Andersson
in his mail to scummvm-devel. (Though "a discussed a while ago change" sounds like sort of thing Robert Jordan writes whenever there is danger of anything actually happening in any of his more recent books. Tantalizing, yet non-informative. ;-) It's still rather messy. I'll look into cleaning it up later. svn-id: r15818
2004-11-14CleanupTorbjörn Andersson
svn-id: r15810
2004-11-11Fixed comment typo. It's the pyramid bug that's dreaded, not the pyramidTorbjörn Andersson
itself. :-) svn-id: r15789
2004-10-30Doxygen fixesMax Horn
svn-id: r15701
2004-10-19Use the same REDUCE_MEMORY_USAGE trick here as in scumm/intern.hTorbjörn Andersson
svn-id: r15612
2004-10-19Cleanup of the credits code. Use the new gets() function.Torbjörn Andersson
svn-id: r15609
2004-10-17Doxygen fixMax Horn
svn-id: r15594
2004-10-12Migration to the newer form of setupPremix().Torbjörn Andersson
svn-id: r15532