Age | Commit message (Collapse) | Author |
|
|
|
The regression affected AGOS and maybe some others; specifically,
the real MidiDriver would have been deleted twice -- I previously
missed that the Engine instances takes care of freeing the real
MidiDriver, not the MidiPlayer wrapping it.
This commit should clarify the ownership of the real MidiDriver for
most pseudo MidiDrivers.
|
|
Many engines follow the advice in audio/midiparser.h and create a
"pseudo-MidiDriver" subclass. But MidiParser really only needs a tiny
subset of the MidiDriver capabilities, namely those found in
MidiDriver_BASE. So we try to subclass from that whenever possible; this
allows us to remove many stub methods, and enables further future
simplifications.
|
|
|
|
This in turn enables modifying MidiDriver_MPU401::close() to allow
it to be called on a midi driver that has not yet been opened.
The specific issue that triggered me to make these changes was a
crash-upon-quit in HUGO, caused by it instantiating a midi driver,
then encountering an error (missing hugo.dat) *before* having
opened the new midi driver; the general cleanup code then tries
to close the (not yet opened) midi driver -> kaboom
Also fixed some engines which were leaking MidiDriver instances.
|
|
|
|
master
Conflicts:
backends/platform/android/android.cpp
engines/sci/graphics/screen.cpp
engines/sci/graphics/transitions.cpp
|
|
This fixes corruption during fades when low palette values end up negative.
|
|
Thanks to peres for pointing this out to me.
|
|
This change is not tested, but should hopefully work fine.
|
|
svn-id: r55889
|
|
svn-id: r55850
|
|
svn-id: r55820
|
|
svn-id: r55818
|
|
This avoids hiding an overloaded virtual method, which in turn can
cause weird bugs (see also the next commit).
svn-id: r55815
|
|
svn-id: r55806
|
|
svn-id: r55792
|
|
svn-id: r55611
|
|
Shorten long lines to increase readability.
svn-id: r55610
|
|
Not that I understand exactly what this function does, but since it's
a piece of debug code I figure I don't really have to.
svn-id: r55608
|
|
Turned 'no answer selected' into a constant.
svn-id: r55607
|
|
Hide mood and balloon winding extraction into Question and Answer objects.
svn-id: r55606
|
|
Encapsulate text comparison into string owners and removed some ugly
double negative logic.
svn-id: r55605
|
|
svn-id: r55604
|
|
Skip a 'runanswer' state when the text of the only answer available is 'null'.
svn-id: r55603
|
|
Print out the current question or the available answers when debug level is 9.
svn-id: r55602
|
|
svn-id: r55601
|
|
Some dialogue answers are set to the literal 'null', which is used in NS to
simulate a fixed monologue ('null' instructs the engine to jump to the first
entry in the list of available questions, which is always made of a single
item in this case).
BRA has flexible monologues that depend on the game state, so this patch goes
and checks all the available branches before picking the correct one.
svn-id: r55591
|
|
svn-id: r55590
|
|
svn-id: r55510
|
|
This will now avoid invalid memory reads and instead emit warnings if it is called with values outside of the expected data buffer or on a NULL buffer.
svn-id: r55492
|
|
svn-id: r55392
|
|
Amiga Demo.
These were found using Valgrind.
svn-id: r55369
|
|
Walking now works correctly, with no valgrind issues, lockups or assertions.
svn-id: r55281
|
|
svn-id: r55280
|
|
* Renamed and retyped "int _fieldC" to "bool _stillWalkingTowardsNode" to aid readability and clarity of code. Thanks to fuzzie for naming.
* Added assertion to prevent use of invalid memory as reported by Valgrind when walk point p is constructed from an empty list.
* Added code to stop walk if buildPath fails, though this causes an assertion instead currently.
svn-id: r55279
|
|
This command forces the mouse state to Enabled and Visible.
This is intended to help playtesting in Big Red Adventure, which has an issue currently with the mouse pointer getting stuck in the hidden state in some cases.
svn-id: r55234
|
|
The automatic destruction of engine member "_char" of type Character at end of the destructor causes an invalid read in the destruction of the AnimationPtr which is a SharedPtr. To stop this happening, the SharedPtr is reset() prior to the destruction of Gfx, so it's dependencies on Gfx are still present. This will affect Nippon Safes as well as Big Red Adventure, but is unlikely to cause any issues and it is likely this exists in NS as well.
Thanks to fuzzie for this code.
svn-id: r55233
|
|
svn-id: r55232
|
|
This corrects the Valgrind invalid reads associated with the IS_PATH_CLEAR() check reading beyond the data buffer and probably improves the pathfinding behaviour.
Thanks to fuzzie for suggesting this patch.
svn-id: r55231
|
|
svn-id: r55229
|
|
svn-id: r55226
|
|
svn-id: r55225
|
|
Code.
svn-id: r55221
|
|
Red Adventure.
svn-id: r55220
|
|
svn-id: r55148
|
|
* Do not restart character theme is already playing.
* Play the correct tune in the night club.
* Do not play muisc in the location meant to be silent.
svn-id: r55147
|
|
svn-id: r55146
|
|
svn-id: r55091
|
|
show. This fixes bug #3135782.
svn-id: r54882
|