aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStrangerke2015-12-22 12:03:18 +0100
committerWillem Jan Palenstijn2015-12-23 21:35:34 +0100
commitdb99a31accd584d31be6e140bb52e592de0165bb (patch)
tree0bdd861ca6f44173262bbe7945d032de0c14c027
parent0823ebb36f7a464ea5986768c95d4e8d0adff3f9 (diff)
downloadscummvm-rg350-db99a31accd584d31be6e140bb52e592de0165bb.tar.gz
scummvm-rg350-db99a31accd584d31be6e140bb52e592de0165bb.tar.bz2
scummvm-rg350-db99a31accd584d31be6e140bb52e592de0165bb.zip
LAB: Fix stupid regression
-rw-r--r--engines/lab/resource.cpp42
1 files changed, 21 insertions, 21 deletions
diff --git a/engines/lab/resource.cpp b/engines/lab/resource.cpp
index 43820cf0ee..a679899acc 100644
--- a/engines/lab/resource.cpp
+++ b/engines/lab/resource.cpp
@@ -103,19 +103,19 @@ void Resource::readRoomData(const Common::String fileName) {
memset(_vm->_rooms, 0, (_vm->_manyRooms + 1) * sizeof(RoomData));
for (uint16 i = 1; i <= _vm->_manyRooms; i++) {
- RoomData curRoom = _vm->_rooms[i];
- curRoom._doors[NORTH] = dataFile->readUint16LE();
- curRoom._doors[SOUTH] = dataFile->readUint16LE();
- curRoom._doors[EAST] = dataFile->readUint16LE();
- curRoom._doors[WEST] = dataFile->readUint16LE();
- curRoom._transitionType = dataFile->readByte();
-
- curRoom._view[NORTH] = nullptr;
- curRoom._view[SOUTH] = nullptr;
- curRoom._view[EAST] = nullptr;
- curRoom._view[WEST] = nullptr;
- curRoom._rules = nullptr;
- curRoom._roomMsg = "";
+ RoomData *curRoom = &_vm->_rooms[i];
+ curRoom->_doors[NORTH] = dataFile->readUint16LE();
+ curRoom->_doors[SOUTH] = dataFile->readUint16LE();
+ curRoom->_doors[EAST] = dataFile->readUint16LE();
+ curRoom->_doors[WEST] = dataFile->readUint16LE();
+ curRoom->_transitionType = dataFile->readByte();
+
+ curRoom->_view[NORTH] = nullptr;
+ curRoom->_view[SOUTH] = nullptr;
+ curRoom->_view[EAST] = nullptr;
+ curRoom->_view[WEST] = nullptr;
+ curRoom->_rules = nullptr;
+ curRoom->_roomMsg = "";
}
delete dataFile;
@@ -142,14 +142,14 @@ void Resource::readViews(uint16 roomNum) {
Common::File *dataFile = openDataFile(fileName, MKTAG('R', 'O', 'M', '4'));
freeViews(roomNum);
- RoomData curRoom = _vm->_rooms[roomNum];
-
- curRoom._roomMsg = readString(dataFile);
- curRoom._view[NORTH] = readView(dataFile);
- curRoom._view[SOUTH] = readView(dataFile);
- curRoom._view[EAST] = readView(dataFile);
- curRoom._view[WEST] = readView(dataFile);
- curRoom._rules = readRule(dataFile);
+ RoomData *curRoom = &_vm->_rooms[roomNum];
+
+ curRoom->_roomMsg = readString(dataFile);
+ curRoom->_view[NORTH] = readView(dataFile);
+ curRoom->_view[SOUTH] = readView(dataFile);
+ curRoom->_view[EAST] = readView(dataFile);
+ curRoom->_view[WEST] = readView(dataFile);
+ curRoom->_rules = readRule(dataFile);
_vm->_music->updateMusic();
delete dataFile;