mirror of
https://github.com/libretro/scummvm.git
synced 2024-12-15 14:18:37 +00:00
DM: Fix comparison warnings
This commit is contained in:
parent
efe44f1eb0
commit
c673c5654b
@ -1286,11 +1286,11 @@ bool MenuMan::isActionPerformed(uint16 champIndex, int16 actionIndex) {
|
||||
break;
|
||||
case kDMActionFreezeLife: {
|
||||
int16 freezeTicks;
|
||||
if (weaponInHand->getType() == k42_JunkTypeMagicalBoxBlue) {
|
||||
if (weaponInHand->getType() == (int)k42_JunkTypeMagicalBoxBlue) {
|
||||
freezeTicks = 30;
|
||||
_vm->_championMan->getObjectRemovedFromSlot(champIndex, kDMSlotActionHand);
|
||||
weaponInHand->setNextThing(Thing::_none);
|
||||
} else if (weaponInHand->getType() == k43_JunkTypeMagicalBoxGreen) {
|
||||
} else if (weaponInHand->getType() == (int)k43_JunkTypeMagicalBoxGreen) {
|
||||
freezeTicks = 125;
|
||||
_vm->_championMan->getObjectRemovedFromSlot(champIndex, kDMSlotActionHand);
|
||||
weaponInHand->setNextThing(Thing::_none);
|
||||
@ -1308,7 +1308,7 @@ bool MenuMan::isActionPerformed(uint16 champIndex, int16 actionIndex) {
|
||||
break;
|
||||
case kDMActionThrow:
|
||||
setChampionDirectionToPartyDirection(curChampion);
|
||||
actionPerformed = _vm->_championMan->isObjectThrown(champIndex, kDMSlotActionHand, (curChampion->_cell == _vm->turnDirRight(_vm->_dungeonMan->_partyDir)) || (curChampion->_cell == (ViewCell)_vm->returnOppositeDir(_vm->_dungeonMan->_partyDir)));
|
||||
actionPerformed = _vm->_championMan->isObjectThrown(champIndex, kDMSlotActionHand, (curChampion->_cell == (ViewCell)_vm->turnDirRight(_vm->_dungeonMan->_partyDir)) || (curChampion->_cell == (ViewCell)_vm->returnOppositeDir(_vm->_dungeonMan->_partyDir)));
|
||||
if (actionPerformed)
|
||||
_vm->_timeline->_events[curChampion->_enableActionEventIndex]._Bu._slotOrdinal = _vm->indexToOrdinal(kDMSlotActionHand);
|
||||
break;
|
||||
|
@ -264,7 +264,7 @@ bool MovesensMan::getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 destM
|
||||
for (int16 chainedMoveCount = 1000; --chainedMoveCount; ) {
|
||||
destinationSquareData = _vm->_dungeonMan->_currMapData[destMapX][destMapY];
|
||||
SquareType destinationSquareType = Square(destinationSquareData).getType();
|
||||
if (destinationSquareType == kDMElementTypeTeleporter) {
|
||||
if (destinationSquareType == (int)kDMElementTypeTeleporter) {
|
||||
if (!getFlag(destinationSquareData, k0x0008_TeleporterOpen))
|
||||
break;
|
||||
|
||||
@ -307,7 +307,7 @@ bool MovesensMan::getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 destM
|
||||
if (destinationIsTeleporterTarget)
|
||||
break;
|
||||
} else {
|
||||
if ((destinationSquareType == kDMElementTypePit) && !thingLevitates && getFlag(destinationSquareData, k0x0008_PitOpen) && !getFlag(destinationSquareData, k0x0001_PitImaginary)) {
|
||||
if ((destinationSquareType == (int)kDMElementTypePit) && !thingLevitates && getFlag(destinationSquareData, k0x0008_PitOpen) && !getFlag(destinationSquareData, k0x0001_PitImaginary)) {
|
||||
if (drawDungeonViewWhileFalling && !_useRopeToClimbDownPit) {
|
||||
drawDungeonViewWhileFalling = true;
|
||||
if (traversedPitCount) {
|
||||
@ -346,7 +346,7 @@ bool MovesensMan::getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 destM
|
||||
if (outcome == k1_outcomeKilledSomeCreaturesInGroup)
|
||||
_vm->_groupMan->dropMovingCreatureFixedPossession(thing, destMapX, destMapY);
|
||||
}
|
||||
} else if ((destinationSquareType == kDMElementTypeStairs) && (thing != Thing::_party) && (thingType != kDMThingTypeProjectile)) {
|
||||
} else if ((destinationSquareType == (int)kDMElementTypeStairs) && (thing != Thing::_party) && (thingType != kDMThingTypeProjectile)) {
|
||||
if (!getFlag(destinationSquareData, k0x0004_StairsUp)) {
|
||||
mapIndexDestination = _vm->_dungeonMan->getLocationAfterLevelChange(mapIndexDestination, 1, &destMapX, &destMapY);
|
||||
_vm->_dungeonMan->setCurrentMap(mapIndexDestination);
|
||||
@ -916,7 +916,7 @@ void MovesensMan::triggerEffect(Sensor *sensor, int16 effect, int16 mapX, int16
|
||||
int16 targetMapY = sensor->getActionTargetMapY();
|
||||
SquareType curSquareType = Square(_vm->_dungeonMan->_currMapData[targetMapX][targetMapY]).getType();
|
||||
uint16 targetCell;
|
||||
if (curSquareType == kDMElementTypeWall)
|
||||
if (curSquareType == (int)kDMElementTypeWall)
|
||||
targetCell = sensor->getActionTargetCell();
|
||||
else
|
||||
targetCell = kDMCellNorthWest;
|
||||
|
Loading…
Reference in New Issue
Block a user