mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-22 18:02:05 +00:00
Added some slight fixes for the RAMA demo, which starts now, though it dies horribly when clicking on anything
svn-id: r50569
This commit is contained in:
parent
0e3f923f78
commit
d5e037e703
@ -405,6 +405,18 @@ SciVersion GameFeatures::detectGfxFunctionsType() {
|
||||
|
||||
#ifdef ENABLE_SCI32
|
||||
bool GameFeatures::autoDetectSci21KernelType() {
|
||||
// First, check if the Sound object is loaded
|
||||
reg_t soundObjAddr = _segMan->findObjectByName("Sound");
|
||||
if (soundObjAddr.isNull()) {
|
||||
// Usually, this means that the Sound object isn't loaded yet.
|
||||
// This case doesn't occur in early SCI2.1 games, and we've only
|
||||
// seen it happen in the RAMA demo, thus we can assume that the
|
||||
// game is using a SCI2.1 table
|
||||
warning("autoDetectSci21KernelType(): Sound object not loaded, assuming a SCI2.1 table");
|
||||
_sci21KernelType = SCI_VERSION_2_1;
|
||||
return true;
|
||||
}
|
||||
|
||||
// Look up the script address
|
||||
reg_t addr = getDetectionAddr("Sound", SELECTOR(play));
|
||||
|
||||
|
@ -463,6 +463,13 @@ reg_t kArray(EngineState *s, int argc, reg_t *argv) {
|
||||
return argv[1];
|
||||
}
|
||||
case 6: { // Cpy
|
||||
if (s->_segMan->getSegmentObj(argv[1].segment)->getType() != SEG_TYPE_ARRAY ||
|
||||
s->_segMan->getSegmentObj(argv[3].segment)->getType() != SEG_TYPE_ARRAY) {
|
||||
// Happens in the RAMA demo
|
||||
warning("kArray(Cpy): Request to copy a segment which isn't an array, ignoring");
|
||||
return NULL_REG;
|
||||
}
|
||||
|
||||
SciArray<reg_t> *array1 = s->_segMan->lookupArray(argv[1]);
|
||||
SciArray<reg_t> *array2 = s->_segMan->lookupArray(argv[3]);
|
||||
uint32 index1 = argv[2].toUint16();
|
||||
|
Loading…
Reference in New Issue
Block a user