Skip to content

Commit

Permalink
DM: Rename some more enums
Browse files Browse the repository at this point in the history
  • Loading branch information
Strangerke committed Sep 18, 2016
1 parent 94cee9d commit 8bdabc1
Show file tree
Hide file tree
Showing 15 changed files with 74 additions and 71 deletions.
10 changes: 5 additions & 5 deletions engines/dm/champion.cpp
Expand Up @@ -440,7 +440,7 @@ bool ChampionMan::hasObjectIconInSlotBoxChanged(int16 slotBoxIndex, Thing thing)
|| (currIconIndex == kDMIconIndicePotionEmptyFlask)) {
IconIndice newIconIndex = objMan.getIconIndex(thing);
if (newIconIndex != currIconIndex) {
if ((slotBoxIndex < k8_SlotBoxInventoryFirstSlot) && !_mousePointerHiddenToDrawChangedObjIconOnScreen) {
if ((slotBoxIndex < kDMSlotBoxInventoryFirstSlot) && !_mousePointerHiddenToDrawChangedObjIconOnScreen) {
_mousePointerHiddenToDrawChangedObjIconOnScreen = true;
_vm->_eventMan->hideMouse();
}
Expand Down Expand Up @@ -496,7 +496,7 @@ void ChampionMan::drawChangedObjectIcons() {
uint16 drawViewport = 0;

for (uint16 slotIndex = kDMSlotReadyHand; slotIndex < kDMSlotChest1; slotIndex++, thing++) {
uint16 objIconChanged = hasObjectIconInSlotBoxChanged(slotIndex + k8_SlotBoxInventoryFirstSlot, *thing) ? 1 : 0;
uint16 objIconChanged = hasObjectIconInSlotBoxChanged(slotIndex + kDMSlotBoxInventoryFirstSlot, *thing) ? 1 : 0;
drawViewport |= objIconChanged;
if (objIconChanged && (slotIndex == kDMSlotActionHand)) {
menuMan.drawActionIcon((ChampionIndex)_vm->ordinalToIndex(invChampOrdinal));
Expand Down Expand Up @@ -1294,7 +1294,7 @@ void ChampionMan::clickOnSlotBox(uint16 slotBoxIndex) {
uint16 champIndex;
uint16 slotIndex;

if (slotBoxIndex < k8_SlotBoxInventoryFirstSlot) {
if (slotBoxIndex < kDMSlotBoxInventoryFirstSlot) {
if (_candidateChampionOrdinal)
return;

Expand All @@ -1305,7 +1305,7 @@ void ChampionMan::clickOnSlotBox(uint16 slotBoxIndex) {
slotIndex = getHandSlotIndex(slotBoxIndex);
} else {
champIndex = _vm->ordinalToIndex(_vm->_inventoryMan->_inventoryChampionOrdinal);
slotIndex = slotBoxIndex - k8_SlotBoxInventoryFirstSlot;
slotIndex = slotBoxIndex - kDMSlotBoxInventoryFirstSlot;
}

Thing leaderHandObject = _leaderHandObject;
Expand Down Expand Up @@ -2309,7 +2309,7 @@ void ChampionMan::drawSlot(uint16 champIndex, int16 slotIndex) {
return;
slotBoxIndex = (champIndex << 1) + slotIndex;
} else
slotBoxIndex = k8_SlotBoxInventoryFirstSlot + slotIndex;
slotBoxIndex = kDMSlotBoxInventoryFirstSlot + slotIndex;

Thing thing;
if (slotIndex >= kDMSlotChest1)
Expand Down
2 changes: 1 addition & 1 deletion engines/dm/console.cpp
Expand Up @@ -218,7 +218,7 @@ bool Console::Cmd_listItems(int argc, const char** argv) {
if(strstr(_vm->_objectMan->_objectNames[0], searchedString.c_str()) != nullptr)
debugPrintf("| %s", _vm->_objectMan->_objectNames[0]);

for (uint16 i = 1; i < k199_ObjectNameCount; ++i) {
for (uint16 i = 1; i < kDMObjectNameCount; ++i) {
const char *name = _vm->_objectMan->_objectNames[i - 1];
const char *prevName = _vm->_objectMan->_objectNames[i];

Expand Down
4 changes: 3 additions & 1 deletion engines/dm/dm.h
Expand Up @@ -148,7 +148,9 @@ enum MapIndice {
#define kDMMaskDecodeEvenIfInvisible 0x8000 // @ MASK0x8000_DECODE_EVEN_IF_INVISIBLE
#define kDMMaskMergeCycles 0x8000 // @ MASK0x8000_MERGE_CYCLES

#define kDMSlotBoxChestFirstSlot 38 // @ C38_SLOT_BOX_CHEST_FIRST_SLOT
#define kDMSlotBoxInventoryFirstSlot 8 // @ C08_SLOT_BOX_INVENTORY_FIRST_SLOT
#define kDMSlotBoxInventoryActionHand 9 // @ C09_SLOT_BOX_INVENTORY_ACTION_HAND
#define kDMSlotBoxChestFirstSlot 38 // @ C38_SLOT_BOX_CHEST_FIRST_SLOT

struct DMADGameDescription {
ADGameDescription _desc;
Expand Down
28 changes: 14 additions & 14 deletions engines/dm/group.cpp
Expand Up @@ -390,7 +390,7 @@ int16 GroupMan::groupGetDamageCreatureOutcome(Group *group, uint16 creatureIndex
CreatureType creatureType = group->_type;
CreatureInfo *creatureInfo = &_vm->_dungeonMan->_creatureInfos[creatureType];
if (getFlag(creatureInfo->_attributes, kDMCreatureMaskArchenemy)) /* Lord Chaos cannot be damaged */
return k0_outcomeKilledNoCreaturesInGroup;
return kDMKillOutcomeNoCreaturesInGroup;

if (group->_health[creatureIndex] <= damage) {
uint16 groupCells = getGroupCells(group, _vm->_dungeonMan->_currMapIndex);
Expand All @@ -403,7 +403,7 @@ int16 GroupMan::groupGetDamageCreatureOutcome(Group *group, uint16 creatureIndex
dropGroupPossessions(mapX, mapY, groupGetThing(mapX, mapY), kDMSoundModePlayOneTickLater);
groupDelete(mapX, mapY);
}
retVal = k2_outcomeKilledAllCreaturesInGroup;
retVal = kDMKillOutcomeAllCreaturesInGroup;
} else { /* If there are several creatures in the group */
uint16 groupDirections = getGroupDirections(group, _vm->_dungeonMan->_currMapIndex);
if (getFlag(creatureInfo->_attributes, kDMCreatureMaskDropFixedPoss)) {
Expand Down Expand Up @@ -464,7 +464,7 @@ int16 GroupMan::groupGetDamageCreatureOutcome(Group *group, uint16 creatureIndex
_vm->_dungeonMan->setGroupCells(group, groupCells, _vm->_dungeonMan->_currMapIndex);
_vm->_dungeonMan->setGroupDirections(group, groupDirections, _vm->_dungeonMan->_currMapIndex);
group->setCount(group->getCount() - 1);
retVal = k1_outcomeKilledSomeCreaturesInGroup;
retVal = kDMKillOutcomeSomeCreaturesInGroup;
}

CreatureSize creatureSize = (CreatureSize)getFlag(creatureInfo->_attributes, kDMCreatureMaskSize);
Expand All @@ -483,7 +483,7 @@ int16 GroupMan::groupGetDamageCreatureOutcome(Group *group, uint16 creatureIndex
if (damage > 0)
group->_health[creatureIndex] -= damage;

return k0_outcomeKilledNoCreaturesInGroup;
return kDMKillOutcomeNoCreaturesInGroup;
}

void GroupMan::groupDelete(int16 mapX, int16 mapY) {
Expand Down Expand Up @@ -538,13 +538,13 @@ int16 GroupMan::getDamageAllCreaturesOutcome(Group *group, int16 mapX, int16 map
killedSomeCreatures = killedSomeCreatures || outcomeVal;
} while (creatureIndex--);
if (killedAllCreatures)
return k2_outcomeKilledAllCreaturesInGroup;
return kDMKillOutcomeAllCreaturesInGroup;

if (killedSomeCreatures)
return k1_outcomeKilledSomeCreaturesInGroup;
return kDMKillOutcomeSomeCreaturesInGroup;
}

return k0_outcomeKilledNoCreaturesInGroup;
return kDMKillOutcomeNoCreaturesInGroup;
}

int16 GroupMan::groupGetResistanceAdjustedPoisonAttack(CreatureType creatureType, int16 poisonAttack) {
Expand Down Expand Up @@ -971,7 +971,7 @@ void GroupMan::processEvents29to41(int16 eventMapX, int16 eventMapY, int16 event
}
/* If 1/8 chance and the creature is not adjacent to the party and is a quarter square sized creature then process projectile impacts and update the creature cell if still alive. When the creature is not in front of the party, it has 7/8 chances of dodging a projectile by moving to another cell or staying in the center of the square */
if (!(AL0446_i_GroupCellsCriteria & 0x0038) && (distanceToVisibleParty != 1) && (creatureSize == kDMCreatureSizeQuarter)) {
if (_vm->_projexpl->projectileGetImpactCount(kDMElementTypeCreature, eventMapX, eventMapY, activeGroup->_cells) && (_vm->_projexpl->_creatureDamageOutcome == k2_outcomeKilledAllCreaturesInGroup)) /* This call to F0218_PROJECTILE_GetImpactCount works fine because there is a single creature in the group so L0445_ps_ActiveGroup->Cells contains only one cell index */
if (_vm->_projexpl->projectileGetImpactCount(kDMElementTypeCreature, eventMapX, eventMapY, activeGroup->_cells) && (_vm->_projexpl->_creatureDamageOutcome == kDMKillOutcomeAllCreaturesInGroup)) /* This call to F0218_PROJECTILE_GetImpactCount works fine because there is a single creature in the group so L0445_ps_ActiveGroup->Cells contains only one cell index */
return;
activeGroup->_cells = _vm->normalizeModulo4(AL0446_i_GroupCellsCriteria);
}
Expand Down Expand Up @@ -1001,9 +1001,9 @@ void GroupMan::processEvents29to41(int16 eventMapX, int16 eventMapY, int16 event
AL0446_i_Cell = _vm->normalizeModulo4(AL0446_i_Cell);
if (!getCreatureOrdinalInCell(curGroup, AL0446_i_Cell) ||
(_vm->getRandomNumber(2) && !getCreatureOrdinalInCell(curGroup, AL0446_i_Cell = _vm->returnOppositeDir((Direction)AL0446_i_Cell)))) { /* If the selected cell (or the opposite cell) is not already occupied by a creature */
if (_vm->_projexpl->projectileGetImpactCount(kDMElementTypeCreature, eventMapX, eventMapY, activeGroup->_cells) && (_vm->_projexpl->_creatureDamageOutcome == k2_outcomeKilledAllCreaturesInGroup)) /* BUG0_70 A projectile impact on a creature may be ignored. The function F0218_PROJECTILE_GetImpactCount to detect projectile impacts when a quarter square sized creature moves inside a group (to another cell on the same square) may fail if there are several creatures in the group because the function expects a single cell index for its last parameter. The function should be called once for each cell where there is a creature */
if (_vm->_projexpl->projectileGetImpactCount(kDMElementTypeCreature, eventMapX, eventMapY, activeGroup->_cells) && (_vm->_projexpl->_creatureDamageOutcome == kDMKillOutcomeAllCreaturesInGroup)) /* BUG0_70 A projectile impact on a creature may be ignored. The function F0218_PROJECTILE_GetImpactCount to detect projectile impacts when a quarter square sized creature moves inside a group (to another cell on the same square) may fail if there are several creatures in the group because the function expects a single cell index for its last parameter. The function should be called once for each cell where there is a creature */
return;
if (_vm->_projexpl->_creatureDamageOutcome != k1_outcomeKilledSomeCreaturesInGroup) {
if (_vm->_projexpl->_creatureDamageOutcome != kDMKillOutcomeSomeCreaturesInGroup) {
activeGroup->_cells = getGroupValueUpdatedWithCreatureValue(activeGroup->_cells, AL0447_i_CreatureIndex, AL0446_i_Cell);
}
}
Expand Down Expand Up @@ -1811,9 +1811,9 @@ int16 GroupMan::getMeleeActionDamage(Champion *champ, int16 champIndex, Group *g
int16 doubledMapDifficulty = _vm->_dungeonMan->_currMap->_difficulty << 1;
CreatureInfo *creatureInfo = &_vm->_dungeonMan->_creatureInfos[group->_type];
int16 actionHandObjectIconIndex = _vm->_objectMan->getIconIndex(champ->_slots[kDMSlotActionHand]);
bool actionHitsNonMaterialCreatures = getFlag(actionHitProbability, k0x8000_hitNonMaterialCreatures);
bool actionHitsNonMaterialCreatures = getFlag(actionHitProbability, kDMActionMaskHitNonMaterialCreatures);
if (actionHitsNonMaterialCreatures)
clearFlag(actionHitProbability, k0x8000_hitNonMaterialCreatures);
clearFlag(actionHitProbability, kDMActionMaskHitNonMaterialCreatures);

if ((!getFlag(creatureInfo->_attributes, kDMCreatureMaskNonMaterial) || actionHitsNonMaterialCreatures) &&
((_vm->_championMan->getDexterity(champ) > (_vm->getRandomNumber(32) + creatureInfo->_dexterity + doubledMapDifficulty - 16)) ||
Expand Down Expand Up @@ -1869,11 +1869,11 @@ int16 GroupMan::getMeleeActionDamage(Champion *champ, int16 champIndex, Group *g
}
T0231015:
L0565_i_Damage = 0;
L0569_i_Outcome = k0_outcomeKilledNoCreaturesInGroup;
L0569_i_Outcome = kDMKillOutcomeNoCreaturesInGroup;
_vm->_championMan->decrementStamina(champIndex, _vm->getRandomNumber(2) + 2);
T0231016:
_vm->_championMan->drawChampionState((ChampionIndex)champIndex);
if (L0569_i_Outcome != k2_outcomeKilledAllCreaturesInGroup) {
if (L0569_i_Outcome != kDMKillOutcomeAllCreaturesInGroup) {
processEvents29to41(mapX, mapY, kM1_TMEventTypeCreateReactionEvent31ParyIsAdjacent, 0);
}
return L0565_i_Damage;
Expand Down
2 changes: 1 addition & 1 deletion engines/dm/inventory.cpp
Expand Up @@ -365,7 +365,7 @@ void InventoryMan::openAndDrawChest(Thing thingToOpen, Container *chest, bool is

_openChest = thingToOpen;
if (!isPressingEye) {
objMan.drawIconInSlotBox(k9_SlotBoxInventoryActionHand, kDMIconIndiceContainerChestOpen);
objMan.drawIconInSlotBox(kDMSlotBoxInventoryActionHand, kDMIconIndiceContainerChestOpen);
}
dispMan.blitToViewport(_vm->_displayMan->getNativeBitmapOrGraphic(k25_PanelOpenChestIndice),
_boxPanel, k72_byteWidth, kDMColorRed, 73);
Expand Down
2 changes: 0 additions & 2 deletions engines/dm/loadsave.h
Expand Up @@ -36,9 +36,7 @@ class LoadsaveMan {
DMEngine *_vm;
public:
explicit LoadsaveMan(DMEngine *vm);

};

}

#endif
24 changes: 12 additions & 12 deletions engines/dm/menus.cpp
Expand Up @@ -425,7 +425,7 @@ void MenuMan::buildSpellAreaLine(int16 spellAreaBitmapLine) {

char spellSymbolString[2] = {'\0', '\0'};
Champion *magicChampion = &_vm->_championMan->_champions[_vm->_championMan->_magicCasterChampionIndex];
if (spellAreaBitmapLine == k2_SpellAreaAvailableSymbols) {
if (spellAreaBitmapLine == kDMSpellAreaAvailableSymbols) {
_vm->_displayMan->_useByteBoxCoordinates = false;
_vm->_displayMan->blitToBitmap(_bitmapSpellAreaLines, _bitmapSpellAreaLine, boxSpellAreaLine, 0, 12, k48_byteWidth, k48_byteWidth, kDMColorNoTransparency, 36, 12);
int16 x = 1;
Expand All @@ -435,7 +435,7 @@ void MenuMan::buildSpellAreaLine(int16 spellAreaBitmapLine) {
x += 14;
_vm->_textMan->printTextToBitmap(_bitmapSpellAreaLine, 48, x, 8, kDMColorCyan, kDMColorBlack, spellSymbolString, 12);
}
} else if (spellAreaBitmapLine == k3_SpellAreaChampionSymbols) {
} else if (spellAreaBitmapLine == kDMSpellAreaChampionSymbols) {
_vm->_displayMan->_useByteBoxCoordinates = false;
_vm->_displayMan->blitToBitmap(_bitmapSpellAreaLines, _bitmapSpellAreaLine, boxSpellAreaLine, 0, 24, k48_byteWidth, k48_byteWidth, kDMColorNoTransparency, 36, 12);
int16 x = 8;
Expand Down Expand Up @@ -470,11 +470,11 @@ void MenuMan::setMagicCasterAndDrawSpellArea(ChampionIndex champIndex) {
return;
}
_vm->_championMan->_magicCasterChampionIndex = champIndex;
buildSpellAreaLine(k2_SpellAreaAvailableSymbols);
buildSpellAreaLine(kDMSpellAreaAvailableSymbols);
_vm->_eventMan->showMouse();
drawSpellAreaControls(champIndex);
_vm->_displayMan->blitToScreen(_bitmapSpellAreaLine, &boxSpellAreaLine2, k48_byteWidth, kDMColorNoTransparency, 12);
buildSpellAreaLine(k3_SpellAreaChampionSymbols);
buildSpellAreaLine(kDMSpellAreaChampionSymbols);
_vm->_displayMan->blitToScreen(_bitmapSpellAreaLine, &boxSpellAreaLine3, k48_byteWidth, kDMColorNoTransparency, 12);
_vm->_eventMan->hideMouse();
}
Expand Down Expand Up @@ -1144,7 +1144,7 @@ bool MenuMan::isActionPerformed(uint16 champIndex, int16 actionIndex) {
break;
case kDMActionShoot: {
if (Thing(curChampion->_slots[kDMSlotReadyHand]).getType() != kDMThingTypeWeapon) {
_actionDamage = kM2_damageNoAmmunition;
_actionDamage = kDMDamageNoAmmunition;
actionExperienceGain = 0;
actionPerformed = false;
break;
Expand All @@ -1157,15 +1157,15 @@ bool MenuMan::isActionPerformed(uint16 champIndex, int16 actionIndex) {
int16 stepEnergy = actionHandWeaponClass;
if ((actionHandWeaponClass >= kDMWeaponClassFirstBow) && (actionHandWeaponClass <= kDMWeaponClassLastBow)) {
if (readyHandWeaponClass != kDMWeaponClassBowAmmunition) {
_actionDamage = kM2_damageNoAmmunition;
_actionDamage = kDMDamageNoAmmunition;
actionExperienceGain = 0;
actionPerformed = false;
break;
}
stepEnergy -= kDMWeaponClassFirstBow;
} else if ((actionHandWeaponClass >= kDMWeaponClassFirstSling) && (actionHandWeaponClass <= kDMWeaponClassLastSling)) {
if (readyHandWeaponClass != kDMWeaponClassSlingAmmunition) {
_actionDamage = kM2_damageNoAmmunition;
_actionDamage = kDMDamageNoAmmunition;
actionExperienceGain = 0;
actionPerformed = false;
break;
Expand Down Expand Up @@ -1496,7 +1496,7 @@ bool MenuMan::isMeleeActionPerformed(int16 champIndex, Champion *champ, int16 ac
uint16 cellDelta = (viewCell == kDMViewCellBackRight) ? 3 : 1;
/* Check if there is another champion in front */
if (_vm->_championMan->getIndexInCell(_vm->normalizeModulo4(championCell + cellDelta)) != kDMChampionNone) {
_actionDamage = kM1_damageCantReach;
_actionDamage = kDMDamageCantReach;
return false;
}
break;
Expand All @@ -1508,7 +1508,7 @@ bool MenuMan::isMeleeActionPerformed(int16 champIndex, Champion *champ, int16 ac
uint16 actionHitProbability = actionHitProbabilityArray[actionIndex];
uint16 actionDamageFactor = actionDamageFactorArray[actionIndex];
if ((_vm->_objectMan->getIconIndex(champ->_slots[kDMSlotActionHand]) == kDMIconIndiceWeaponVorpalBlade) || (actionIndex == kDMActionDisrupt)) {
setFlag(actionHitProbability, k0x8000_hitNonMaterialCreatures);
setFlag(actionHitProbability, kDMActionMaskHitNonMaterialCreatures);
}
_actionDamage = _vm->_groupMan->getMeleeActionDamage(champ, champIndex, (Group *)_vm->_dungeonMan->getThingData(_actionTargetGroupThing), _vm->ordinalToIndex(targetCreatureOrdinal), targetMapX, targetMapY, actionHitProbability, actionDamageFactor, skillIndex);
return true;
Expand Down Expand Up @@ -1681,10 +1681,10 @@ void MenuMan::setActionList(ActionSet *actionSet) {
continue;

uint16 minimumSkillLevel = actionSet->_actionProperties[idx - 1];
if (getFlag(minimumSkillLevel, k0x0080_actionRequiresCharge) && !getActionObjectChargeCount())
if (getFlag(minimumSkillLevel, kDMActionMaskRequiresCharge) && !getActionObjectChargeCount())
continue;

clearFlag(minimumSkillLevel, k0x0080_actionRequiresCharge);
clearFlag(minimumSkillLevel, kDMActionMaskRequiresCharge);
if (_vm->_championMan->getSkillLevel(_vm->ordinalToIndex(_vm->_championMan->_actingChampionOrdinal), _actionSkillIndex[actionIndex]) >= minimumSkillLevel) {
_actionList._actionIndices[nextAvailableActionListIndex] = (ChampionAction)actionIndex;
_actionList._minimumSkillLevel[nextAvailableActionListIndex] = minimumSkillLevel;
Expand Down Expand Up @@ -1745,7 +1745,7 @@ void MenuMan::drawActionDamage(int16 damage) {

const char *displayString;
int16 textPosX;
if (damage == kM1_damageCantReach) {
if (damage == kDMDamageCantReach) {
textPosX = pos[0];
displayString = message[0];
} else {
Expand Down
20 changes: 13 additions & 7 deletions engines/dm/menus.h
Expand Up @@ -34,13 +34,20 @@

namespace DM {

#define kM1_damageCantReach -1 // @ CM1_DAMAGE_CANT_REACH
#define kM2_damageNoAmmunition -2 // @ CM2_DAMAGE_NO_AMMUNITION
#define k2_SpellAreaAvailableSymbols 2 // @ C2_SPELL_AREA_AVAILABLE_SYMBOLS
#define k3_SpellAreaChampionSymbols 3 // @ C3_SPELL_AREA_CHAMPION_SYMBOLS
enum Damage {
kDMDamageCantReach = -1, // @ CM1_DAMAGE_CANT_REACH
kDMDamageNoAmmunition = -2 // @ CM2_DAMAGE_NO_AMMUNITION
};

#define k0x0080_actionRequiresCharge 0x0080 // @ MASK0x0080_ACTION_REQUIRES_CHARGE
#define k0x8000_hitNonMaterialCreatures 0x8000 // @ MASK0x8000_HIT_NON_MATERIAL_CREATURES
enum SpellArea {
kDMSpellAreaAvailableSymbols = 2, // @ C2_SPELL_AREA_AVAILABLE_SYMBOLS
kDMSpellAreaChampionSymbols = 3 // @ C3_SPELL_AREA_CHAMPION_SYMBOLS
};

enum ActionMask {
kDMActionMaskRequiresCharge = 0x0080, // @ MASK0x0080_ACTION_REQUIRES_CHARGE
kDMActionMaskHitNonMaterialCreatures = 0x8000 // @ MASK0x8000_HIT_NON_MATERIAL_CREATURES
};

class ActionList {
public:
Expand Down Expand Up @@ -129,7 +136,6 @@ class MenuMan {

void initConstants();
};

}

#endif // DM_MENUS_H
6 changes: 3 additions & 3 deletions engines/dm/movesens.cpp
Expand Up @@ -334,11 +334,11 @@ bool MovesensMan::getMoveResult(Thing thing, int16 mapX, int16 mapY, int16 destM
_vm->_dungeonMan->setCurrentMap(mapIndexSource);
uint16 outcome = _vm->_groupMan->getDamageAllCreaturesOutcome((Group *)_vm->_dungeonMan->getThingData(thing), mapX, mapY, 20, false);
_vm->_dungeonMan->setCurrentMap(mapIndexDestination);
fallKilledGroup = (outcome == k2_outcomeKilledAllCreaturesInGroup);
fallKilledGroup = (outcome == kDMKillOutcomeAllCreaturesInGroup);
if (fallKilledGroup)
break;

if (outcome == k1_outcomeKilledSomeCreaturesInGroup)
if (outcome == kDMKillOutcomeSomeCreaturesInGroup)
_vm->_groupMan->dropMovingCreatureFixedPossession(thing, destMapX, destMapY);
}
} else if ((destinationSquareType == (int)kDMElementTypeStairs) && (thing != Thing::_party) && (thingType != kDMThingTypeProjectile)) {
Expand Down Expand Up @@ -564,7 +564,7 @@ bool MovesensMan::moveIsKilledByProjectileImpact(int16 srcMapX, int16 srcMapY, i
int16 championOrCreatureOrdinal = championOrCreatureOrdinalInCell[curThing.getCell()];
if (championOrCreatureOrdinal && _vm->_projexpl->hasProjectileImpactOccurred(impactType, srcMapX, srcMapY, _vm->ordinalToIndex(championOrCreatureOrdinal), curThing)) {
_vm->_projexpl->projectileDeleteEvent(curThing);
if (_vm->_projexpl->_creatureDamageOutcome == k2_outcomeKilledAllCreaturesInGroup)
if (_vm->_projexpl->_creatureDamageOutcome == kDMKillOutcomeAllCreaturesInGroup)
return true;

goto T0266017_CheckProjectileImpacts;
Expand Down
1 change: 0 additions & 1 deletion engines/dm/movesens.h
Expand Up @@ -77,7 +77,6 @@ namespace DM {
void createEventMoveGroup(Thing groupThing, int16 mapX, int16 mapY, int16 mapIndex, bool audible); // @ F0265_MOVE_CreateEvent60To61_MoveGroup
Thing getObjectOfTypeInCell(int16 mapX, int16 mapY, int16 cell, int16 objectType); // @ F0273_SENSOR_GetObjectOfTypeInCell
};

}

#endif

0 comments on commit 8bdabc1

Please sign in to comment.