[Scummvm-cvs-logs] SF.net SVN: scummvm: [28551] scummvm/trunk/engines/lure/disk.cpp
dreammaster at users.sourceforge.net
dreammaster at users.sourceforge.net
Sun Aug 12 13:17:48 CEST 2007
Revision: 28551
http://scummvm.svn.sourceforge.net/scummvm/?rev=28551&view=rev
Author: dreammaster
Date: 2007-08-12 04:17:48 -0700 (Sun, 12 Aug 2007)
Log Message:
-----------
Added code fragment that can change the resource Id to change depending on whether inside/outside
Modified Paths:
--------------
scummvm/trunk/engines/lure/disk.cpp
Modified: scummvm/trunk/engines/lure/disk.cpp
===================================================================
--- scummvm/trunk/engines/lure/disk.cpp 2007-08-12 11:16:43 UTC (rev 28550)
+++ scummvm/trunk/engines/lure/disk.cpp 2007-08-12 11:17:48 UTC (rev 28551)
@@ -31,6 +31,7 @@
#include "lure/disk.h"
#include "lure/luredefs.h"
+#include "lure/res.h"
namespace Lure {
@@ -125,6 +126,14 @@
}
uint32 Disk::getEntrySize(uint16 id) {
+ // Special room area check
+ uint16 tempId = id & 0x3fff;
+ if ((tempId == 0x120) || (tempId == 0x311) || (tempId == 8) || (tempId == 0x410)) {
+ ValueTableData &fieldList = Resources::getReference().fieldList();
+ if (fieldList.getField(AREA_FLAG) != 0)
+ id ^= 0x8000;
+ }
+
// Get the index of the resource, if necessary opening the correct file
uint8 index = indexOf(id);
@@ -137,6 +146,14 @@
MemoryBlock *Disk::getEntry(uint16 id)
{
+ // Special room area check
+ uint16 tempId = id & 0x3fff;
+ if ((tempId == 0x120) || (tempId == 0x311) || (tempId == 8) || (tempId == 0x410)) {
+ ValueTableData &fieldList = Resources::getReference().fieldList();
+ if (fieldList.getField(AREA_FLAG) != 0)
+ id ^= 0x8000;
+ }
+
// Get the index of the resource, if necessary opening the correct file
uint8 index = indexOf(id);
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
More information about the Scummvm-git-logs
mailing list