diff options
author | Strangerke | 2016-08-21 14:25:06 +0200 |
---|---|---|
committer | Bendegúz Nagy | 2016-08-26 23:02:22 +0200 |
commit | 53121afb092587f87faf0281b08e96ff1c59e44e (patch) | |
tree | b704a953969c3dc3e2e7bb4d0f3f3b2bc1ff2b3c /engines/dm/dungeonman.cpp | |
parent | 20165b18656ee6ddb2586983735fa280abfefc54 (diff) | |
download | scummvm-rg350-53121afb092587f87faf0281b08e96ff1c59e44e.tar.gz scummvm-rg350-53121afb092587f87faf0281b08e96ff1c59e44e.tar.bz2 scummvm-rg350-53121afb092587f87faf0281b08e96ff1c59e44e.zip |
DM: Fix some GCC warnings
Diffstat (limited to 'engines/dm/dungeonman.cpp')
-rw-r--r-- | engines/dm/dungeonman.cpp | 12 |
1 files changed, 7 insertions, 5 deletions
diff --git a/engines/dm/dungeonman.cpp b/engines/dm/dungeonman.cpp index 8a17ce6fd5..287c454456 100644 --- a/engines/dm/dungeonman.cpp +++ b/engines/dm/dungeonman.cpp @@ -797,19 +797,19 @@ Square DungeonMan::f151_getSquare(int16 mapX, int16 mapY) { if (isMapYInBounds) { SquareType squareType = Square(_g271_currMapData[0][mapY]).getType(); - if (((mapX == -1) && (squareType == k1_CorridorElemType)) || (squareType == k2_ElementTypePit)) + if (((mapX == -1) && (squareType == k1_CorridorElemType)) || (squareType == k2_PitElemType)) return Square(k0_ElementTypeWall, k0x0004_WallEastRandOrnAllowed); squareType = Square(_g271_currMapData[_g273_currMapWidth - 1][mapY]).getType(); - if (((mapX == _g273_currMapWidth) && (squareType == k1_CorridorElemType)) || (squareType == k2_ElementTypePit)) + if (((mapX == _g273_currMapWidth) && (squareType == k1_CorridorElemType)) || (squareType == k2_PitElemType)) return Square(k0_ElementTypeWall, k0x0001_WallWestRandOrnAllowed); } else if (isMapXInBounds) { SquareType squareType = Square(_g271_currMapData[mapX][0]).getType(); - if (((mapY == -1) && (squareType == k1_CorridorElemType)) || (squareType == k2_ElementTypePit)) + if (((mapY == -1) && (squareType == k1_CorridorElemType)) || (squareType == k2_PitElemType)) return Square(k0_ElementTypeWall, k0x0002_WallSouthRandOrnAllowed); squareType = Square(_g271_currMapData[mapX][_g274_currMapHeight - 1]).getType(); - if (((mapY == _g274_currMapHeight) && (squareType == k1_CorridorElemType)) || (squareType == k2_ElementTypePit)) + if (((mapY == _g274_currMapHeight) && (squareType == k1_CorridorElemType)) || (squareType == k2_PitElemType)) return Square(k0_ElementTypeWall, k0x0008_WallNorthRandOrnAllowed); } return Square(k0_ElementTypeWall, 0); @@ -941,7 +941,7 @@ T0172010_ClosedFakeWall: AL0307_uc_FootprintsAllowed = true; } - while ((curThing != Thing::_endOfList) && ((Direction)curThing.getType() <= k3_SensorThingType)) { + while ((curThing != Thing::_endOfList) && (curThing.getType() <= k3_SensorThingType)) { if (curThing.getType() == k3_SensorThingType) { Sensor *curSensor = (Sensor*)f156_getThingData(curThing); aspectArray[k4_FloorOrnOrdAspect] = curSensor->getOrnOrdinal(); @@ -1271,6 +1271,8 @@ uint16 DungeonMan::f140_getObjectWeight(Thing thing) { case k7_ScrollThingType: weight = 1; break; + default: + break; } return weight; // this is garbage if none of the branches were taken |