diff options
author | Strangerke | 2016-08-24 08:03:55 +0200 |
---|---|---|
committer | Bendegúz Nagy | 2016-08-26 23:02:22 +0200 |
commit | 64b1c4fdf11001acc442fea7367b11f45336b25f (patch) | |
tree | 2f76f550236c7064e13417fb4c8077c31fc0c2cd /engines/dm/movesens.cpp | |
parent | 544ce3578b9c190169d85cfa9ab2c0138684b525 (diff) | |
download | scummvm-rg350-64b1c4fdf11001acc442fea7367b11f45336b25f.tar.gz scummvm-rg350-64b1c4fdf11001acc442fea7367b11f45336b25f.tar.bz2 scummvm-rg350-64b1c4fdf11001acc442fea7367b11f45336b25f.zip |
DM: Rename DungeonMan class members
Diffstat (limited to 'engines/dm/movesens.cpp')
-rw-r--r-- | engines/dm/movesens.cpp | 230 |
1 files changed, 115 insertions, 115 deletions
diff --git a/engines/dm/movesens.cpp b/engines/dm/movesens.cpp index b24a997549..ac66f231f6 100644 --- a/engines/dm/movesens.cpp +++ b/engines/dm/movesens.cpp @@ -77,7 +77,7 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui for (L0752_ui_Cell = k0_CellNorthWest; L0752_ui_Cell < k3_CellSouthWest + 1; L0752_ui_Cell++) { L0760_ai_SensorCountToProcessPerCell[L0752_ui_Cell] = 0; } - L0764_T_SquareFirstThing = L0750_T_ThingBeingProcessed = _vm->_dungeonMan->f161_getSquareFirstThing(mapX, mapY); + L0764_T_SquareFirstThing = L0750_T_ThingBeingProcessed = _vm->_dungeonMan->getSquareFirstThing(mapX, mapY); while (L0750_T_ThingBeingProcessed != Thing::_endOfList) { if ((L0751_ui_ThingType = (L0750_T_ThingBeingProcessed).getType()) == k3_SensorThingType) { L0760_ai_SensorCountToProcessPerCell[(L0750_T_ThingBeingProcessed).getCell()]++; @@ -85,13 +85,13 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui if (L0751_ui_ThingType >= k4_GroupThingType) break; } - L0750_T_ThingBeingProcessed = _vm->_dungeonMan->f159_getNextThing(L0750_T_ThingBeingProcessed); + L0750_T_ThingBeingProcessed = _vm->_dungeonMan->getNextThing(L0750_T_ThingBeingProcessed); } L0763_T_LastProcessedThing = L0750_T_ThingBeingProcessed = L0764_T_SquareFirstThing; while (L0750_T_ThingBeingProcessed != Thing::_endOfList) { if ((L0751_ui_ThingType = (L0750_T_ThingBeingProcessed).getType()) == k3_SensorThingType) { L0760_ai_SensorCountToProcessPerCell[L0752_ui_Cell = (L0750_T_ThingBeingProcessed).getCell()]--; - L0755_ps_Sensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0750_T_ThingBeingProcessed); + L0755_ps_Sensor = (Sensor *)_vm->_dungeonMan->getThingData(L0750_T_ThingBeingProcessed); if ((L0757_ui_SensorType = (L0755_ps_Sensor)->getType()) == k0_SensorDisabled) goto T0275058_ProceedToNextThing; if ((_vm->_championMan->_leaderIndex == kM1_ChampionNone) && (L0757_ui_SensorType != k127_SensorWallChampionPortrait)) @@ -99,16 +99,16 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui if (L0752_ui_Cell != cellParam) goto T0275058_ProceedToNextThing; L0758_i_SensorData = L0755_ps_Sensor->getData(); - L0756_i_SensorEffect = L0755_ps_Sensor->getEffectA(); + L0756_i_SensorEffect = L0755_ps_Sensor->getAttrEffectA(); switch (L0757_ui_SensorType) { case k1_SensorWallOrnClick: L0753_B_DoNotTriggerSensor = false; - if (L0755_ps_Sensor->getEffectA() == k3_SensorEffHold) { + if (L0755_ps_Sensor->getAttrEffectA() == k3_SensorEffHold) { goto T0275058_ProceedToNextThing; } break; case k2_SensorWallOrnClickWithAnyObj: - L0753_B_DoNotTriggerSensor = (_vm->_championMan->_leaderEmptyHanded != L0755_ps_Sensor->getRevertEffectA()); + L0753_B_DoNotTriggerSensor = (_vm->_championMan->_leaderEmptyHanded != L0755_ps_Sensor->getAttrRevertEffectA()); break; case k17_SensorWallOrnClickWithSpecObjRemovedSensor: case k11_SensorWallOrnClickWithSpecObjRemovedRotateSensors: @@ -116,11 +116,11 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui goto T0275058_ProceedToNextThing; case k3_SensorWallOrnClickWithSpecObj: case k4_SensorWallOrnClickWithSpecObjRemoved: - L0753_B_DoNotTriggerSensor = ((L0758_i_SensorData == _vm->_objectMan->f32_getObjectType(L0761_T_LeaderHandObject)) == L0755_ps_Sensor->getRevertEffectA()); + L0753_B_DoNotTriggerSensor = ((L0758_i_SensorData == _vm->_objectMan->f32_getObjectType(L0761_T_LeaderHandObject)) == L0755_ps_Sensor->getAttrRevertEffectA()); if (!L0753_B_DoNotTriggerSensor && (L0757_ui_SensorType == k17_SensorWallOrnClickWithSpecObjRemovedSensor)) { if (L0763_T_LastProcessedThing == L0750_T_ThingBeingProcessed) /* If the sensor is the only one of its type on the cell */ break; - L0765_ps_Sensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0763_T_LastProcessedThing); + L0765_ps_Sensor = (Sensor *)_vm->_dungeonMan->getThingData(L0763_T_LastProcessedThing); L0765_ps_Sensor->setNextThing(L0755_ps_Sensor->getNextThing()); L0755_ps_Sensor->setNextThing(Thing::_none); L0750_T_ThingBeingProcessed = L0763_T_LastProcessedThing; @@ -141,13 +141,13 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui if (_vm->_championMan->_leaderEmptyHanded) { if ((L0761_T_LeaderHandObject = f273_sensorGetObjectOfTypeInCell(mapX, mapY, L0752_ui_Cell, L0758_i_SensorData)) == Thing::_none) goto T0275058_ProceedToNextThing; - _vm->_dungeonMan->f164_unlinkThingFromList(L0761_T_LeaderHandObject, Thing(0), mapX, mapY); + _vm->_dungeonMan->unlinkThingFromList(L0761_T_LeaderHandObject, Thing(0), mapX, mapY); _vm->_championMan->putObjectInLeaderHand(L0761_T_LeaderHandObject, true); } else { if ((_vm->_objectMan->f32_getObjectType(L0761_T_LeaderHandObject) != L0758_i_SensorData) || (f273_sensorGetObjectOfTypeInCell(mapX, mapY, L0752_ui_Cell, L0758_i_SensorData) != Thing::_none)) goto T0275058_ProceedToNextThing; _vm->_championMan->getObjectRemovedFromLeaderHand(); - _vm->_dungeonMan->f163_linkThingToList(thingWithNewCell(L0761_T_LeaderHandObject, L0752_ui_Cell), Thing(0), mapX, mapY); + _vm->_dungeonMan->linkThingToList(thingWithNewCell(L0761_T_LeaderHandObject, L0752_ui_Cell), Thing(0), mapX, mapY); L0761_T_LeaderHandObject = Thing::_none; } f270_sensorTriggetLocalEffect(k2_SensorEffToggle, mapX, mapY, L0752_ui_Cell); /* This will cause a rotation of the sensors at the specified cell on the specified square after all sensors have been processed */ @@ -160,12 +160,12 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui case k16_SensorWallObjExchanger: if (L0760_ai_SensorCountToProcessPerCell[L0752_ui_Cell]) /* If the sensor is not the last one of its type on the cell */ goto T0275058_ProceedToNextThing; - L0762_T_ThingOnSquare = _vm->_dungeonMan->f162_getSquareFirstObject(mapX, mapY); + L0762_T_ThingOnSquare = _vm->_dungeonMan->getSquareFirstObject(mapX, mapY); if ((_vm->_objectMan->f32_getObjectType(L0761_T_LeaderHandObject) != L0758_i_SensorData) || (L0762_T_ThingOnSquare == Thing::_none)) goto T0275058_ProceedToNextThing; - _vm->_dungeonMan->f164_unlinkThingFromList(L0762_T_ThingOnSquare, Thing(0), mapX, mapY); + _vm->_dungeonMan->unlinkThingFromList(L0762_T_ThingOnSquare, Thing(0), mapX, mapY); _vm->_championMan->getObjectRemovedFromLeaderHand(); - _vm->_dungeonMan->f163_linkThingToList(thingWithNewCell(L0761_T_LeaderHandObject, L0752_ui_Cell), Thing(0), mapX, mapY); + _vm->_dungeonMan->linkThingToList(thingWithNewCell(L0761_T_LeaderHandObject, L0752_ui_Cell), Thing(0), mapX, mapY); _vm->_championMan->putObjectInLeaderHand(L0762_T_ThingOnSquare, true); L0753_B_DoNotTriggerSensor = false; break; @@ -181,18 +181,18 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui } if (!L0753_B_DoNotTriggerSensor) { L0759_B_AtLeastOneSensorWasTriggered = true; - if (L0755_ps_Sensor->getAudibleA()) { - _vm->_sound->f064_SOUND_RequestPlay_CPSD(k01_soundSWITCH, _vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY, k1_soundModePlayIfPrioritized); + if (L0755_ps_Sensor->getAttrAudibleA()) { + _vm->_sound->f064_SOUND_RequestPlay_CPSD(k01_soundSWITCH, _vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY, k1_soundModePlayIfPrioritized); } if (!_vm->_championMan->_leaderEmptyHanded && ((L0757_ui_SensorType == k4_SensorWallOrnClickWithSpecObjRemoved) || (L0757_ui_SensorType == k11_SensorWallOrnClickWithSpecObjRemovedRotateSensors) || (L0757_ui_SensorType == k17_SensorWallOrnClickWithSpecObjRemovedSensor))) { - L0754_ps_Generic = (Thing *)_vm->_dungeonMan->f156_getThingData(L0761_T_LeaderHandObject); + L0754_ps_Generic = (Thing *)_vm->_dungeonMan->getThingData(L0761_T_LeaderHandObject); *L0754_ps_Generic = Thing::_none; _vm->_championMan->getObjectRemovedFromLeaderHand(); L0761_T_LeaderHandObject = Thing::_none; } else { if (_vm->_championMan->_leaderEmptyHanded && (L0757_ui_SensorType == k12_SensorWallObjGeneratorRotateSensors) && - ((L0761_T_LeaderHandObject = _vm->_dungeonMan->f167_getObjForProjectileLaucherOrObjGen(L0758_i_SensorData)) != Thing::_none)) { + ((L0761_T_LeaderHandObject = _vm->_dungeonMan->getObjForProjectileLaucherOrObjGen(L0758_i_SensorData)) != Thing::_none)) { _vm->_championMan->putObjectInLeaderHand(L0761_T_LeaderHandObject, true); } } @@ -204,7 +204,7 @@ bool MovesensMan::f275_sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, ui break; T0275058_ProceedToNextThing: L0763_T_LastProcessedThing = L0750_T_ThingBeingProcessed; - L0750_T_ThingBeingProcessed = _vm->_dungeonMan->f159_getNextThing(L0750_T_ThingBeingProcessed); + L0750_T_ThingBeingProcessed = _vm->_dungeonMan->getNextThing(L0750_T_ThingBeingProcessed); } f271_processRotationEffect(); return L0759_B_AtLeastOneSensorWasTriggered; @@ -245,7 +245,7 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 L0713_B_ThingLevitates = f264_isLevitating(thing); } /* If moving the party or a creature on the party map from a dungeon square then check for a projectile impact */ - if ((mapX >= 0) && ((thing == Thing::_party) || ((L0710_i_ThingType == k4_GroupThingType) && (_vm->_dungeonMan->_g272_currMapIndex == _vm->_dungeonMan->_g309_partyMapIndex)))) { + if ((mapX >= 0) && ((thing == Thing::_party) || ((L0710_i_ThingType == k4_GroupThingType) && (_vm->_dungeonMan->_currMapIndex == _vm->_dungeonMan->_partyMapIndex)))) { if (f266_moveIsKilledByProjectileImpact(mapX, mapY, destMapX, destMapY, thing)) { return true; /* The specified group thing cannot be moved because it was killed by a projectile impact */ } @@ -258,18 +258,18 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 bool L0726_B_Audible = false; if (destMapX >= 0) { - L0714_ui_MapIndexSource = L0715_ui_MapIndexDestination = _vm->_dungeonMan->_g272_currMapIndex; - L0721_B_GroupOnPartyMap = (L0714_ui_MapIndexSource == _vm->_dungeonMan->_g309_partyMapIndex) && (mapX >= 0); + L0714_ui_MapIndexSource = L0715_ui_MapIndexDestination = _vm->_dungeonMan->_currMapIndex; + L0721_B_GroupOnPartyMap = (L0714_ui_MapIndexSource == _vm->_dungeonMan->_partyMapIndex) && (mapX >= 0); uint16 L0716_ui_Direction = 0; bool L0722_B_FallKilledGroup = false; bool L0723_B_DrawDungeonViewWhileFalling = false; bool L0724_B_DestinationIsTeleporterTarget = false; if (thing == Thing::_party) { - _vm->_dungeonMan->_g306_partyMapX = destMapX; - _vm->_dungeonMan->_g307_partyMapY = destMapY; + _vm->_dungeonMan->_partyMapX = destMapX; + _vm->_dungeonMan->_partyMapY = destMapY; L0718_i_RequiredTeleporterScope = k0x0002_TelepScopeObjOrParty; L0723_B_DrawDungeonViewWhileFalling = !_vm->_inventoryMan->_g432_inventoryChampionOrdinal && !_vm->_championMan->_partyIsSleeping; - L0716_ui_Direction = _vm->_dungeonMan->_g308_partyDir; + L0716_ui_Direction = _vm->_dungeonMan->_partyDir; } else { if (L0710_i_ThingType == k4_GroupThingType) { L0718_i_RequiredTeleporterScope = k0x0001_TelepScopeCreatures; @@ -278,15 +278,15 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 } } if (L0710_i_ThingType == k14_ProjectileThingType) { - L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->f156_getThingData(thing); + L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->getThingData(thing); _g400_moveResultDir = (_vm->_timeline->_g370_events[((Projectile *)L0712_ps_Teleporter)->_eventIndex])._C._projectile.getDir(); } for (L0728_i_ChainedMoveCount = 1000; --L0728_i_ChainedMoveCount; ) { /* No more than 1000 chained moves at once (in a chain of teleporters and pits for example) */ - AL0708_i_DestinationSquare = _vm->_dungeonMan->_g271_currMapData[destMapX][destMapY]; + AL0708_i_DestinationSquare = _vm->_dungeonMan->_currMapData[destMapX][destMapY]; if ((AL0709_i_DestinationSquareType = Square(AL0708_i_DestinationSquare).getType()) == k5_ElementTypeTeleporter) { if (!getFlag(AL0708_i_DestinationSquare, k0x0008_TeleporterOpen)) break; - L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->f157_getSquareFirstThingData(destMapX, destMapY); + L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->getSquareFirstThingData(destMapX, destMapY); if ((L0712_ps_Teleporter->getScope() == k0x0001_TelepScopeCreatures) && (L0710_i_ThingType != k4_GroupThingType)) break; if ((L0718_i_RequiredTeleporterScope != (k0x0001_TelepScopeCreatures | k0x0002_TelepScopeObjOrParty)) && !getFlag(L0712_ps_Teleporter->getScope(), L0718_i_RequiredTeleporterScope)) @@ -295,18 +295,18 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 destMapX = L0712_ps_Teleporter->getTargetMapX(); destMapY = L0712_ps_Teleporter->getTargetMapY(); L0726_B_Audible = L0712_ps_Teleporter->isAudible(); - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination = L0712_ps_Teleporter->getTargetMapIndex()); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination = L0712_ps_Teleporter->getTargetMapIndex()); if (thing == Thing::_party) { - _vm->_dungeonMan->_g306_partyMapX = destMapX; - _vm->_dungeonMan->_g307_partyMapY = destMapY; + _vm->_dungeonMan->_partyMapX = destMapX; + _vm->_dungeonMan->_partyMapY = destMapY; if (L0712_ps_Teleporter->isAudible()) { - _vm->_sound->f064_SOUND_RequestPlay_CPSD(k17_soundBUZZ, _vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY, k0_soundModePlayImmediately); + _vm->_sound->f064_SOUND_RequestPlay_CPSD(k17_soundBUZZ, _vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY, k0_soundModePlayImmediately); } L0723_B_DrawDungeonViewWhileFalling = true; if (L0712_ps_Teleporter->getAbsoluteRotation()) { _vm->_championMan->setPartyDirection(L0712_ps_Teleporter->getRotation()); } else { - _vm->_championMan->setPartyDirection(normalizeModulo4(_vm->_dungeonMan->_g308_partyDir + L0712_ps_Teleporter->getRotation())); + _vm->_championMan->setPartyDirection(normalizeModulo4(_vm->_dungeonMan->_partyDir + L0712_ps_Teleporter->getRotation())); } } else { if (L0710_i_ThingType == k4_GroupThingType) { @@ -331,19 +331,19 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 if (L0723_B_DrawDungeonViewWhileFalling && !_g402_useRopeToClimbDownPit) { L0723_B_DrawDungeonViewWhileFalling = true; if (L0719_i_TraversedPitCount) { - _vm->_dungeonMan->f174_setCurrentMapAndPartyMap(L0715_ui_MapIndexDestination); + _vm->_dungeonMan->setCurrentMapAndPartyMap(L0715_ui_MapIndexDestination); _vm->_displayMan->f96_loadCurrentMapGraphics(); } L0719_i_TraversedPitCount++; - _vm->_displayMan->f128_drawDungeon(_vm->_dungeonMan->_g308_partyDir, destMapX, destMapY); /* BUG0_28 When falling through multiple pits the dungeon view is updated to show each traversed map but the graphics used for creatures, wall and floor ornaments may not be correct. The dungeon view is drawn for each map by using the graphics loaded for the source map. Therefore the graphics for creatures, wall and floor ornaments may not look like what they should */ + _vm->_displayMan->f128_drawDungeon(_vm->_dungeonMan->_partyDir, destMapX, destMapY); /* BUG0_28 When falling through multiple pits the dungeon view is updated to show each traversed map but the graphics used for creatures, wall and floor ornaments may not be correct. The dungeon view is drawn for each map by using the graphics loaded for the source map. Therefore the graphics for creatures, wall and floor ornaments may not look like what they should */ /* BUG0_71 Some timings are too short on fast computers. When the party falls in a series of pits, the dungeon view is refreshed too quickly because the execution speed is not limited */ /* BUG0_01 While drawing creatures the engine will read invalid ACTIVE_GROUP data in _vm->_groupMan->_g375_activeGroups because the data is for the creatures on the source map and not the map being drawn. The only consequence is that creatures may be drawn with incorrect bitmaps and/or directions */ } - L0715_ui_MapIndexDestination = _vm->_dungeonMan->f154_getLocationAfterLevelChange(L0715_ui_MapIndexDestination, 1, &destMapX, &destMapY); - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); + L0715_ui_MapIndexDestination = _vm->_dungeonMan->getLocationAfterLevelChange(L0715_ui_MapIndexDestination, 1, &destMapX, &destMapY); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); if (thing == Thing::_party) { - _vm->_dungeonMan->_g306_partyMapX = destMapX; - _vm->_dungeonMan->_g307_partyMapY = destMapY; + _vm->_dungeonMan->_partyMapX = destMapX; + _vm->_dungeonMan->_partyMapY = destMapY; if (_vm->_championMan->_partyChampionCount > 0) { if (_g402_useRopeToClimbDownPit) { for (AL0709_i_ChampionIndex = k0_ChampionFirst, L0711_ps_Champion = _vm->_championMan->_champions; AL0709_i_ChampionIndex < _vm->_championMan->_partyChampionCount; AL0709_i_ChampionIndex++, L0711_ps_Champion++) { @@ -353,16 +353,16 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 } } else { if (_vm->_championMan->getDamagedChampionCount(20, k0x0010_ChampionWoundLegs | k0x0020_ChampionWoundFeet, k2_attackType_SELF)) { - _vm->_sound->f064_SOUND_RequestPlay_CPSD(k06_soundSCREAM, _vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY, k0_soundModePlayImmediately); + _vm->_sound->f064_SOUND_RequestPlay_CPSD(k06_soundSCREAM, _vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY, k0_soundModePlayImmediately); } } } _g402_useRopeToClimbDownPit = false; } else { if (L0710_i_ThingType == k4_GroupThingType) { - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); - AL0727_ui_Outcome = _vm->_groupMan->f191_getDamageAllCreaturesOutcome((Group *)_vm->_dungeonMan->f156_getThingData(thing), mapX, mapY, 20, false); - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); + AL0727_ui_Outcome = _vm->_groupMan->f191_getDamageAllCreaturesOutcome((Group *)_vm->_dungeonMan->getThingData(thing), mapX, mapY, 20, false); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); L0722_B_FallKilledGroup = (AL0727_ui_Outcome == k2_outcomeKilledAllCreaturesInGroup); if (L0722_B_FallKilledGroup) break; @@ -374,10 +374,10 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 } else { if ((AL0709_i_DestinationSquareType == k3_ElementTypeStairs) && (thing != Thing::_party) && (L0710_i_ThingType != k14_ProjectileThingType)) { if (!getFlag(AL0708_i_DestinationSquare, k0x0004_StairsUp)) { - L0715_ui_MapIndexDestination = _vm->_dungeonMan->f154_getLocationAfterLevelChange(L0715_ui_MapIndexDestination, 1, &destMapX, &destMapY); - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); + L0715_ui_MapIndexDestination = _vm->_dungeonMan->getLocationAfterLevelChange(L0715_ui_MapIndexDestination, 1, &destMapX, &destMapY); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); } - L0716_ui_Direction = _vm->_dungeonMan->f155_getStairsExitDirection(destMapX, destMapY); + L0716_ui_Direction = _vm->_dungeonMan->getStairsExitDirection(destMapX, destMapY); destMapX += _vm->_dirIntoStepCountEast[L0716_ui_Direction], destMapY += _vm->_dirIntoStepCountNorth[L0716_ui_Direction]; L0716_ui_Direction = returnOppositeDir((Direction)L0716_ui_Direction); AL0727_ui_ThingCell = thing.getCell(); @@ -388,10 +388,10 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 } } } - if ((L0710_i_ThingType == k4_GroupThingType) && (L0722_B_FallKilledGroup || !_vm->_dungeonMan->f139_isCreatureAllowedOnMap(thing, L0715_ui_MapIndexDestination))) { + if ((L0710_i_ThingType == k4_GroupThingType) && (L0722_B_FallKilledGroup || !_vm->_dungeonMan->isCreatureAllowedOnMap(thing, L0715_ui_MapIndexDestination))) { _vm->_groupMan->f187_dropMovingCreatureFixedPossession(thing, destMapX, destMapY); _vm->_groupMan->f188_dropGroupPossessions(destMapX, destMapY, thing, k2_soundModePlayOneTickLater); - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); if (mapX >= 0) { _vm->_groupMan->f189_delete(mapX, mapY); } @@ -404,7 +404,7 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 L0725_B_PartySquare = (L0715_ui_MapIndexDestination == L0714_ui_MapIndexSource) && (destMapX == mapX) && (destMapY == mapY); if (L0725_B_PartySquare) { if (thing == Thing::_party) { - if (_vm->_dungeonMan->_g308_partyDir == L0716_ui_Direction) { + if (_vm->_dungeonMan->_partyDir == L0716_ui_Direction) { return false; } } else { @@ -436,7 +436,7 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 AL0708_i_DestinationSquare = AL0727_ui_Backup; } if (L0715_ui_MapIndexDestination != L0714_ui_MapIndexSource) { - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); } } } @@ -445,32 +445,32 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 f276_sensorProcessThingAdditionOrRemoval(mapX, mapY, Thing::_party, L0725_B_PartySquare, false); } else { if (L0713_B_ThingLevitates) { - _vm->_dungeonMan->f164_unlinkThingFromList(thing, Thing(0), mapX, mapY); + _vm->_dungeonMan->unlinkThingFromList(thing, Thing(0), mapX, mapY); } else { - f276_sensorProcessThingAdditionOrRemoval(mapX, mapY, thing, (_vm->_dungeonMan->_g272_currMapIndex == _vm->_dungeonMan->_g309_partyMapIndex) && (mapX == _vm->_dungeonMan->_g306_partyMapX) && (mapY == _vm->_dungeonMan->_g307_partyMapY), false); + f276_sensorProcessThingAdditionOrRemoval(mapX, mapY, thing, (_vm->_dungeonMan->_currMapIndex == _vm->_dungeonMan->_partyMapIndex) && (mapX == _vm->_dungeonMan->_partyMapX) && (mapY == _vm->_dungeonMan->_partyMapY), false); } } } if (destMapX >= 0) { if (thing == Thing::_party) { - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); - if ((thing = _vm->_groupMan->f175_groupGetThing(_vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY)) != Thing::_endOfList) { /* Delete group if party moves onto its square */ - _vm->_groupMan->f188_dropGroupPossessions(_vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY, thing, k1_soundModePlayIfPrioritized); - _vm->_groupMan->f189_delete(_vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); + if ((thing = _vm->_groupMan->f175_groupGetThing(_vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY)) != Thing::_endOfList) { /* Delete group if party moves onto its square */ + _vm->_groupMan->f188_dropGroupPossessions(_vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY, thing, k1_soundModePlayIfPrioritized); + _vm->_groupMan->f189_delete(_vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY); } if (L0715_ui_MapIndexDestination == L0714_ui_MapIndexSource) { - f276_sensorProcessThingAdditionOrRemoval(_vm->_dungeonMan->_g306_partyMapX, _vm->_dungeonMan->_g307_partyMapY, Thing::_party, L0725_B_PartySquare, true); + f276_sensorProcessThingAdditionOrRemoval(_vm->_dungeonMan->_partyMapX, _vm->_dungeonMan->_partyMapY, Thing::_party, L0725_B_PartySquare, true); } else { - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); _vm->_newPartyMapIndex = L0715_ui_MapIndexDestination; } } else { if (L0710_i_ThingType == k4_GroupThingType) { - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); - L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->f156_getThingData(thing); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); + L0712_ps_Teleporter = (Teleporter *)_vm->_dungeonMan->getThingData(thing); AL0708_i_ActiveGroupIndex = ((Group *)L0712_ps_Teleporter)->getActiveGroupIndex(); - if (((L0715_ui_MapIndexDestination == _vm->_dungeonMan->_g309_partyMapIndex) && (destMapX == _vm->_dungeonMan->_g306_partyMapX) && (destMapY == _vm->_dungeonMan->_g307_partyMapY)) || (_vm->_groupMan->f175_groupGetThing(destMapX, destMapY) != Thing::_endOfList)) { /* If a group tries to move to the party square or over another group then create an event to move the group later */ - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + if (((L0715_ui_MapIndexDestination == _vm->_dungeonMan->_partyMapIndex) && (destMapX == _vm->_dungeonMan->_partyMapX) && (destMapY == _vm->_dungeonMan->_partyMapY)) || (_vm->_groupMan->f175_groupGetThing(destMapX, destMapY) != Thing::_endOfList)) { /* If a group tries to move to the party square or over another group then create an event to move the group later */ + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); if (mapX >= 0) { _vm->_groupMan->f181_groupDeleteEvents(mapX, mapY); } @@ -480,28 +480,28 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 f265_createEvent60to61_moveGroup(thing, destMapX, destMapY, L0715_ui_MapIndexDestination, L0726_B_Audible); return true; /* The specified group thing cannot be moved because the party or another group is on the destination square */ } - L1638_ui_MovementSoundIndex = f514_getSound(((Group *)_vm->_dungeonMan->_g284_thingData[k4_GroupThingType])[thing.getIndex()]._type); + L1638_ui_MovementSoundIndex = f514_getSound(((Group *)_vm->_dungeonMan->_thingData[k4_GroupThingType])[thing.getIndex()]._type); if (L1638_ui_MovementSoundIndex < k34_D13_soundCount) { _vm->_sound->f064_SOUND_RequestPlay_CPSD(L1638_ui_MovementSoundIndex, destMapX, destMapY, k1_soundModePlayIfPrioritized); } - if (L0721_B_GroupOnPartyMap && (L0715_ui_MapIndexDestination != _vm->_dungeonMan->_g309_partyMapIndex)) { /* If the group leaves the party map */ + if (L0721_B_GroupOnPartyMap && (L0715_ui_MapIndexDestination != _vm->_dungeonMan->_partyMapIndex)) { /* If the group leaves the party map */ _vm->_groupMan->f184_removeActiveGroup(AL0708_i_ActiveGroupIndex); L0720_ui_MoveGroupResult = true; } else { - if ((L0715_ui_MapIndexDestination == _vm->_dungeonMan->_g309_partyMapIndex) && (!L0721_B_GroupOnPartyMap)) { /* If the group arrives on the party map */ + if ((L0715_ui_MapIndexDestination == _vm->_dungeonMan->_partyMapIndex) && (!L0721_B_GroupOnPartyMap)) { /* If the group arrives on the party map */ _vm->_groupMan->f183_addActiveGroup(thing, destMapX, destMapY); L0720_ui_MoveGroupResult = true; } } if (L0713_B_ThingLevitates) { - _vm->_dungeonMan->f163_linkThingToList(thing, Thing(0), destMapX, destMapY); + _vm->_dungeonMan->linkThingToList(thing, Thing(0), destMapX, destMapY); } else { f276_sensorProcessThingAdditionOrRemoval(destMapX, destMapY, thing, false, true); } if (L0720_ui_MoveGroupResult || (mapX < 0)) { /* If group moved from one map to another or if it was just placed on a square */ _vm->_groupMan->f180_startWanedring(destMapX, destMapY); } - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); if (mapX >= 0) { if (L0720_ui_MoveGroupResult > 1) { /* If the group behavior was C6_BEHAVIOR_ATTACK before being teleported from and to the party map */ _vm->_groupMan->f182_stopAttacking(&_vm->_groupMan->_g375_activeGroups[L0720_ui_MoveGroupResult - 2], mapX, mapY); @@ -513,13 +513,13 @@ bool MovesensMan::f267_getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 } return L0720_ui_MoveGroupResult; } - _vm->_dungeonMan->f173_setCurrentMap(L0715_ui_MapIndexDestination); + _vm->_dungeonMan->setCurrentMap(L0715_ui_MapIndexDestination); if (L0710_i_ThingType == k14_ProjectileThingType) { /* BUG0_29 An explosion can trigger a floor sensor. Explosions do not trigger floor sensors on the square where they are created. However, if an explosion is moved by a teleporter (or by falling into a pit, see BUG0_26) after it was created, it can trigger floor sensors on the destination square. This is because explosions are not considered as levitating in the code, while projectiles are. The condition here should be (L0713_B_ThingLevitates) so that explosions would not start sensor processing on their destination square as they should be Levitating. This would work if F0264_MOVE_IsLevitating returned true for explosions (see BUG0_26) */ - _vm->_dungeonMan->f163_linkThingToList(thing, Thing(0), destMapX, destMapY); + _vm->_dungeonMan->linkThingToList(thing, Thing(0), destMapX, destMapY); } else { - f276_sensorProcessThingAdditionOrRemoval(destMapX, destMapY, thing, (_vm->_dungeonMan->_g272_currMapIndex == _vm->_dungeonMan->_g309_partyMapIndex) && (destMapX == _vm->_dungeonMan->_g306_partyMapX) && (destMapY == _vm->_dungeonMan->_g307_partyMapY), true); + f276_sensorProcessThingAdditionOrRemoval(destMapX, destMapY, thing, (_vm->_dungeonMan->_currMapIndex == _vm->_dungeonMan->_partyMapIndex) && (destMapX == _vm->_dungeonMan->_partyMapX) && (destMapY == _vm->_dungeonMan->_partyMapY), true); } - _vm->_dungeonMan->f173_setCurrentMap(L0714_ui_MapIndexSource); + _vm->_dungeonMan->setCurrentMap(L0714_ui_MapIndexSource); } } return false; @@ -530,7 +530,7 @@ bool MovesensMan::f264_isLevitating(Thing thing) { if ((L0695_i_ThingType = thing.getType()) == k4_GroupThingType) { - return getFlag(_vm->_dungeonMan->f144_getCreatureAttributes(thing), k0x0020_MaskCreatureInfo_levitation); + return getFlag(_vm->_dungeonMan->getCreatureAttributes(thing), k0x0020_MaskCreatureInfo_levitation); } if (L0695_i_ThingType == k14_ProjectileThingType) { /* BUG0_26 An explosion may fall in a pit. If a pit is opened while there is an explosion above then the explosion falls into the pit in F0267_MOVE_GetMoveResult_CPSCE. Explosions are not considered as levitating so they are moved when the pit is opened. This function should return true for explosions */ return true; @@ -572,7 +572,7 @@ bool MovesensMan::f266_moveIsKilledByProjectileImpact(int16 srcMapX, int16 srcMa } } else { L0702_i_ImpactType = kM1_CreatureElemType; - L0701_ps_Group = (Group *)_vm->_dungeonMan->f156_getThingData(thing); + L0701_ps_Group = (Group *)_vm->_dungeonMan->getThingData(thing); for (AL0699_ui_Cell = k0_CellNorthWest, AL0700_B_CreatureAlive = false; AL0699_ui_Cell < k3_CellSouthWest + 1; AL0699_ui_Cell++) { AL0700_B_CreatureAlive |= L0701_ps_Group->_health[AL0699_ui_Cell]; if (_vm->_groupMan->f176_getCreatureOrdinalInCell(L0701_ps_Group, AL0699_ui_Cell)) { @@ -608,10 +608,10 @@ bool MovesensMan::f266_moveIsKilledByProjectileImpact(int16 srcMapX, int16 srcMa L0704_ui_ProjectileMapX = srcMapX; /* Check impacts with projectiles on the source square */ L0705_ui_ProjectileMapY = srcMapY; T0266017_CheckProjectileImpacts: - L0697_T_Thing = _vm->_dungeonMan->f161_getSquareFirstThing(L0704_ui_ProjectileMapX, L0705_ui_ProjectileMapY); + L0697_T_Thing = _vm->_dungeonMan->getSquareFirstThing(L0704_ui_ProjectileMapX, L0705_ui_ProjectileMapY); while (L0697_T_Thing != Thing::_endOfList) { if (((L0697_T_Thing).getType() == k14_ProjectileThingType) && - (_vm->_timeline->_g370_events[(((Projectile *)_vm->_dungeonMan->_g284_thingData[k14_ProjectileThingType])[(L0697_T_Thing).getIndex()])._eventIndex]._type != k48_TMEventTypeMoveProjectileIgnoreImpacts) && (AL0699_ui_ChampionOrCreatureOrdinal = L0707_auc_ChampionOrCreatureOrdinalInCell[(L0697_T_Thing).getCell()]) && + (_vm->_timeline->_g370_events[(((Projectile *)_vm->_dungeonMan->_thingData[k14_ProjectileThingType])[(L0697_T_Thing).getIndex()])._eventIndex]._type != k48_TMEventTypeMoveProjectileIgnoreImpacts) && (AL0699_ui_ChampionOrCreatureOrdinal = L0707_auc_ChampionOrCreatureOrdinalInCell[(L0697_T_Thing).getCell()]) && _vm->_projexpl->f217_projectileHasImpactOccurred(L0702_i_ImpactType, srcMapX, srcMapY, _vm->ordinalToIndex(AL0699_ui_ChampionOrCreatureOrdinal), L0697_T_Thing)) { _vm->_projexpl->f214_projectileDeleteEvent(L0697_T_Thing); if (_vm->_projexpl->_g364_creatureDamageOutcome == k2_outcomeKilledAllCreaturesInGroup) { @@ -619,7 +619,7 @@ T0266017_CheckProjectileImpacts: } goto T0266017_CheckProjectileImpacts; } - L0697_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0697_T_Thing); + L0697_T_Thing = _vm->_dungeonMan->getNextThing(L0697_T_Thing); } if (L0703_B_CheckDestinationSquareProjectileImpacts) { srcMapX |= ((L0704_ui_ProjectileMapX = destMapX) + 1) << 8; /* Check impacts with projectiles on the destination square */ @@ -635,7 +635,7 @@ T0266017_CheckProjectileImpacts: void MovesensMan::f268_addEvent(byte type, byte mapX, byte mapY, byte cell, byte effect, int32 time) { TimelineEvent L0729_s_Event; - setMapAndTime(L0729_s_Event._mapTime, _vm->_dungeonMan->_g272_currMapIndex, time); + setMapAndTime(L0729_s_Event._mapTime, _vm->_dungeonMan->_currMapIndex, time); L0729_s_Event._type = type; L0729_s_Event._priority = 0; L0729_s_Event._B._location._mapX = mapX; @@ -702,7 +702,7 @@ int16 MovesensMan::f262_getTeleporterRotatedGroupResult(Teleporter* teleporter, int16 L0691_i_CreatureSize; int16 L0692_i_RelativeRotation; - L0686_ps_Group = (Group *)_vm->_dungeonMan->f156_getThingData(thing); + L0686_ps_Group = (Group *)_vm->_dungeonMan->getThingData(thing); L0683_i_Rotation = teleporter->getRotation(); L0684_ui_GroupDirections = _vm->_groupMan->f147_getGroupDirections(L0686_ps_Group, mapIndex); @@ -732,9 +732,9 @@ int16 MovesensMan::f262_getTeleporterRotatedGroupResult(Teleporter* teleporter, L0690_ui_GroupCells >>= 2; } } - _vm->_dungeonMan->f148_setGroupDirections(L0686_ps_Group, L0685_ui_UpdatedGroupDirections, mapIndex); - _vm->_dungeonMan->f146_setGroupCells(L0686_ps_Group, L0687_ui_UpdatedGroupCells, mapIndex); - if ((mapIndex == _vm->_dungeonMan->_g309_partyMapIndex) && (L0686_ps_Group->setBehaviour(k6_behavior_ATTACK))) { + _vm->_dungeonMan->setGroupDirections(L0686_ps_Group, L0685_ui_UpdatedGroupDirections, mapIndex); + _vm->_dungeonMan->setGroupCells(L0686_ps_Group, L0687_ui_UpdatedGroupCells, mapIndex); + if ((mapIndex == _vm->_dungeonMan->_partyMapIndex) && (L0686_ps_Group->setBehaviour(k6_behavior_ATTACK))) { return L0686_ps_Group->getActiveGroupIndex() + 2; } return 1; @@ -781,24 +781,24 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m L0774_i_ObjectType = kM1_IconIndiceNone; } if ((!addThing) && (L0767_i_ThingType != kM1_PartyThingType)) { - _vm->_dungeonMan->f164_unlinkThingFromList(thing, Thing(0), mapX, mapY); + _vm->_dungeonMan->unlinkThingFromList(thing, Thing(0), mapX, mapY); } - L0777_ui_Square = _vm->_dungeonMan->_g271_currMapData[mapX][mapY]; + L0777_ui_Square = _vm->_dungeonMan->_currMapData[mapX][mapY]; if (Square(L0777_ui_Square).getType() == k0_WallElemType) { L0770_ui_SensorTriggeredCell = thing.getCell(); } else { L0770_ui_SensorTriggeredCell = kM1_CellAny; // this will wrap around } L0772_B_SquareContainsObject = L0773_B_SquareContainsGroup = L0775_B_SquareContainsThingOfSameType = L0776_B_SquareContainsThingOfDifferentType = false; - L0766_T_Thing = _vm->_dungeonMan->f161_getSquareFirstThing(mapX, mapY); + L0766_T_Thing = _vm->_dungeonMan->getSquareFirstThing(mapX, mapY); if (L0770_ui_SensorTriggeredCell == kM1_CellAny) { while (L0766_T_Thing != Thing::_endOfList) { if ((L0771_ui_ThingType = (L0766_T_Thing).getType()) == k4_GroupThingType) { L0773_B_SquareContainsGroup = true; } else { if ((L0771_ui_ThingType == k2_TextstringType) && (L0767_i_ThingType == kM1_PartyThingType) && addThing && !partySquare) { - _vm->_dungeonMan->f168_decodeText(_vm->_stringBuildBuffer, L0766_T_Thing, k1_TextTypeMessage); + _vm->_dungeonMan->decodeText(_vm->_stringBuildBuffer, L0766_T_Thing, k1_TextTypeMessage); _vm->_textMan->f47_messageAreaPrintMessage(k15_ColorWhite, _vm->_stringBuildBuffer); } else { if ((L0771_ui_ThingType > k4_GroupThingType) && (L0771_ui_ThingType < k14_ProjectileThingType)) { @@ -808,7 +808,7 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m } } } - L0766_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0766_T_Thing); + L0766_T_Thing = _vm->_dungeonMan->getNextThing(L0766_T_Thing); } } else { while (L0766_T_Thing != Thing::_endOfList) { @@ -817,17 +817,17 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m L0775_B_SquareContainsThingOfSameType |= (_vm->_objectMan->f32_getObjectType(L0766_T_Thing) == L0774_i_ObjectType); L0776_B_SquareContainsThingOfDifferentType |= (_vm->_objectMan->f32_getObjectType(L0766_T_Thing) != L0774_i_ObjectType); } - L0766_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0766_T_Thing); + L0766_T_Thing = _vm->_dungeonMan->getNextThing(L0766_T_Thing); } } if (addThing && (L0767_i_ThingType != kM1_PartyThingType)) { - _vm->_dungeonMan->f163_linkThingToList(thing, Thing(0), mapX, mapY); + _vm->_dungeonMan->linkThingToList(thing, Thing(0), mapX, mapY); } - L0766_T_Thing = _vm->_dungeonMan->f161_getSquareFirstThing(mapX, mapY); + L0766_T_Thing = _vm->_dungeonMan->getSquareFirstThing(mapX, mapY); while (L0766_T_Thing != Thing::_endOfList) { L0771_ui_ThingType = (L0766_T_Thing).getType(); if (L0771_ui_ThingType == k3_SensorThingType) { - L0769_ps_Sensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0766_T_Thing); + L0769_ps_Sensor = (Sensor *)_vm->_dungeonMan->getThingData(L0766_T_Thing); if ((L0769_ps_Sensor)->getType() == k0_SensorDisabled) goto T0276079; L0779_i_SensorData = L0769_ps_Sensor->getData(); @@ -852,7 +852,7 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m if (!addThing) { L0768_B_TriggerSensor = false; } else { - L0768_B_TriggerSensor = (L0779_i_SensorData == _vm->indexToOrdinal(_vm->_dungeonMan->_g308_partyDir)); + L0768_B_TriggerSensor = (L0779_i_SensorData == _vm->indexToOrdinal(_vm->_dungeonMan->_partyDir)); } } break; @@ -904,14 +904,14 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m goto T0276079; } } - L0768_B_TriggerSensor ^= L0769_ps_Sensor->getRevertEffectA(); - L0778_i_Effect = L0769_ps_Sensor->getEffectA(); + L0768_B_TriggerSensor ^= L0769_ps_Sensor->getAttrRevertEffectA(); + L0778_i_Effect = L0769_ps_Sensor->getAttrEffectA(); if (L0778_i_Effect == k3_SensorEffHold) { L0778_i_Effect = L0768_B_TriggerSensor ? k0_SensorEffSet : k1_SensorEffClear; } else if (!L0768_B_TriggerSensor) goto T0276079; - if (L0769_ps_Sensor->getAudibleA()) + if (L0769_ps_Sensor->getAttrAudibleA()) _vm->_sound->f064_SOUND_RequestPlay_CPSD(k01_soundSWITCH, mapX, mapY, k1_soundModePlayIfPrioritized); f272_sensorTriggerEffect(L0769_ps_Sensor, L0778_i_Effect, mapX, mapY, (uint16)kM1_CellAny); // this will wrap around @@ -920,7 +920,7 @@ void MovesensMan::f276_sensorProcessThingAdditionOrRemoval(uint16 mapX, uint16 m if (L0771_ui_ThingType >= k4_GroupThingType) break; T0276079: - L0766_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0766_T_Thing); + L0766_T_Thing = _vm->_dungeonMan->getNextThing(L0766_T_Thing); } f271_processRotationEffect(); } @@ -948,13 +948,13 @@ T0274003: return true; } if (L0747_i_ObjectType == k144_IconIndiceContainerChestClosed) { - L0749_ps_Container = (Container *)_vm->_dungeonMan->f156_getThingData(L0744_T_Thing); + L0749_ps_Container = (Container *)_vm->_dungeonMan->getThingData(L0744_T_Thing); L0744_T_Thing = L0749_ps_Container->getSlot(); while (L0744_T_Thing != Thing::_endOfList) { if (_vm->_objectMan->f32_getObjectType(L0744_T_Thing) == objectType) { return true; } - L0744_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0744_T_Thing); + L0744_T_Thing = _vm->_dungeonMan->getNextThing(L0744_T_Thing); } } } @@ -985,18 +985,18 @@ void MovesensMan::f272_sensorTriggerEffect(Sensor* sensor, int16 effect, int16 m uint16 L0740_ui_TargetCell; - if (sensor->getOnlyOnce()) { + if (sensor->getAttrOnlyOnce()) { sensor->setTypeDisabled(); } - L0738_l_Time = _vm->_gameTime + sensor->getValue(); - if (sensor->getLocalEffect()) { - f270_sensorTriggetLocalEffect(sensor->M49_localEffect(), mapX, mapY, cell); + L0738_l_Time = _vm->_gameTime + sensor->getAttrValue(); + if (sensor->getAttrLocalEffect()) { + f270_sensorTriggetLocalEffect(sensor->getActionLocalEffect(), mapX, mapY, cell); } else { - L0736_i_TargetMapX = sensor->getTargetMapX(); - L0737_i_TargetMapY = sensor->getTargetMapY(); - L0739_ui_SquareType = Square(_vm->_dungeonMan->_g271_currMapData[L0736_i_TargetMapX][L0737_i_TargetMapY]).getType(); + L0736_i_TargetMapX = sensor->getActionTargetMapX(); + L0737_i_TargetMapY = sensor->getActionTargetMapY(); + L0739_ui_SquareType = Square(_vm->_dungeonMan->_currMapData[L0736_i_TargetMapX][L0737_i_TargetMapY]).getType(); if (L0739_ui_SquareType == k0_ElementTypeWall) { - L0740_ui_TargetCell = sensor->getTargetCell(); + L0740_ui_TargetCell = sensor->getActionTargetCell(); } else { L0740_ui_TargetCell = k0_CellNorthWest; } @@ -1045,25 +1045,25 @@ void MovesensMan::f271_processRotationEffect() { switch (_g403_sensorRotationEffect) { case k1_SensorEffClear: case k2_SensorEffToggle: - L0732_T_FirstSensorThing = _vm->_dungeonMan->f161_getSquareFirstThing(_g404_sensorRotationEffMapX, _g405_sensorRotationEffMapY); + L0732_T_FirstSensorThing = _vm->_dungeonMan->getSquareFirstThing(_g404_sensorRotationEffMapX, _g405_sensorRotationEffMapY); while (((L0732_T_FirstSensorThing).getType() != k3_SensorThingType) || ((_g406_sensorRotationEffCell != kM1_CellAny) && ((L0732_T_FirstSensorThing).getCell() != _g406_sensorRotationEffCell))) { - L0732_T_FirstSensorThing = _vm->_dungeonMan->f159_getNextThing(L0732_T_FirstSensorThing); + L0732_T_FirstSensorThing = _vm->_dungeonMan->getNextThing(L0732_T_FirstSensorThing); } - L0734_ps_FirstSensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0732_T_FirstSensorThing); + L0734_ps_FirstSensor = (Sensor *)_vm->_dungeonMan->getThingData(L0732_T_FirstSensorThing); L0733_T_LastSensorThing = L0734_ps_FirstSensor->getNextThing(); while ((L0733_T_LastSensorThing != Thing::_endOfList) && (((L0733_T_LastSensorThing).getType() != k3_SensorThingType) || ((_g406_sensorRotationEffCell != kM1_CellAny) && ((L0733_T_LastSensorThing).getCell() != _g406_sensorRotationEffCell)))) { - L0733_T_LastSensorThing = _vm->_dungeonMan->f159_getNextThing(L0733_T_LastSensorThing); + L0733_T_LastSensorThing = _vm->_dungeonMan->getNextThing(L0733_T_LastSensorThing); } if (L0733_T_LastSensorThing == Thing::_endOfList) break; - _vm->_dungeonMan->f164_unlinkThingFromList(L0732_T_FirstSensorThing, Thing(0), _g404_sensorRotationEffMapX, _g405_sensorRotationEffMapY); - L0735_ps_LastSensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0733_T_LastSensorThing); - L0733_T_LastSensorThing = _vm->_dungeonMan->f159_getNextThing(L0733_T_LastSensorThing); + _vm->_dungeonMan->unlinkThingFromList(L0732_T_FirstSensorThing, Thing(0), _g404_sensorRotationEffMapX, _g405_sensorRotationEffMapY); + L0735_ps_LastSensor = (Sensor *)_vm->_dungeonMan->getThingData(L0733_T_LastSensorThing); + L0733_T_LastSensorThing = _vm->_dungeonMan->getNextThing(L0733_T_LastSensorThing); while (((L0733_T_LastSensorThing != Thing::_endOfList) && ((L0733_T_LastSensorThing).getType() == k3_SensorThingType))) { if ((_g406_sensorRotationEffCell == kM1_CellAny) || ((L0733_T_LastSensorThing).getCell() == _g406_sensorRotationEffCell)) { - L0735_ps_LastSensor = (Sensor *)_vm->_dungeonMan->f156_getThingData(L0733_T_LastSensorThing); + L0735_ps_LastSensor = (Sensor *)_vm->_dungeonMan->getThingData(L0733_T_LastSensorThing); } - L0733_T_LastSensorThing = _vm->_dungeonMan->f159_getNextThing(L0733_T_LastSensorThing); + L0733_T_LastSensorThing = _vm->_dungeonMan->getNextThing(L0733_T_LastSensorThing); } L0734_ps_FirstSensor->setNextThing(L0735_ps_LastSensor->getNextThing()); L0735_ps_LastSensor->setNextThing(L0732_T_FirstSensorThing); @@ -1087,14 +1087,14 @@ Thing MovesensMan::f273_sensorGetObjectOfTypeInCell(int16 mapX, int16 mapY, int1 Thing L0741_T_Thing; - L0741_T_Thing = _vm->_dungeonMan->f162_getSquareFirstObject(mapX, mapY); + L0741_T_Thing = _vm->_dungeonMan->getSquareFirstObject(mapX, mapY); while (L0741_T_Thing != Thing::_endOfList) { if (_vm->_objectMan->f32_getObjectType(L0741_T_Thing) == objectType) { if ((cell == kM1_CellAny) || ((L0741_T_Thing.getCell()) == cell)) { return L0741_T_Thing; } } - L0741_T_Thing = _vm->_dungeonMan->f159_getNextThing(L0741_T_Thing); + L0741_T_Thing = _vm->_dungeonMan->getNextThing(L0741_T_Thing); } return Thing::_none; } |