diff options
author | Bendegúz Nagy | 2016-07-02 01:55:48 +0200 |
---|---|---|
committer | Bendegúz Nagy | 2016-08-26 23:02:22 +0200 |
commit | 71e4b5b2bca49f0de8b07f4f85de9167dd9b5f99 (patch) | |
tree | 9e656c1c3af8a90ab7e631528bfa2669c13862a8 | |
parent | da317f14be4d2b6f1031d84b5fc7ee743998cf4c (diff) | |
download | scummvm-rg350-71e4b5b2bca49f0de8b07f4f85de9167dd9b5f99.tar.gz scummvm-rg350-71e4b5b2bca49f0de8b07f4f85de9167dd9b5f99.tar.bz2 scummvm-rg350-71e4b5b2bca49f0de8b07f4f85de9167dd9b5f99.zip |
DM: Renaming in champion.c/h
-rw-r--r-- | engines/dm/champion.cpp | 392 | ||||
-rw-r--r-- | engines/dm/champion.h | 468 | ||||
-rw-r--r-- | engines/dm/dm.cpp | 8 | ||||
-rw-r--r-- | engines/dm/eventman.cpp | 82 | ||||
-rw-r--r-- | engines/dm/inventory.cpp | 52 | ||||
-rw-r--r-- | engines/dm/loadsave.cpp | 6 | ||||
-rw-r--r-- | engines/dm/menus.cpp | 78 | ||||
-rw-r--r-- | engines/dm/menus.h | 2 | ||||
-rw-r--r-- | engines/dm/movesens.cpp | 16 | ||||
-rw-r--r-- | engines/dm/objectman.cpp | 38 |
10 files changed, 571 insertions, 571 deletions
diff --git a/engines/dm/champion.cpp b/engines/dm/champion.cpp index 5f1b68c15b..9302216766 100644 --- a/engines/dm/champion.cpp +++ b/engines/dm/champion.cpp @@ -38,14 +38,14 @@ namespace DM { Box gBoxMouth = Box(55, 72, 12, 29); // @ G0048_s_Graphic562_Box_Mouth
Box gBoxEye = Box(11, 28, 12, 29); // @ G0049_s_Graphic562_Box_Eye
-Box gBoxChampionIcons[4] = {
+Box g54_BoxChampionIcons[4] = {
Box(281, 299, 0, 13),
Box(301, 319, 0, 13),
Box(301, 319, 15, 28),
Box(281, 299, 15, 28)};
-Color gChampionColor[4] = {(Color)7, (Color)11, (Color)8, (Color)14};
+Color g46_ChampionColor[4] = {(Color)7, (Color)11, (Color)8, (Color)14};
-int16 gLightPowerToLightAmount[16] = {0, 5, 12, 24, 33, 40, 46, 51, 59, 68, 76, 82, 89, 94, 97, 100};
+int16 g39_LightPowerToLightAmount[16] = {0, 5, 12, 24, 33, 40, 46, 51, 59, 68, 76, 82, 89, 94, 97, 100};
uint16 gSlotMasks[38] = { // @ G0038_ai_Graphic562_SlotMasks
/* 30 for champion inventory, 8 for chest */
@@ -91,13 +91,13 @@ uint16 gSlotMasks[38] = { // @ G0038_ai_Graphic562_SlotMasks Box gBoxChampionPortrait = Box(0, 31, 0, 28); // @ G0047_s_Graphic562_Box_ChampionPortrait
ChampionMan::ChampionMan(DMEngine *vm) : _vm(vm) {
- _leaderIndex = kChampionNone;
+ _g411_leaderIndex = kM1_ChampionNone;
- _partyDead = false;
- _partyIsSleeping = false;
- _leaderHandObjectIconIndex = kIconIndiceNone;
- _leaderEmptyHanded = true;
- _magicCasterChampionIndex = kChampionNone;
+ _303_partyDead = false;
+ _g300_partyIsSleeping = false;
+ _g413_leaderHandObjectIconIndex = kM1_IconIndiceNone;
+ _g415_leaderEmptyHanded = true;
+ _g514_magicCasterChampionIndex = kM1_ChampionNone;
}
uint16 ChampionMan::getChampionPortraitX(uint16 index) {
@@ -143,13 +143,13 @@ void ChampionMan::applyModifiersToStatistics(Champion* champ, ChampionSlot slotI int16 modifier = 0;
ThingType thingType = thing.getType();
if (((thingType == kWeaponThingType) || (thingType == kArmourThingType))
- && (slotIndex >= kChampionSlotReadyHand)
- && (slotIndex <= kChampionSlotQuiverLine_1_1)) {
+ && (slotIndex >= k0_ChampionSlotReadyHand)
+ && (slotIndex <= k12_ChampionSlotQuiverLine_1_1)) {
Weapon *weapon = (Weapon*)_vm->_dungeonMan->getThingData(thing);
Armour *armour = (Armour*)_vm->_dungeonMan->getThingData(thing);
if (((thingType == kWeaponThingType) && weapon->getCursed())
|| ((thingType == kArmourThingType) && armour->getCursed())) {
- statIndex = kChampionStatLuck;
+ statIndex = k0_ChampionStatLuck;
modifier = -3;
goto T0299044_ApplyModifier;
}
@@ -157,58 +157,58 @@ void ChampionMan::applyModifiersToStatistics(Champion* champ, ChampionSlot slotI statIndex = (ChampionStatisticType)thingType; // variable sharing
- if ((iconIndex == kIconIndiceJunkRabbitsFoot) && (slotIndex < kChampionSlotChest_1)) {
- statIndex = kChampionStatLuck;
+ if ((iconIndex == k137_IconIndiceJunkRabbitsFoot) && (slotIndex < k30_ChampionSlotChest_1)) {
+ statIndex = k0_ChampionStatLuck;
modifier = 10;
- } else if (slotIndex == kChampionSlotActionHand) {
+ } else if (slotIndex == k1_ChampionSlotActionHand) {
- if (iconIndex == kIconIndiceWeaponMaceOfOrder) {
- statIndex = kChampionStatStrength;
+ if (iconIndex == k45_IconIndiceWeaponMaceOfOrder) {
+ statIndex = k1_ChampionStatStrength;
modifier = 5;
} else {
- statIndex = kChampionStatMana;
- if ((iconIndex >= kIconIndiceWeaponStaffOfClawsEmpty) && (iconIndex <= kIconIndiceWeaponStaffOfClawsFull)) {
+ statIndex = k8_ChampionStatMana;
+ if ((iconIndex >= k20_IconIndiceWeaponStaffOfClawsEmpty) && (iconIndex <= k22_IconIndiceWeaponStaffOfClawsFull)) {
modifier = 4;
- } else if ((iconIndex >= kIconIndiceWeaponStaff) && (iconIndex <= kIconIndiceWeaponSceptreOfLyf)) {
+ } else if ((iconIndex >= k58_IconIndiceWeaponStaff) && (iconIndex <= k66_IconIndiceWeaponSceptreOfLyf)) {
switch (iconIndex) {
- case kIconIndiceWeaponStaff:
+ case k58_IconIndiceWeaponStaff:
modifier = 2;
break;
- case kIconIndiceWeaponWand:
+ case k59_IconIndiceWeaponWand:
modifier = 1;
break;
- case kIconIndiceWeaponTeowand:
+ case k60_IconIndiceWeaponTeowand:
modifier = 6;
break;
- case kIconIndiceWeaponYewStaff:
+ case k61_IconIndiceWeaponYewStaff:
modifier = 4;
break;
- case kIconIndiceWeaponStaffOfManarStaffOfIrra:
+ case k62_IconIndiceWeaponStaffOfManarStaffOfIrra:
modifier = 10;
break;
- case kIconIndiceWeaponSnakeStaffCrossOfNeta:
+ case k63_IconIndiceWeaponSnakeStaffCrossOfNeta:
modifier = 8;
break;
- case kIconIndiceWeaponTheConduitSerpentStaff:
+ case k64_IconIndiceWeaponTheConduitSerpentStaff:
modifier = 16;
break;
- case kIconIndiceWeaponDragonSpit:
+ case k65_IconIndiceWeaponDragonSpit:
modifier = 7;
break;
- case kIconIndiceWeaponSceptreOfLyf:
+ case k66_IconIndiceWeaponSceptreOfLyf:
modifier = 5;
break;
}
} else {
switch (iconIndex) {
- case kIconIndiceWeaponDeltaSideSplitter:
+ case k38_IconIndiceWeaponDeltaSideSplitter:
modifier = 1;
break;
- case kIconIndiceWeaponTheInquisitorDragonFang:
+ case k41_IconIndiceWeaponTheInquisitorDragonFang:
modifier = 2;
break;
- case kIconIndiceWeaponVorpalBlade:
+ case k40_IconIndiceWeaponVorpalBlade:
modifier = 4;
break;
}
@@ -216,43 +216,43 @@ void ChampionMan::applyModifiersToStatistics(Champion* champ, ChampionSlot slotI }
- } else if (slotIndex == kChampionSlotLegs) {
+ } else if (slotIndex == k4_ChampionSlotLegs) {
- if (iconIndex == kIconIndiceArmourPowertowers) {
- statIndex = kChampionStatStrength;
+ if (iconIndex == k142_IconIndiceArmourPowertowers) {
+ statIndex = k1_ChampionStatStrength;
modifier = 10;
}
- } else if (slotIndex == kChampionSlotHead) {
+ } else if (slotIndex == k2_ChampionSlotHead) {
- if (iconIndex == kIconIndiceArmourCrownOfNerra) {
- statIndex = kChampionStatWisdom;
+ if (iconIndex == k104_IconIndiceArmourCrownOfNerra) {
+ statIndex = k3_ChampionStatWisdom;
modifier = 10;
- } else if (iconIndex == kIconIndiceArmourDexhelm) {
- statIndex = kChampionStatDexterity;
+ } else if (iconIndex == k140_IconIndiceArmourDexhelm) {
+ statIndex = k2_ChampionStatDexterity;
modifier = 10;
}
- } else if (slotIndex == kChampionSlotTorso) {
+ } else if (slotIndex == k3_ChampionSlotTorso) {
- if (iconIndex == kIconIndiceArmourFlamebain) {
- statIndex = kChampionStatAntifire;
+ if (iconIndex == k141_IconIndiceArmourFlamebain) {
+ statIndex = k6_ChampionStatAntifire;
modifier = 12;
- } else if (iconIndex == kIconIndiceArmourCloakOfNight) {
- statIndex = kChampionStatDexterity;
+ } else if (iconIndex == k81_IconIndiceArmourCloakOfNight) {
+ statIndex = k2_ChampionStatDexterity;
modifier = 8;
}
- } else if (slotIndex == kChampionSlotNeck) {
+ } else if (slotIndex == k10_ChampionSlotNeck) {
- if ((iconIndex >= kIconIndiceJunkJewelSymalUnequipped) && (iconIndex <= kIconIndiceJunkJewelSymalEquipped)) {
- statIndex = kChampionStatAntimagic;
+ if ((iconIndex >= k10_IconIndiceJunkJewelSymalUnequipped) && (iconIndex <= k11_IconIndiceJunkJewelSymalEquipped)) {
+ statIndex = k5_ChampionStatAntimagic;
modifier = 15;
- } else if (iconIndex == kIconIndiceArmourCloakOfNight) {
- statIndex = kChampionStatDexterity;
+ } else if (iconIndex == k81_IconIndiceArmourCloakOfNight) {
+ statIndex = k2_ChampionStatDexterity;
modifier = 8;
- } else if (iconIndex == kIconIndiceJunkMoonstone) {
- statIndex = kChampionStatMana;
+ } else if (iconIndex == k122_IconIndiceJunkMoonstone) {
+ statIndex = k8_ChampionStatMana;
modifier = 3;
}
@@ -261,10 +261,10 @@ void ChampionMan::applyModifiersToStatistics(Champion* champ, ChampionSlot slotI T0299044_ApplyModifier:
if (modifier) {
modifier *= modifierFactor;
- if (statIndex == kChampionStatMana) {
+ if (statIndex == k8_ChampionStatMana) {
champ->_maxMana += modifier;
- } else if (statIndex < kChampionStatAntifire + 1) {
- for (uint16 statValIndex = kChampionStatMaximum; statValIndex <= kChampionStatMinimum; ++statValIndex) {
+ } else if (statIndex < k6_ChampionStatAntifire + 1) {
+ for (uint16 statValIndex = k0_ChampionStatMaximum; statValIndex <= k2_ChampionStatMinimum; ++statValIndex) {
champ->getStatistic((ChampionStatisticType)statIndex, (ChampionStatisticValue)statValIndex) += modifier;
warning("BUG0_38");
}
@@ -277,13 +277,13 @@ bool ChampionMan::hasObjectIconInSlotBoxChanged(int16 slotBoxIndex, Thing thing) ObjectMan &objMan = *_vm->_objectMan;
IconIndice currIconIndex = objMan.getIconIndexInSlotBox(slotBoxIndex);
- if (((currIconIndex < kIconIndiceWeaponDagger) && (currIconIndex >= kIconIndiceJunkCompassNorth))
- || ((currIconIndex >= kIconIndicePotionMaPotionMonPotion) && (currIconIndex <= kIconIndicePotionWaterFlask))
- || (currIconIndex == kIconIndicePotionEmptyFlask)) {
+ if (((currIconIndex < k32_IconIndiceWeaponDagger) && (currIconIndex >= k0_IconIndiceJunkCompassNorth))
+ || ((currIconIndex >= k148_IconIndicePotionMaPotionMonPotion) && (currIconIndex <= k163_IconIndicePotionWaterFlask))
+ || (currIconIndex == k195_IconIndicePotionEmptyFlask)) {
IconIndice newIconIndex = objMan.getIconIndex(thing);
if (newIconIndex != currIconIndex) {
- if ((slotBoxIndex < kSlotBoxInventoryFirstSlot) && !_mousePointerHiddenToDrawChangedObjIconOnScreen) {
- _mousePointerHiddenToDrawChangedObjIconOnScreen = true;
+ if ((slotBoxIndex < kSlotBoxInventoryFirstSlot) && !_g420_mousePointerHiddenToDrawChangedObjIconOnScreen) {
+ _g420_mousePointerHiddenToDrawChangedObjIconOnScreen = true;
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
}
objMan.drawIconInSlotBox(slotBoxIndex, newIconIndex);
@@ -300,33 +300,33 @@ void ChampionMan::drawChangedObjectIcons() { MenuMan &menuMan = *_vm->_menuMan;
uint16 invChampOrdinal = invMan._inventoryChampionOrdinal;
- if (_candidateChampionOrdinal && !invChampOrdinal)
+ if (_g299_candidateChampionOrdinal && !invChampOrdinal)
return;
- _mousePointerHiddenToDrawChangedObjIconOnScreen = false;
- IconIndice leaderHandObjIconIndex = _leaderHandObjectIconIndex;
+ _g420_mousePointerHiddenToDrawChangedObjIconOnScreen = false;
+ IconIndice leaderHandObjIconIndex = _g413_leaderHandObjectIconIndex;
- if (((leaderHandObjIconIndex < kIconIndiceWeaponDagger) && (leaderHandObjIconIndex >= kIconIndiceJunkCompassNorth)) // < instead of <= is correct
- || ((leaderHandObjIconIndex >= kIconIndicePotionMaPotionMonPotion) && (leaderHandObjIconIndex <= kIconIndicePotionWaterFlask))
- || (leaderHandObjIconIndex == kIconIndicePotionEmptyFlask)) {
- IconIndice iconIndex = objMan.getIconIndex(_leaderHandObject);
+ if (((leaderHandObjIconIndex < k32_IconIndiceWeaponDagger) && (leaderHandObjIconIndex >= k0_IconIndiceJunkCompassNorth)) // < instead of <= is correct
+ || ((leaderHandObjIconIndex >= k148_IconIndicePotionMaPotionMonPotion) && (leaderHandObjIconIndex <= k163_IconIndicePotionWaterFlask))
+ || (leaderHandObjIconIndex == k195_IconIndicePotionEmptyFlask)) {
+ IconIndice iconIndex = objMan.getIconIndex(_414_leaderHandObject);
if (iconIndex != leaderHandObjIconIndex) {
- _mousePointerHiddenToDrawChangedObjIconOnScreen = true;
+ _g420_mousePointerHiddenToDrawChangedObjIconOnScreen = true;
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
objMan.extractIconFromBitmap(iconIndex, objMan._objectIconForMousePointer);
warning("MISSING CODE: F0068_MOUSE_SetPointerToObject");
- _leaderHandObjectIconIndex = iconIndex;
- objMan.drawLeaderObjectName(_leaderHandObject);
+ _g413_leaderHandObjectIconIndex = iconIndex;
+ objMan.drawLeaderObjectName(_414_leaderHandObject);
}
}
- for (uint16 slotBoxIndex = 0; slotBoxIndex < (_partyChampionCount * 2); ++slotBoxIndex) {
+ for (uint16 slotBoxIndex = 0; slotBoxIndex < (_g305_partyChampionCount * 2); ++slotBoxIndex) {
int16 champIndex = slotBoxIndex >> 1;
if (invChampOrdinal == _vm->indexToOrdinal(champIndex))
continue;
if (hasObjectIconInSlotBoxChanged(slotBoxIndex, _champions[champIndex].getSlot((ChampionSlot)handSlotIndex(slotBoxIndex)))
- && (handSlotIndex(slotBoxIndex) == kChampionSlotActionHand)) {
+ && (handSlotIndex(slotBoxIndex) == k1_ChampionSlotActionHand)) {
menuMan.drawActionIcon((ChampionIndex)champIndex);
}
@@ -334,13 +334,13 @@ void ChampionMan::drawChangedObjectIcons() { if (invChampOrdinal) {
Champion *champ = &_champions[_vm->ordinalToIndex(invChampOrdinal)];
- Thing *thing = &champ->getSlot(kChampionSlotReadyHand);
+ Thing *thing = &champ->getSlot(k0_ChampionSlotReadyHand);
uint16 drawViewport = 0;
- for (uint16 slotIndex = kChampionSlotReadyHand; slotIndex < kChampionSlotChest_1; slotIndex++, thing++) {
+ for (uint16 slotIndex = k0_ChampionSlotReadyHand; slotIndex < k30_ChampionSlotChest_1; slotIndex++, thing++) {
uint16 objIconChanged = hasObjectIconInSlotBoxChanged(slotIndex + kSlotBoxInventoryFirstSlot, *thing) ? 1 : 0;
drawViewport |= objIconChanged;
- if (objIconChanged && (slotIndex == kChampionSlotActionHand)) {
+ if (objIconChanged && (slotIndex == k1_ChampionSlotActionHand)) {
menuMan.drawActionIcon((ChampionIndex)_vm->ordinalToIndex(invChampOrdinal));
}
}
@@ -353,12 +353,12 @@ void ChampionMan::drawChangedObjectIcons() { }
if (drawViewport) {
- champ->setAttributeFlag(kChampionAttributeViewport, true);
+ champ->setAttributeFlag(k0x4000_ChampionAttributeViewport, true);
drawChampionState((ChampionIndex)_vm->ordinalToIndex(invChampOrdinal));
}
}
- if (_mousePointerHiddenToDrawChangedObjIconOnScreen)
+ if (_g420_mousePointerHiddenToDrawChangedObjIconOnScreen)
warning("MISSING CODE: F0078_MOUSE_ShowPointer");
}
@@ -373,49 +373,49 @@ void ChampionMan::addObjectInSlot(ChampionIndex champIndex, Thing thing, Champio Champion *champ = &_champions[champIndex];
- if (slotIndex >= kChampionSlotChest_1) {
- invMan._chestSlots[slotIndex - kChampionSlotChest_1] = thing;
+ if (slotIndex >= k30_ChampionSlotChest_1) {
+ invMan._chestSlots[slotIndex - k30_ChampionSlotChest_1] = thing;
} else {
champ->setSlot(slotIndex, thing);
}
champ->_load += dunMan.getObjectWeight(thing);
- champ->setAttributeFlag(kChampionAttributeLoad, true);
+ champ->setAttributeFlag(k0x0200_ChampionAttributeLoad, true);
IconIndice iconIndex = objMan.getIconIndex(thing);
bool isInventoryChampion = (_vm->indexToOrdinal(champIndex) == invMan._inventoryChampionOrdinal);
applyModifiersToStatistics(champ, slotIndex, iconIndex, 1, thing);
uint16 *rawObjPtr = dunMan.getThingData(thing);
- if (slotIndex < kChampionSlotHead) {
+ if (slotIndex < k2_ChampionSlotHead) {
- if (slotIndex == kChampionSlotActionHand) {
- champ->setAttributeFlag(kChampionAttributeActionHand, true);
- if (_actingChampionOrdinal == _vm->indexToOrdinal(champIndex))
+ if (slotIndex == k1_ChampionSlotActionHand) {
+ champ->setAttributeFlag(k0x8000_ChampionAttributeActionHand, true);
+ if (_g506_actingChampionOrdinal == _vm->indexToOrdinal(champIndex))
menuMan.clearActingChampion();
- if ((iconIndex >= kIconIndiceScrollOpen) && (iconIndex <= kIconIndiceScrollClosed)) {
+ if ((iconIndex >= k30_IconIndiceScrollOpen) && (iconIndex <= k31_IconIndiceScrollClosed)) {
((Scroll*)rawObjPtr)->setClosed(false);
drawChangedObjectIcons();
}
}
- if (iconIndex = kIconIndiceWeaponTorchUnlit) {
+ if (iconIndex = k4_IconIndiceWeaponTorchUnlit) {
((Weapon*)rawObjPtr)->setLit(true);
warning("MISSING CODE: F0337_INVENTORY_SetDungeonViewPalette");
drawChangedObjectIcons();
- } else if (isInventoryChampion && (slotIndex == kChampionSlotActionHand) &&
- ((iconIndex == kIconIndiceContainerChestClosed) || ((iconIndex >= kIconIndiceScrollOpen) && (iconIndex <= kIconIndiceScrollClosed)))) {
- champ->setAttributeFlag(kChampionAttributePanel, true);
+ } else if (isInventoryChampion && (slotIndex == k1_ChampionSlotActionHand) &&
+ ((iconIndex == k144_IconIndiceContainerChestClosed) || ((iconIndex >= k30_IconIndiceScrollOpen) && (iconIndex <= k31_IconIndiceScrollClosed)))) {
+ champ->setAttributeFlag(k0x0800_ChampionAttributePanel, true);
}
- } else if (slotIndex == kChampionSlotNeck) {
+ } else if (slotIndex == k10_ChampionSlotNeck) {
- if ((iconIndex >= kIconIndiceJunkIllumuletUnequipped) && (iconIndex <= kIconIndiceJunkIllumuletEquipped)) {
+ if ((iconIndex >= k12_IconIndiceJunkIllumuletUnequipped) && (iconIndex <= k13_IconIndiceJunkIllumuletEquipped)) {
((Junk*)rawObjPtr)->setChargeCount(1);
- _party._magicalLightAmount += gLightPowerToLightAmount[2];
+ _g407_party._magicalLightAmount += g39_LightPowerToLightAmount[2];
warning("MISSING CODE: F0337_INVENTORY_SetDungeonViewPalette");
iconIndex = (IconIndice) (iconIndex + 1);
- } else if ((iconIndex >= kIconIndiceJunkJewelSymalUnequipped) && (iconIndex <= kIconIndiceJunkJewelSymalEquipped)) {
+ } else if ((iconIndex >= k10_IconIndiceJunkJewelSymalUnequipped) && (iconIndex <= k11_IconIndiceJunkJewelSymalEquipped)) {
((Junk*)rawObjPtr)->setChargeCount(1);
iconIndex = (IconIndice) (iconIndex + 1);
}
@@ -424,16 +424,16 @@ void ChampionMan::addObjectInSlot(ChampionIndex champIndex, Thing thing, Champio drawSlot(champIndex, slotIndex);
if (isInventoryChampion)
- champ->setAttributeFlag(kChampionAttributeViewport, true);
+ champ->setAttributeFlag(k0x4000_ChampionAttributeViewport, true);
}
ChampionIndex ChampionMan::getIndexInCell(ViewCell cell) {
- for (uint16 i = 0; i < _partyChampionCount; ++i) {
+ for (uint16 i = 0; i < _g305_partyChampionCount; ++i) {
if ((_champions[i]._cell == cell) && _champions[i]._currHealth)
return (ChampionIndex)i;
}
- return kChampionNone;
+ return kM1_ChampionNone;
}
void ChampionMan::resetDataToStartGame() {
@@ -442,9 +442,9 @@ void ChampionMan::resetDataToStartGame() { assert(false);
}
- _leaderHandObject = Thing::_none;
- _leaderHandObjectIconIndex = kIconIndiceNone;
- _leaderEmptyHanded = true;
+ _414_leaderHandObject = Thing::_none;
+ _g413_leaderHandObjectIconIndex = kM1_IconIndiceNone;
+ _g415_leaderEmptyHanded = true;
}
@@ -452,10 +452,10 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { DisplayMan &dispMan = *_vm->_displayMan;
DungeonMan &dunMan = *_vm->_dungeonMan;
- if (!_leaderEmptyHanded || _partyChampionCount == 4)
+ if (!_g415_leaderEmptyHanded || _g305_partyChampionCount == 4)
return;
- uint16 prevChampCount = _partyChampionCount;
+ uint16 prevChampCount = _g305_partyChampionCount;
Champion *champ = &_champions[prevChampCount];
champ->resetToZero();
dispMan._g578_useByteBoxCoordinates = true;
@@ -465,20 +465,20 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { champ->_portrait, 32, destBox._x1, destBox._x2, destBox._y1, destBox._y2, k255_ColorNoTransparency);
}
- champ->_actionIndex = kChampionActionNone;
+ champ->_actionIndex = k255_ChampionActionNone;
champ->_enableActionEventIndex = -1;
champ->_hideDamageReceivedIndex = -1;
champ->_dir = dunMan._currMap._partyDir;
ViewCell AL_0_viewCell = k0_ViewCellFronLeft;
- while (getIndexInCell((ViewCell)((AL_0_viewCell + dunMan._currMap._partyDir) & 3)) != kChampionNone)
+ while (getIndexInCell((ViewCell)((AL_0_viewCell + dunMan._currMap._partyDir) & 3)) != kM1_ChampionNone)
AL_0_viewCell = (ViewCell)(AL_0_viewCell + 1);
champ->_cell = (ViewCell)((AL_0_viewCell + dunMan._currMap._partyDir) & 3);
- champ->clearAttributes(kChampionAttributeIcon);
+ champ->clearAttributes(k0x0400_ChampionAttributeIcon);
champ->_directionMaximumDamageReceived = dunMan._currMap._partyDir;
champ->_food = 1500 + _vm->_rnd->getRandomNumber(256);
champ->_water = 1500 + _vm->_rnd->getRandomNumber(256);
int16 AL_0_slotIndex_Red;
- for (AL_0_slotIndex_Red = kChampionSlotReadyHand; AL_0_slotIndex_Red < kChampionSlotChest_1; ++AL_0_slotIndex_Red) {
+ for (AL_0_slotIndex_Red = k0_ChampionSlotReadyHand; AL_0_slotIndex_Red < k30_ChampionSlotChest_1; ++AL_0_slotIndex_Red) {
champ->setSlot((ChampionSlot)AL_0_slotIndex_Red, Thing::_none);
}
Thing thing = dunMan.getSquareFirstThing(dunMan._currMap._partyPosX, dunMan._currMap._partyPosY);
@@ -508,7 +508,7 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { }
champ->_title[AL_0_characterIndex] = '\0';
if (*character_Green++ == 'M') {
- champ->setAttributeFlag(kChampionAttributeMale, true);
+ champ->setAttributeFlag(k0x0010_ChampionAttributeMale, true);
}
character_Green++;
champ->_currHealth = champ->_maxHealth = getDecodedValue(character_Green, 4);
@@ -520,26 +520,26 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { character_Green++;
int16 AL_0_statisticIndex;
- for (AL_0_statisticIndex = kChampionStatLuck; AL_0_statisticIndex <= kChampionStatAntifire; ++AL_0_statisticIndex) {
- champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, kChampionStatMinimum, 30);
+ for (AL_0_statisticIndex = k0_ChampionStatLuck; AL_0_statisticIndex <= k6_ChampionStatAntifire; ++AL_0_statisticIndex) {
+ champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, k2_ChampionStatMinimum, 30);
uint16 currMaxVal = getDecodedValue(character_Green, 2);
- champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, kChampionStatCurrent, currMaxVal);
- champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, kChampionStatMaximum, currMaxVal);
+ champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, k1_ChampionStatCurrent, currMaxVal);
+ champ->setStatistic((ChampionStatisticType)AL_0_statisticIndex, k0_ChampionStatMaximum, currMaxVal);
character_Green += 2;
}
- champ->setStatistic(kChampionStatLuck, kChampionStatMinimum, 10);
+ champ->setStatistic(k0_ChampionStatLuck, k2_ChampionStatMinimum, 10);
character_Green++;
int16 AL_0_skillIndex;
int16 AL_2_skillValue;
- for (AL_0_skillIndex = kChampionSkillSwing; AL_0_skillIndex <= kChampionSkillWater; AL_0_skillIndex++) {
+ for (AL_0_skillIndex = k4_ChampionSkillSwing; AL_0_skillIndex <= k19_ChampionSkillWater; AL_0_skillIndex++) {
if ((AL_2_skillValue = *character_Green++ - 'A') > 0) {
champ->setSkillExp((ChampionSkill)AL_0_skillIndex, 125L << AL_2_skillValue);
}
}
- for (AL_0_skillIndex = kChampionSkillFighter; AL_0_skillIndex <= kChampionSkillWizard; ++AL_0_skillIndex) {
+ for (AL_0_skillIndex = k0_ChampionSkillFighter; AL_0_skillIndex <= k3_ChampionSkillWizard; ++AL_0_skillIndex) {
int32 baseSkillExp = 0;
int16 hiddenSkillIndex = (AL_0_skillIndex + 1) << 2;
for (uint16 AL_4_hiddenSkillCounter = 0; AL_4_hiddenSkillCounter < 4; ++AL_4_hiddenSkillCounter) {
@@ -548,13 +548,13 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { champ->setSkillExp((ChampionSkill)AL_0_skillIndex, baseSkillExp);
}
- _candidateChampionOrdinal = prevChampCount + 1;
- if (++_partyChampionCount == 1) {
- _vm->_eventMan->commandSetLeader(kChampionFirst);
+ _g299_candidateChampionOrdinal = prevChampCount + 1;
+ if (++_g305_partyChampionCount == 1) {
+ _vm->_eventMan->commandSetLeader(k0_ChampionFirst);
_vm->_menuMan->_refreshActionArea = true;
} else {
_vm->_menuMan->clearActingChampion();
- _vm->_menuMan->drawActionIcon((ChampionIndex)(_partyChampionCount - 1));
+ _vm->_menuMan->drawActionIcon((ChampionIndex)(_g305_partyChampionCount - 1));
}
int16 mapX = _vm->_dungeonMan->_currMap._partyPosX;
@@ -564,7 +564,7 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { mapX += _vm->_dirIntoStepCountEast[dunMan._currMap._partyDir];
mapY += _vm->_dirIntoStepCountNorth[dunMan._currMap._partyDir];
thing = dunMan.getSquareFirstThing(mapX, mapY);
- AL_0_slotIndex_Red = kChampionSlotBackpackLine_1_1;
+ AL_0_slotIndex_Red = k13_ChampionSlotBackpackLine_1_1;
uint16 slotIndex_Green;
while (thing != Thing::_endOfList) {
ThingType AL_2_thingType = thing.getType();
@@ -572,29 +572,29 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { int16 objectAllowedSlots = gObjectInfo[dunMan.getObjectInfoIndex(thing)].getAllowedSlots();
switch (AL_2_thingType) {
case kArmourThingType:
- for (slotIndex_Green = kChampionSlotHead; slotIndex_Green <= kChampionSlotFeet; slotIndex_Green++) {
+ for (slotIndex_Green = k2_ChampionSlotHead; slotIndex_Green <= k5_ChampionSlotFeet; slotIndex_Green++) {
if (objectAllowedSlots & gSlotMasks[slotIndex_Green])
goto T0280048;
}
- if ((objectAllowedSlots & gSlotMasks[kChampionSlotNeck]) && (champ->getSlot(kChampionSlotNeck) == Thing::_none)) {
- slotIndex_Green = kChampionSlotNeck;
+ if ((objectAllowedSlots & gSlotMasks[k10_ChampionSlotNeck]) && (champ->getSlot(k10_ChampionSlotNeck) == Thing::_none)) {
+ slotIndex_Green = k10_ChampionSlotNeck;
} else {
goto T0280046;
}
break;
case kWeaponThingType:
- if (champ->getSlot(kChampionSlotActionHand) == Thing::_none) {
- slotIndex_Green = kChampionSlotActionHand;
+ if (champ->getSlot(k1_ChampionSlotActionHand) == Thing::_none) {
+ slotIndex_Green = k1_ChampionSlotActionHand;
} else {
goto T0280046;
}
break;
case kScrollThingType:
case kPotionThingType:
- if (champ->getSlot(kChampionSlotPouch_1) == Thing::_none) {
- slotIndex_Green = kChampionSlotPouch_1;
- } else if (champ->getSlot(kChampionSlotPouch_2) == Thing::_none) {
- slotIndex_Green = kChampionSlotPouch_2;
+ if (champ->getSlot(k11_ChampionSlotPouch_1) == Thing::_none) {
+ slotIndex_Green = k11_ChampionSlotPouch_1;
+ } else if (champ->getSlot(k6_ChampionSlotPouch_2) == Thing::_none) {
+ slotIndex_Green = k6_ChampionSlotPouch_2;
} else {
goto T0280046;
}
@@ -602,8 +602,8 @@ void ChampionMan::addCandidateChampionToParty(uint16 championPortraitIndex) { case kContainerThingType:
case kJunkThingType:
T0280046:
- if ((objectAllowedSlots & gSlotMasks[kChampionSlotNeck]) && (champ->getSlot(kChampionSlotNeck) == Thing::_none)) {
- slotIndex_Green = kChampionSlotNeck;
+ if ((objectAllowedSlots & gSlotMasks[k10_ChampionSlotNeck]) && (champ->getSlot(k10_ChampionSlotNeck) == Thing::_none)) {
+ slotIndex_Green = k10_ChampionSlotNeck;
} else {
slotIndex_Green = AL_0_slotIndex_Red++;
}
@@ -676,12 +676,12 @@ void ChampionMan::drawChampionBarGraphs(ChampionIndex champIndex) { if (barGraphHeight < 25) {
box._y1 = 2;
box._y1 = 27 - barGraphHeight + 1;
- _vm->_displayMan->clearScreenBox(gChampionColor[champIndex], box);
+ _vm->_displayMan->clearScreenBox(g46_ChampionColor[champIndex], box);
}
if (barGraphHeight) {
box._y1 = 27 - barGraphHeight;
box._y2 = 26 + 1;
- _vm->_displayMan->clearScreenBox(gChampionColor[champIndex], box);
+ _vm->_displayMan->clearScreenBox(g46_ChampionColor[champIndex], box);
}
box._x1 += 7;
box._x2 += 7;
@@ -702,13 +702,13 @@ uint16 ChampionMan::getStaminaAdjustedValue(Champion *champ, int16 val) { }
uint16 ChampionMan::getMaximumLoad(Champion *champ) {
- uint16 maximumLoad = champ->getStatistic(kChampionStatStrength, kChampionStatCurrent) * 8 + 100;
+ uint16 maximumLoad = champ->getStatistic(k1_ChampionStatStrength, k1_ChampionStatCurrent) * 8 + 100;
maximumLoad = getStaminaAdjustedValue(champ, maximumLoad);
int16 wounds = champ->getWounds();
if (wounds) {
- maximumLoad -= maximumLoad >> (champ->getWoundsFlag(kChampionWoundLegs) ? 2 : 3);
+ maximumLoad -= maximumLoad >> (champ->getWoundsFlag(k0x0010_ChampionWoundLegs) ? 2 : 3);
}
- if (_vm->_objectMan->getIconIndex(champ->getSlot(kChampionSlotFeet)) == kIconIndiceArmourElvenBoots) {
+ if (_vm->_objectMan->getIconIndex(champ->getSlot(k5_ChampionSlotFeet)) == k119_IconIndiceArmourElvenBoots) {
maximumLoad += maximumLoad * 16;
}
maximumLoad += 9;
@@ -726,14 +726,14 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { int16 champStatusBoxX = champIndex * kChampionStatusBoxSpacing;
Champion *champ = &_champions[champIndex];
uint16 champAttributes = champ->getAttributes();
- if (!((champAttributes) & (kChampionAttributeNameTitle | kChampionAttributeStatistics | kChampionAttributeLoad | kChampionAttributeIcon |
- kChampionAttributePanel | kChampionAttributeStatusBox | kChampionAttributeWounds | kChampionAttributeViewport |
- kChampionAttributeActionHand))) {
+ if (!((champAttributes) & (k0x0080_ChampionAttributeNameTitle | k0x0100_ChampionAttributeStatistics | k0x0200_ChampionAttributeLoad | k0x0400_ChampionAttributeIcon |
+ k0x0800_ChampionAttributePanel | k0x1000_ChampionAttributeStatusBox | k0x2000_ChampionAttributeWounds | k0x4000_ChampionAttributeViewport |
+ k0x8000_ChampionAttributeActionHand))) {
return;
}
bool isInventoryChamp = (_vm->indexToOrdinal(champIndex) == invMan._inventoryChampionOrdinal);
dispMan._g578_useByteBoxCoordinates = false;
- if (champAttributes & kChampionAttributeStatusBox) {
+ if (champAttributes & k0x1000_ChampionAttributeStatusBox) {
box._y1 = 0;
box._y2 = 28 + 1;
box._x1 = champStatusBoxX;
@@ -744,20 +744,20 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { for (int16 i = 0; i < 3; ++i)
nativeBitmapIndices[i] = 0;
int16 AL_0_borderCount = 0;
- if (_party._fireShieldDefense > 0)
+ if (_g407_party._fireShieldDefense > 0)
nativeBitmapIndices[AL_0_borderCount++] = k38_BorderPartyFireshieldIndice;
- if (_party._spellShieldDefense > 0)
+ if (_g407_party._spellShieldDefense > 0)
nativeBitmapIndices[AL_0_borderCount++] = k39_BorderPartySpellshieldIndice;
- if (_party._shieldDefense > 0)
+ if (_g407_party._shieldDefense > 0)
nativeBitmapIndices[AL_0_borderCount++] = k37_BorderPartyShieldIndice;
while (AL_0_borderCount--) {
dispMan.blitToScreen(dispMan.getBitmap(nativeBitmapIndices[AL_0_borderCount]), 80, 0, 0, box, k10_ColorFlesh);
}
if (isInventoryChamp) {
invMan.drawStatusBoxPortrait(champIndex);
- champAttributes |= kChampionAttributeStatistics;
+ champAttributes |= k0x0100_ChampionAttributeStatistics;
} else {
- champAttributes |= (kChampionAttributeNameTitle | kChampionAttributeStatistics | kChampionAttributeWounds | kChampionAttributeActionHand);
+ champAttributes |= (k0x0080_ChampionAttributeNameTitle | k0x0100_ChampionAttributeStatistics | k0x2000_ChampionAttributeWounds | k0x8000_ChampionAttributeActionHand);
}
} else {
dispMan.blitToScreen(dispMan.getBitmap(k8_StatusBoxDeadChampion), 80, 0, 0, box, k255_ColorNoTransparency);
@@ -770,8 +770,8 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { if (!champ->_currHealth)
goto T0292042_green;
- if (champAttributes & kChampionAttributeNameTitle) {
- Color AL_0_colorIndex = (champIndex == _leaderIndex) ? k9_ColorGold : k13_ColorLightestGray; // unused because of missing functions
+ if (champAttributes & k0x0080_ChampionAttributeNameTitle) {
+ Color AL_0_colorIndex = (champIndex == _g411_leaderIndex) ? k9_ColorGold : k13_ColorLightestGray; // unused because of missing functions
if (isInventoryChamp) {
char *champName = champ->_name;
_vm->_textMan->printToViewport(3, 7, AL_0_colorIndex, champName);
@@ -781,7 +781,7 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { champTitleX += 6;
}
_vm->_textMan->printToViewport(champTitleX, 7, AL_0_colorIndex, champ->_title);
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
} else {
box._y1 = 0;
box._y2 = 6 + 1;
@@ -792,7 +792,7 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { }
}
- if (champAttributes & kChampionAttributeStatistics) {
+ if (champAttributes & k0x0100_ChampionAttributeStatistics) {
drawChampionBarGraphs(champIndex);
if (isInventoryChamp) {
drawHealthStaminaManaValues(champ);
@@ -804,28 +804,28 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { }
dispMan.blitToScreen(dispMan.getBitmap(AL_2_nativeBitmapIndex), 32, 0, 0, gBoxMouth, k12_ColorDarkestGray, g296_DungeonViewport);
AL_2_nativeBitmapIndex = k33_SlotBoxNormalIndice;
- for (int16 AL_0_statisticIndex = kChampionStatStrength; AL_0_statisticIndex <= kChampionStatAntifire; AL_0_statisticIndex++) {
- if (champ->getStatistic((ChampionStatisticType)AL_0_statisticIndex, kChampionStatCurrent)
- < champ->getStatistic((ChampionStatisticType)AL_0_statisticIndex, kChampionStatMaximum)) {
+ for (int16 AL_0_statisticIndex = k1_ChampionStatStrength; AL_0_statisticIndex <= k6_ChampionStatAntifire; AL_0_statisticIndex++) {
+ if (champ->getStatistic((ChampionStatisticType)AL_0_statisticIndex, k1_ChampionStatCurrent)
+ < champ->getStatistic((ChampionStatisticType)AL_0_statisticIndex, k0_ChampionStatMaximum)) {
AL_2_nativeBitmapIndex = k34_SlotBoxWoundedIndice;
break;
}
}
dispMan.blitToScreen(dispMan.getBitmap(AL_2_nativeBitmapIndex), 32, 0, 0, gBoxEye, k12_ColorDarkestGray, g296_DungeonViewport);
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
}
}
- if (champAttributes & kChampionAttributeWounds) {
- for (int16 AL_0_slotIndex = isInventoryChamp ? kChampionSlotFeet : kChampionSlotActionHand; AL_0_slotIndex >= kChampionSlotReadyHand; AL_0_slotIndex--) {
+ if (champAttributes & k0x2000_ChampionAttributeWounds) {
+ for (int16 AL_0_slotIndex = isInventoryChamp ? k5_ChampionSlotFeet : k1_ChampionSlotActionHand; AL_0_slotIndex >= k0_ChampionSlotReadyHand; AL_0_slotIndex--) {
drawSlot(champIndex, (ChampionSlot)AL_0_slotIndex);
}
if (isInventoryChamp) {
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
}
}
- if ((champAttributes & kChampionAttributeLoad) && isInventoryChamp) {
+ if ((champAttributes & k0x0200_ChampionAttributeLoad) && isInventoryChamp) {
Color loadColor;
int16 champMaxLoad = getMaximumLoad(champ);
if (champ->_load > champMaxLoad) {
@@ -846,49 +846,49 @@ void ChampionMan::drawChampionState(ChampionIndex champIndex) { loadTmp = (getMaximumLoad(champ) + 5) / 10;
str += "KG";
_vm->_textMan->printToViewport(148, 132, loadColor, str.c_str());
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
}
{ // block so goto won't skip AL_0_championIconIndex initialization
int16 AL_0_championIconIndex = championIconIndex(champ->_cell, _vm->_dungeonMan->_currMap._partyDir);
if ((champAttributes & k28_ChampionIcons) && (eventMan._useChampionIconOrdinalAsMousePointerBitmap != _vm->indexToOrdinal(AL_0_championIconIndex))) {
- dispMan.clearScreenBox(gChampionColor[champIndex], gBoxChampionIcons[AL_0_championIconIndex]);
+ dispMan.clearScreenBox(g46_ChampionColor[champIndex], g54_BoxChampionIcons[AL_0_championIconIndex]);
dispMan.blitToScreen(dispMan.getBitmap(k28_ChampionIcons), 80, championIconIndex(champ->_dir, _vm->_dungeonMan->_currMap._partyDir) * 19, 0,
- gBoxChampionIcons[AL_0_championIconIndex], k12_ColorDarkestGray);
+ g54_BoxChampionIcons[AL_0_championIconIndex], k12_ColorDarkestGray);
}
}
- if ((champAttributes & kChampionAttributePanel) && isInventoryChamp) {
+ if ((champAttributes & k0x0800_ChampionAttributePanel) && isInventoryChamp) {
if (_vm->_pressingMouth) {
invMan.drawPanelFoodWaterPoisoned();
} else if (_vm->_pressingEye) {
- if (_leaderEmptyHanded) {
+ if (_g415_leaderEmptyHanded) {
warning("MISSING CODE: F0351_INVENTORY_DrawChampionSkillsAndStatistics");
}
} else {
invMan.drawPanel();
}
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
}
- if (champAttributes & kChampionAttributeActionHand) {
- drawSlot(champIndex, kChampionSlotActionHand);
+ if (champAttributes & k0x8000_ChampionAttributeActionHand) {
+ drawSlot(champIndex, k1_ChampionSlotActionHand);
menuMan.drawActionIcon(champIndex);
if (isInventoryChamp) {
- champAttributes |= kChampionAttributeViewport;
+ champAttributes |= k0x4000_ChampionAttributeViewport;
}
}
- if (champAttributes & kChampionAttributeViewport) {
+ if (champAttributes & k0x4000_ChampionAttributeViewport) {
warning("MISSGIN CODE: F0097_DUNGEONVIEW_DrawViewport");
}
T0292042_green:
- champ->setAttributeFlag((ChampionAttribute)(kChampionAttributeNameTitle | kChampionAttributeStatistics | kChampionAttributeLoad | kChampionAttributeIcon |
- kChampionAttributePanel | kChampionAttributeStatusBox | kChampionAttributeWounds | kChampionAttributeViewport |
- kChampionAttributeActionHand), false);
+ champ->setAttributeFlag((ChampionAttribute)(k0x0080_ChampionAttributeNameTitle | k0x0100_ChampionAttributeStatistics | k0x0200_ChampionAttributeLoad | k0x0400_ChampionAttributeIcon |
+ k0x0800_ChampionAttributePanel | k0x1000_ChampionAttributeStatusBox | k0x2000_ChampionAttributeWounds | k0x4000_ChampionAttributeViewport |
+ k0x8000_ChampionAttributeActionHand), false);
warning("MISSING CODE: F0078_MOUSE_ShowPointer");
}
@@ -909,7 +909,7 @@ void ChampionMan::drawSlot(uint16 champIndex, ChampionSlot slotIndex) { uint16 slotBoxIndex;
if (!isInventoryChamp) { /* If drawing a slot for a champion other than the champion whose inventory is open */
- if ((slotIndex > kChampionSlotActionHand) || (_candidateChampionOrdinal == _vm->indexToOrdinal(champIndex))) {
+ if ((slotIndex > k1_ChampionSlotActionHand) || (_g299_candidateChampionOrdinal == _vm->indexToOrdinal(champIndex))) {
return;
}
slotBoxIndex = (champIndex << 1) + slotIndex;
@@ -918,8 +918,8 @@ void ChampionMan::drawSlot(uint16 champIndex, ChampionSlot slotIndex) { }
Thing thing;
- if (slotIndex >= kChampionSlotChest_1) {
- thing = _vm->_inventoryMan->_chestSlots[slotIndex - kChampionSlotChest_1];
+ if (slotIndex >= k30_ChampionSlotChest_1) {
+ thing = _vm->_inventoryMan->_chestSlots[slotIndex - k30_ChampionSlotChest_1];
} else {
thing = champ->getSlot(slotIndex);
}
@@ -938,8 +938,8 @@ void ChampionMan::drawSlot(uint16 champIndex, ChampionSlot slotIndex) { int16 iconIndex;
if (thing == Thing::_none) {
- if (slotIndex <= kChampionSlotFeet) {
- iconIndex = kIconIndiceReadyHand + (slotIndex << 1);
+ if (slotIndex <= k5_ChampionSlotFeet) {
+ iconIndex = k212_IconIndiceReadyHand + (slotIndex << 1);
if (champ->getWoundsFlag((ChampionWound)(1 << slotIndex))) {
iconIndex++;
nativeBitmapIndex = k34_SlotBoxWoundedIndice;
@@ -947,20 +947,20 @@ void ChampionMan::drawSlot(uint16 champIndex, ChampionSlot slotIndex) { nativeBitmapIndex = k33_SlotBoxNormalIndice;
}
} else {
- if ((slotIndex >= kChampionSlotNeck) && (slotIndex <= kChampionSlotBackpackLine_1_1)) {
- iconIndex = kIconIndiceNeck + (slotIndex - kChampionSlotNeck);
+ if ((slotIndex >= k10_ChampionSlotNeck) && (slotIndex <= k13_ChampionSlotBackpackLine_1_1)) {
+ iconIndex = k208_IconIndiceNeck + (slotIndex - k10_ChampionSlotNeck);
} else {
- iconIndex = kIconIndiceEmptyBox;
+ iconIndex = k204_IconIndiceEmptyBox;
}
}
} else {
warning("BUG0_35");
iconIndex = _vm->_objectMan->getIconIndex(thing); // BUG0_35
- if (isInventoryChamp && (slotIndex == kChampionSlotActionHand) && ((iconIndex == kIconIndiceContainerChestClosed) || (iconIndex == kIconIndiceScrollOpen))) {
+ if (isInventoryChamp && (slotIndex == k1_ChampionSlotActionHand) && ((iconIndex == k144_IconIndiceContainerChestClosed) || (iconIndex == k30_IconIndiceScrollOpen))) {
warning("BUG2_00");
iconIndex++;
} // BUG2_00
- if (slotIndex <= kChampionSlotFeet) {
+ if (slotIndex <= k5_ChampionSlotFeet) {
if (champ->getWoundsFlag((ChampionWound)(1 << slotIndex))) {
nativeBitmapIndex = k34_SlotBoxWoundedIndice;
} else {
@@ -969,7 +969,7 @@ void ChampionMan::drawSlot(uint16 champIndex, ChampionSlot slotIndex) { }
}
- if ((slotIndex == kChampionSlotActionHand) && (_vm->indexToOrdinal(champIndex) == _actingChampionOrdinal)) {
+ if ((slotIndex == k1_ChampionSlotActionHand) && (_vm->indexToOrdinal(champIndex) == _g506_actingChampionOrdinal)) {
nativeBitmapIndex = k35_SlotBoxActingHandIndice;
}
@@ -1014,11 +1014,11 @@ void ChampionMan::renameChampion(Champion* champ) { }
uint16 ChampionMan::getSkillLevel(ChampionIndex champIndex, ChampionSkill skillIndex) {
- if (_partyIsSleeping)
+ if (_g300_partyIsSleeping)
return 1;
- bool ignoreTempExp = skillIndex & kIgnoreTemporaryExperience;
- bool ignoreObjModifiers = skillIndex & kIgnoreObjectModifiers;
+ bool ignoreTempExp = skillIndex & k0x8000_IgnoreTemporaryExperience;
+ bool ignoreObjModifiers = skillIndex & k0x4000_IgnoreObjectModifiers;
skillIndex = (ChampionSkill)(skillIndex & ~(ignoreTempExp | ignoreObjModifiers));
Champion *champ = &_champions[champIndex];
Skill *skill = &champ->getSkill(skillIndex);
@@ -1027,8 +1027,8 @@ uint16 ChampionMan::getSkillLevel(ChampionIndex champIndex, ChampionSkill skillI if (!ignoreTempExp)
experience += skill->_temporaryExperience;
- if (skillIndex > kChampionSkillWizard) { // hidden skill
- skill = &champ->getSkill((ChampionSkill)((skillIndex - kChampionSkillSwing) / 4));
+ if (skillIndex > k3_ChampionSkillWizard) { // hidden skill
+ skill = &champ->getSkill((ChampionSkill)((skillIndex - k4_ChampionSkillSwing) / 4));
experience += skill->_experience; // add exp to the base skill
if (!ignoreTempExp)
experience += skill->_temporaryExperience;
@@ -1043,30 +1043,30 @@ uint16 ChampionMan::getSkillLevel(ChampionIndex champIndex, ChampionSkill skillI }
if (!ignoreObjModifiers) {
- IconIndice actionHandIconIndex = _vm->_objectMan->getIconIndex(champ->getSlot(kChampionSlotActionHand));
- if (actionHandIconIndex == kIconIndiceWeaponTheFirestaff) {
+ IconIndice actionHandIconIndex = _vm->_objectMan->getIconIndex(champ->getSlot(k1_ChampionSlotActionHand));
+ if (actionHandIconIndex == k27_IconIndiceWeaponTheFirestaff) {
skillLevel++;
- } else if (actionHandIconIndex == kIconIndiceWeaponTheFirestaffComplete) {
+ } else if (actionHandIconIndex == k28_IconIndiceWeaponTheFirestaffComplete) {
skillLevel += 2;
}
- IconIndice neckIconIndice = _vm->_objectMan->getIconIndex(champ->getSlot(kChampionSlotNeck));
+ IconIndice neckIconIndice = _vm->_objectMan->getIconIndex(champ->getSlot(k10_ChampionSlotNeck));
switch (skillIndex) {
- case kChampionSkillWizard:
- if (neckIconIndice == kIconIndiceJunkPendantFeral)
+ case k3_ChampionSkillWizard:
+ if (neckIconIndice == k124_IconIndiceJunkPendantFeral)
skillLevel++;
break;
- case kChampionSkillDefend:
- if (neckIconIndice == kIconIndiceJunkEkkhardCross)
+ case k15_ChampionSkillDefend:
+ if (neckIconIndice == k121_IconIndiceJunkEkkhardCross)
skillLevel++;
break;
- case kChampionSkillHeal:
+ case k13_ChampionSkillHeal:
// these two are not cummulative
- if ((neckIconIndice == kIconIndiceJunkGemOfAges) || (neckIconIndice == kIconIndiceWeaponSceptreOfLyf))
+ if ((neckIconIndice == k120_IconIndiceJunkGemOfAges) || (neckIconIndice == k66_IconIndiceWeaponSceptreOfLyf))
skillLevel++;
break;
- case kChampionSkillInfluence:
- if (neckIconIndice == kIconIndiceJunkMoonstone)
+ case k14_ChampionSkillInfluence:
+ if (neckIconIndice == k122_IconIndiceJunkMoonstone)
skillLevel++;
break;
}
diff --git a/engines/dm/champion.h b/engines/dm/champion.h index c1abca1888..cd6694669b 100644 --- a/engines/dm/champion.h +++ b/engines/dm/champion.h @@ -35,13 +35,13 @@ namespace DM { -#define kIgnoreObjectModifiers 0x4000 // @ MASK0x4000_IGNORE_OBJECT_MODIFIERS -#define kIgnoreTemporaryExperience 0x8000 // @ MASK0x8000_IGNORE_TEMPORARY_EXPERIENCE +#define k0x4000_IgnoreObjectModifiers 0x4000 // @ MASK0x4000_IGNORE_OBJECT_MODIFIERS +#define k0x8000_IgnoreTemporaryExperience 0x8000 // @ MASK0x8000_IGNORE_TEMPORARY_EXPERIENCE -extern Box gBoxChampionIcons[4]; // @ G0054_ai_Graphic562_Box_ChampionIcons -extern Color gChampionColor[4]; // @ G0046_auc_Graphic562_ChampionColor +extern Box g54_BoxChampionIcons[4]; // @ G0054_ai_Graphic562_Box_ChampionIcons +extern Color g46_ChampionColor[4]; // @ G0046_auc_Graphic562_ChampionColor -extern int16 gLightPowerToLightAmount[16]; // @ G0039_ai_Graphic562_LightPowerToLightAmount +extern int16 g39_LightPowerToLightAmount[16]; // @ G0039_ai_Graphic562_LightPowerToLightAmount class Scent { uint16 _scent; @@ -84,246 +84,246 @@ public: }; // @ PARTY enum IconIndice { - kIconIndiceNone = -1, // @ CM1_ICON_NONE - kIconIndiceJunkCompassNorth = 0, // @ C000_ICON_JUNK_COMPASS_NORTH - kIconIndiceJunkCompassWest = 3, // @ C003_ICON_JUNK_COMPASS_WEST - kIconIndiceWeaponTorchUnlit = 4, // @ C004_ICON_WEAPON_TORCH_UNLIT - kIconIndiceWeaponTorchLit = 7, // @ C007_ICON_WEAPON_TORCH_LIT - kIconIndiceJunkWater = 8, // @ C008_ICON_JUNK_WATER - kIconIndiceJunkWaterSkin = 9, // @ C009_ICON_JUNK_WATERSKIN - kIconIndiceJunkJewelSymalUnequipped = 10, // @ C010_ICON_JUNK_JEWEL_SYMAL_UNEQUIPPED - kIconIndiceJunkJewelSymalEquipped = 11, // @ C011_ICON_JUNK_JEWEL_SYMAL_EQUIPPED - kIconIndiceJunkIllumuletUnequipped = 12, // @ C012_ICON_JUNK_ILLUMULET_UNEQUIPPED - kIconIndiceJunkIllumuletEquipped = 13, // @ C013_ICON_JUNK_ILLUMULET_EQUIPPED - kIconIndiceWeaponFlamittEmpty = 14, // @ C014_ICON_WEAPON_FLAMITT_EMPTY - kIconIndiceWeaponEyeOfTimeEmpty = 16, // @ C016_ICON_WEAPON_EYE_OF_TIME_EMPTY - kIconIndiceWeaponStormringEmpty = 18, // @ C018_ICON_WEAPON_STORMRING_EMPTY - kIconIndiceWeaponStaffOfClawsEmpty = 20, // @ C020_ICON_WEAPON_STAFF_OF_CLAWS_EMPTY - kIconIndiceWeaponStaffOfClawsFull = 22, // @ C022_ICON_WEAPON_STAFF_OF_CLAWS_FULL - kIconIndiceWeaponBoltBladeStormEmpty = 23, // @ C023_ICON_WEAPON_BOLT_BLADE_STORM_EMPTY - kIconIndiceWeaponFuryRaBladeEmpty = 25, // @ C025_ICON_WEAPON_FURY_RA_BLADE_EMPTY - kIconIndiceWeaponTheFirestaff = 27, // @ C027_ICON_WEAPON_THE_FIRESTAFF - kIconIndiceWeaponTheFirestaffComplete = 28, // @ C028_ICON_WEAPON_THE_FIRESTAFF_COMPLETE - kIconIndiceScrollOpen = 30, // @ C030_ICON_SCROLL_SCROLL_OPEN - kIconIndiceScrollClosed = 31, // @ C031_ICON_SCROLL_SCROLL_CLOSED - kIconIndiceWeaponDagger = 32, // @ C032_ICON_WEAPON_DAGGER - kIconIndiceWeaponDeltaSideSplitter = 38, // @ C038_ICON_WEAPON_DELTA_SIDE_SPLITTER - kIconIndiceWeaponDiamondEdge = 39, // @ C039_ICON_WEAPON_DIAMOND_EDGE - kIconIndiceWeaponVorpalBlade = 40, // @ C040_ICON_WEAPON_VORPAL_BLADE - kIconIndiceWeaponTheInquisitorDragonFang = 41, // @ C041_ICON_WEAPON_THE_INQUISITOR_DRAGON_FANG - kIconIndiceWeaponHardcleaveExecutioner = 43, // @ C043_ICON_WEAPON_HARDCLEAVE_EXECUTIONER - kIconIndiceWeaponMaceOfOrder = 45, // @ C045_ICON_WEAPON_MACE_OF_ORDER - kIconIndiceWeaponArrow = 51, // @ C051_ICON_WEAPON_ARROW - kIconIndiceWeaponSlayer = 52, // @ C052_ICON_WEAPON_SLAYER - kIconIndiceWeaponRock = 54, // @ C054_ICON_WEAPON_ROCK - kIconIndiceWeaponPoisonDart = 55, // @ C055_ICON_WEAPON_POISON_DART - kIconIndiceWeaponThrowingStar = 56, // @ C056_ICON_WEAPON_THROWING_STAR - kIconIndiceWeaponStaff = 58, // @ C058_ICON_WEAPON_STAFF - kIconIndiceWeaponWand = 59, // @ C059_ICON_WEAPON_WAND - kIconIndiceWeaponTeowand = 60, // @ C060_ICON_WEAPON_TEOWAND - kIconIndiceWeaponYewStaff = 61, // @ C061_ICON_WEAPON_YEW_STAFF - kIconIndiceWeaponStaffOfManarStaffOfIrra = 62, // @ C062_ICON_WEAPON_STAFF_OF_MANAR_STAFF_OF_IRRA - kIconIndiceWeaponSnakeStaffCrossOfNeta = 63, // @ C063_ICON_WEAPON_SNAKE_STAFF_CROSS_OF_NETA - kIconIndiceWeaponTheConduitSerpentStaff = 64, // @ C064_ICON_WEAPON_THE_CONDUIT_SERPENT_STAFF - kIconIndiceWeaponDragonSpit = 65, // @ C065_ICON_WEAPON_DRAGON_SPIT - kIconIndiceWeaponSceptreOfLyf = 66, // @ C066_ICON_WEAPON_SCEPTRE_OF_LYF - kIconIndiceArmourCloakOfNight = 81, // @ C081_ICON_ARMOUR_CLOAK_OF_NIGHT - kIconIndiceArmourCrownOfNerra = 104, // @ C104_ICON_ARMOUR_CROWN_OF_NERRA - kIconIndiceArmourElvenBoots = 119, // @ C119_ICON_ARMOUR_ELVEN_BOOTS - kIconIndiceJunkGemOfAges = 120, // @ C120_ICON_JUNK_GEM_OF_AGES - kIconIndiceJunkEkkhardCross = 121, // @ C121_ICON_JUNK_EKKHARD_CROSS - kIconIndiceJunkMoonstone = 122, // @ C122_ICON_JUNK_MOONSTONE - kIconIndiceJunkPendantFeral = 124, // @ C124_ICON_JUNK_PENDANT_FERAL - kIconIndiceJunkBoulder = 128, // @ C128_ICON_JUNK_BOULDER - kIconIndiceJunkRabbitsFoot = 137, // @ C137_ICON_JUNK_RABBITS_FOOT - kIconIndiceArmourDexhelm = 140, // @ C140_ICON_ARMOUR_DEXHELM - kIconIndiceArmourFlamebain = 141, // @ C141_ICON_ARMOUR_FLAMEBAIN - kIconIndiceArmourPowertowers = 142, // @ C142_ICON_ARMOUR_POWERTOWERS - kIconIndiceContainerChestClosed = 144, // @ C144_ICON_CONTAINER_CHEST_CLOSED - kIconIndiceContainerChestOpen = 145, // @ C145_ICON_CONTAINER_CHEST_OPEN - kIconIndiceJunkChampionBones = 147, // @ C147_ICON_JUNK_CHAMPION_BONES - kIconIndicePotionMaPotionMonPotion = 148, // @ C148_ICON_POTION_MA_POTION_MON_POTION - kIconIndicePotionWaterFlask = 163, // @ C163_ICON_POTION_WATER_FLASK - kIconIndiceJunkApple = 168, // @ C168_ICON_JUNK_APPLE - kIconIndiceJunkIronKey = 176, // @ C176_ICON_JUNK_IRON_KEY - kIconIndiceJunkMasterKey = 191, // @ C191_ICON_JUNK_MASTER_KEY - kIconIndiceArmourBootOfSpeed = 194, // @ C194_ICON_ARMOUR_BOOT_OF_SPEED - kIconIndicePotionEmptyFlask = 195, // @ C195_ICON_POTION_EMPTY_FLASK - kIconIndiceJunkZokathra = 197, // @ C197_ICON_JUNK_ZOKATHRA - kIconIndiceActionEmptyHand = 201, // @ C201_ICON_ACTION_ICON_EMPTY_HAND - kIconIndiceEyeNotLooking = 202, // @ C202_ICON_EYE_NOT_LOOKING /* One pixel is different in this bitmap from the eye in C017_GRAPHIC_INVENTORY. This is visible by selecting another champion after clicking the eye */ - kIconIndiceEyeLooking = 203, // @ C203_ICON_EYE_LOOKING - kIconIndiceEmptyBox = 204, // @ C204_ICON_EMPTY_BOX - kIconIndiceMouthOpen = 205, // @ C205_ICON_MOUTH_OPEN - kIconIndiceNeck = 208, // @ C208_ICON_NECK - kIconIndiceReadyHand = 212 // @ C212_ICON_READY_HAND + kM1_IconIndiceNone = -1, // @ CM1_ICON_NONE + k0_IconIndiceJunkCompassNorth = 0, // @ C000_ICON_JUNK_COMPASS_NORTH + k3_IconIndiceJunkCompassWest = 3, // @ C003_ICON_JUNK_COMPASS_WEST + k4_IconIndiceWeaponTorchUnlit = 4, // @ C004_ICON_WEAPON_TORCH_UNLIT + k7_IconIndiceWeaponTorchLit = 7, // @ C007_ICON_WEAPON_TORCH_LIT + k8_IconIndiceJunkWater = 8, // @ C008_ICON_JUNK_WATER + k9_IconIndiceJunkWaterSkin = 9, // @ C009_ICON_JUNK_WATERSKIN + k10_IconIndiceJunkJewelSymalUnequipped = 10, // @ C010_ICON_JUNK_JEWEL_SYMAL_UNEQUIPPED + k11_IconIndiceJunkJewelSymalEquipped = 11, // @ C011_ICON_JUNK_JEWEL_SYMAL_EQUIPPED + k12_IconIndiceJunkIllumuletUnequipped = 12, // @ C012_ICON_JUNK_ILLUMULET_UNEQUIPPED + k13_IconIndiceJunkIllumuletEquipped = 13, // @ C013_ICON_JUNK_ILLUMULET_EQUIPPED + k14_IconIndiceWeaponFlamittEmpty = 14, // @ C014_ICON_WEAPON_FLAMITT_EMPTY + k16_IconIndiceWeaponEyeOfTimeEmpty = 16, // @ C016_ICON_WEAPON_EYE_OF_TIME_EMPTY + k18_IconIndiceWeaponStormringEmpty = 18, // @ C018_ICON_WEAPON_STORMRING_EMPTY + k20_IconIndiceWeaponStaffOfClawsEmpty = 20, // @ C020_ICON_WEAPON_STAFF_OF_CLAWS_EMPTY + k22_IconIndiceWeaponStaffOfClawsFull = 22, // @ C022_ICON_WEAPON_STAFF_OF_CLAWS_FULL + k23_IconIndiceWeaponBoltBladeStormEmpty = 23, // @ C023_ICON_WEAPON_BOLT_BLADE_STORM_EMPTY + k25_IconIndiceWeaponFuryRaBladeEmpty = 25, // @ C025_ICON_WEAPON_FURY_RA_BLADE_EMPTY + k27_IconIndiceWeaponTheFirestaff = 27, // @ C027_ICON_WEAPON_THE_FIRESTAFF + k28_IconIndiceWeaponTheFirestaffComplete = 28, // @ C028_ICON_WEAPON_THE_FIRESTAFF_COMPLETE + k30_IconIndiceScrollOpen = 30, // @ C030_ICON_SCROLL_SCROLL_OPEN + k31_IconIndiceScrollClosed = 31, // @ C031_ICON_SCROLL_SCROLL_CLOSED + k32_IconIndiceWeaponDagger = 32, // @ C032_ICON_WEAPON_DAGGER + k38_IconIndiceWeaponDeltaSideSplitter = 38, // @ C038_ICON_WEAPON_DELTA_SIDE_SPLITTER + k39_IconIndiceWeaponDiamondEdge = 39, // @ C039_ICON_WEAPON_DIAMOND_EDGE + k40_IconIndiceWeaponVorpalBlade = 40, // @ C040_ICON_WEAPON_VORPAL_BLADE + k41_IconIndiceWeaponTheInquisitorDragonFang = 41, // @ C041_ICON_WEAPON_THE_INQUISITOR_DRAGON_FANG + k43_IconIndiceWeaponHardcleaveExecutioner = 43, // @ C043_ICON_WEAPON_HARDCLEAVE_EXECUTIONER + k45_IconIndiceWeaponMaceOfOrder = 45, // @ C045_ICON_WEAPON_MACE_OF_ORDER + k51_IconIndiceWeaponArrow = 51, // @ C051_ICON_WEAPON_ARROW + k52_IconIndiceWeaponSlayer = 52, // @ C052_ICON_WEAPON_SLAYER + k54_IconIndiceWeaponRock = 54, // @ C054_ICON_WEAPON_ROCK + k55_IconIndiceWeaponPoisonDart = 55, // @ C055_ICON_WEAPON_POISON_DART + k56_IconIndiceWeaponThrowingStar = 56, // @ C056_ICON_WEAPON_THROWING_STAR + k58_IconIndiceWeaponStaff = 58, // @ C058_ICON_WEAPON_STAFF + k59_IconIndiceWeaponWand = 59, // @ C059_ICON_WEAPON_WAND + k60_IconIndiceWeaponTeowand = 60, // @ C060_ICON_WEAPON_TEOWAND + k61_IconIndiceWeaponYewStaff = 61, // @ C061_ICON_WEAPON_YEW_STAFF + k62_IconIndiceWeaponStaffOfManarStaffOfIrra = 62, // @ C062_ICON_WEAPON_STAFF_OF_MANAR_STAFF_OF_IRRA + k63_IconIndiceWeaponSnakeStaffCrossOfNeta = 63, // @ C063_ICON_WEAPON_SNAKE_STAFF_CROSS_OF_NETA + k64_IconIndiceWeaponTheConduitSerpentStaff = 64, // @ C064_ICON_WEAPON_THE_CONDUIT_SERPENT_STAFF + k65_IconIndiceWeaponDragonSpit = 65, // @ C065_ICON_WEAPON_DRAGON_SPIT + k66_IconIndiceWeaponSceptreOfLyf = 66, // @ C066_ICON_WEAPON_SCEPTRE_OF_LYF + k81_IconIndiceArmourCloakOfNight = 81, // @ C081_ICON_ARMOUR_CLOAK_OF_NIGHT + k104_IconIndiceArmourCrownOfNerra = 104, // @ C104_ICON_ARMOUR_CROWN_OF_NERRA + k119_IconIndiceArmourElvenBoots = 119, // @ C119_ICON_ARMOUR_ELVEN_BOOTS + k120_IconIndiceJunkGemOfAges = 120, // @ C120_ICON_JUNK_GEM_OF_AGES + k121_IconIndiceJunkEkkhardCross = 121, // @ C121_ICON_JUNK_EKKHARD_CROSS + k122_IconIndiceJunkMoonstone = 122, // @ C122_ICON_JUNK_MOONSTONE + k124_IconIndiceJunkPendantFeral = 124, // @ C124_ICON_JUNK_PENDANT_FERAL + k128_IconIndiceJunkBoulder = 128, // @ C128_ICON_JUNK_BOULDER + k137_IconIndiceJunkRabbitsFoot = 137, // @ C137_ICON_JUNK_RABBITS_FOOT + k140_IconIndiceArmourDexhelm = 140, // @ C140_ICON_ARMOUR_DEXHELM + k141_IconIndiceArmourFlamebain = 141, // @ C141_ICON_ARMOUR_FLAMEBAIN + k142_IconIndiceArmourPowertowers = 142, // @ C142_ICON_ARMOUR_POWERTOWERS + k144_IconIndiceContainerChestClosed = 144, // @ C144_ICON_CONTAINER_CHEST_CLOSED + k145_IconIndiceContainerChestOpen = 145, // @ C145_ICON_CONTAINER_CHEST_OPEN + k147_IconIndiceJunkChampionBones = 147, // @ C147_ICON_JUNK_CHAMPION_BONES + k148_IconIndicePotionMaPotionMonPotion = 148, // @ C148_ICON_POTION_MA_POTION_MON_POTION + k163_IconIndicePotionWaterFlask = 163, // @ C163_ICON_POTION_WATER_FLASK + k168_IconIndiceJunkApple = 168, // @ C168_ICON_JUNK_APPLE + k176_IconIndiceJunkIronKey = 176, // @ C176_ICON_JUNK_IRON_KEY + k191_IconIndiceJunkMasterKey = 191, // @ C191_ICON_JUNK_MASTER_KEY + k194_IconIndiceArmourBootOfSpeed = 194, // @ C194_ICON_ARMOUR_BOOT_OF_SPEED + k195_IconIndicePotionEmptyFlask = 195, // @ C195_ICON_POTION_EMPTY_FLASK + k197_IconIndiceJunkZokathra = 197, // @ C197_ICON_JUNK_ZOKATHRA + k201_IconIndiceActionEmptyHand = 201, // @ C201_ICON_ACTION_ICON_EMPTY_HAND + k202_IconIndiceEyeNotLooking = 202, // @ C202_ICON_EYE_NOT_LOOKING /* One pixel is different in this bitmap from the eye in C017_GRAPHIC_INVENTORY. This is visible by selecting another champion after clicking the eye */ + k203_IconIndiceEyeLooking = 203, // @ C203_ICON_EYE_LOOKING + k204_IconIndiceEmptyBox = 204, // @ C204_ICON_EMPTY_BOX + k205_IconIndiceMouthOpen = 205, // @ C205_ICON_MOUTH_OPEN + k208_IconIndiceNeck = 208, // @ C208_ICON_NECK + k212_IconIndiceReadyHand = 212 // @ C212_ICON_READY_HAND }; enum ChampionIndex { - kChampionNone = -1, // @ CM1_CHAMPION_NONE - kChampionFirst = 0, // @ C00_CHAMPION_FIRST - kChampionSecond = 1, - kChampionThird = 2, - kChampionFourth = 3, - kChampionCloseInventory = 4, // @ C04_CHAMPION_CLOSE_INVENTORY - kChampionSpecialInventory = 5 // @ C05_CHAMPION_SPECIAL_INVENTORY + kM1_ChampionNone = -1, // @ CM1_CHAMPION_NONE + k0_ChampionFirst = 0, // @ C00_CHAMPION_FIRST + k1_ChampionSecond = 1, + k2_ChampionThird = 2, + k3_ChampionFourth = 3, + k4_ChampionCloseInventory = 4, // @ C04_CHAMPION_CLOSE_INVENTORY + k5_ChampionSpecialInventory = 5 // @ C05_CHAMPION_SPECIAL_INVENTORY }; enum ChampionAttribute { - kChampionAttributNone = 0x0000, // @ MASK0x0000_NONE - kChampionAttributeDisableAction = 0x0008, // @ MASK0x0008_DISABLE_ACTION - kChampionAttributeMale = 0x0010, // @ MASK0x0010_MALE - kChampionAttributeNameTitle = 0x0080, // @ MASK0x0080_NAME_TITLE - kChampionAttributeStatistics = 0x0100, // @ MASK0x0100_STATISTICS - kChampionAttributeLoad = 0x0200, // @ MASK0x0200_LOAD - kChampionAttributeIcon = 0x0400, // @ MASK0x0400_ICON - kChampionAttributePanel = 0x0800, // @ MASK0x0800_PANEL - kChampionAttributeStatusBox = 0x1000, // @ MASK0x1000_STATUS_BOX - kChampionAttributeWounds = 0x2000, // @ MASK0x2000_WOUNDS - kChampionAttributeViewport = 0x4000, // @ MASK0x4000_VIEWPORT - kChampionAttributeActionHand = 0x8000 // @ MASK0x8000_ACTION_HAND + k0x0000_ChampionAttributNone = 0x0000, // @ MASK0x0000_NONE + k0x0008_ChampionAttributeDisableAction = 0x0008, // @ MASK0x0008_DISABLE_ACTION + k0x0010_ChampionAttributeMale = 0x0010, // @ MASK0x0010_MALE + k0x0080_ChampionAttributeNameTitle = 0x0080, // @ MASK0x0080_NAME_TITLE + k0x0100_ChampionAttributeStatistics = 0x0100, // @ MASK0x0100_STATISTICS + k0x0200_ChampionAttributeLoad = 0x0200, // @ MASK0x0200_LOAD + k0x0400_ChampionAttributeIcon = 0x0400, // @ MASK0x0400_ICON + k0x0800_ChampionAttributePanel = 0x0800, // @ MASK0x0800_PANEL + k0x1000_ChampionAttributeStatusBox = 0x1000, // @ MASK0x1000_STATUS_BOX + k0x2000_ChampionAttributeWounds = 0x2000, // @ MASK0x2000_WOUNDS + k0x4000_ChampionAttributeViewport = 0x4000, // @ MASK0x4000_VIEWPORT + k0x8000_ChampionAttributeActionHand = 0x8000 // @ MASK0x8000_ACTION_HAND }; enum ChampionWound { - kChampionWoundNone = 0x0000, // @ MASK0x0000_NO_WOUND - kChampionWoundReadHand = 0x0001, // @ MASK0x0001_READY_HAND - kChampionWoundActionHand = 0x0002, // @ MASK0x0002_ACTION_HAND - kChampionWoundHead = 0x0004, // @ MASK0x0004_HEAD - kChampionWoundTorso = 0x0008, // @ MASK0x0008_TORSO - kChampionWoundLegs = 0x0010, // @ MASK0x0010_LEGS - kChampionWoundFeet = 0x0020 // @ MASK0x0020_FEET + k0x0000_ChampionWoundNone = 0x0000, // @ MASK0x0000_NO_WOUND + k0x0001_ChampionWoundReadHand = 0x0001, // @ MASK0x0001_READY_HAND + k0x0002_ChampionWoundActionHand = 0x0002, // @ MASK0x0002_ACTION_HAND + k0x0004_ChampionWoundHead = 0x0004, // @ MASK0x0004_HEAD + k0x0008_ChampionWoundTorso = 0x0008, // @ MASK0x0008_TORSO + k0x0010_ChampionWoundLegs = 0x0010, // @ MASK0x0010_LEGS + k0x0020_ChampionWoundFeet = 0x0020 // @ MASK0x0020_FEET }; enum ChampionStatisticType { - kChampionStatLuck = 0, // @ C0_STATISTIC_LUCK - kChampionStatStrength = 1, // @ C1_STATISTIC_STRENGTH - kChampionStatDexterity = 2, // @ C2_STATISTIC_DEXTERITY - kChampionStatWisdom = 3, // @ C3_STATISTIC_WISDOM - kChampionStatVitality = 4, // @ C4_STATISTIC_VITALITY - kChampionStatAntimagic = 5, // @ C5_STATISTIC_ANTIMAGIC - kChampionStatAntifire = 6, // @ C6_STATISTIC_ANTIFIRE - kChampionStatMana = 8 // @ C8_STATISTIC_MANA /* Used as a fake statistic index for objects granting a Mana bonus */ + k0_ChampionStatLuck = 0, // @ C0_STATISTIC_LUCK + k1_ChampionStatStrength = 1, // @ C1_STATISTIC_STRENGTH + k2_ChampionStatDexterity = 2, // @ C2_STATISTIC_DEXTERITY + k3_ChampionStatWisdom = 3, // @ C3_STATISTIC_WISDOM + k4_ChampionStatVitality = 4, // @ C4_STATISTIC_VITALITY + k5_ChampionStatAntimagic = 5, // @ C5_STATISTIC_ANTIMAGIC + k6_ChampionStatAntifire = 6, // @ C6_STATISTIC_ANTIFIRE + k8_ChampionStatMana = 8 // @ C8_STATISTIC_MANA /* Used as a fake statistic index for objects granting a Mana bonus */ }; enum ChampionStatisticValue { - kChampionStatMaximum = 0, // @ C0_MAXIMUM - kChampionStatCurrent = 1, // @ C1_CURRENT - kChampionStatMinimum = 2 // @ C2_MINIMUM + k0_ChampionStatMaximum = 0, // @ C0_MAXIMUM + k1_ChampionStatCurrent = 1, // @ C1_CURRENT + k2_ChampionStatMinimum = 2 // @ C2_MINIMUM }; enum ChampionSkill { - kChampionSkillFighter = 0, // @ C00_SKILL_FIGHTER - kChampionSkillNinja = 1, // @ C01_SKILL_NINJA - kChampionSkillPriest = 2, // @ C02_SKILL_PRIEST - kChampionSkillWizard = 3, // @ C03_SKILL_WIZARD - kChampionSkillSwing = 4, // @ C04_SKILL_SWING - kChampionSkillThrust = 5, // @ C05_SKILL_THRUST - kChampionSkillClub = 6, // @ C06_SKILL_CLUB - kChampionSkillParry = 7, // @ C07_SKILL_PARRY - kChampionSkillSteal = 8, // @ C08_SKILL_STEAL - kChampionSkillFight = 9, // @ C09_SKILL_FIGHT - kChampionSkillThrow = 10, // @ C10_SKILL_THROW - kChampionSkillShoot = 11, // @ C11_SKILL_SHOOT - kChampionSkillIdentify = 12, // @ C12_SKILL_IDENTIFY - kChampionSkillHeal = 13, // @ C13_SKILL_HEAL - kChampionSkillInfluence = 14, // @ C14_SKILL_INFLUENCE - kChampionSkillDefend = 15, // @ C15_SKILL_DEFEND - kChampionSkillFire = 16, // @ C16_SKILL_FIRE - kChampionSkillAir = 17, // @ C17_SKILL_AIR - kChampionSkillEarth = 18, // @ C18_SKILL_EARTH - kChampionSkillWater = 19 // @ C19_SKILL_WATER + k0_ChampionSkillFighter = 0, // @ C00_SKILL_FIGHTER + k1_ChampionSkillNinja = 1, // @ C01_SKILL_NINJA + k2_ChampionSkillPriest = 2, // @ C02_SKILL_PRIEST + k3_ChampionSkillWizard = 3, // @ C03_SKILL_WIZARD + k4_ChampionSkillSwing = 4, // @ C04_SKILL_SWING + k5_ChampionSkillThrust = 5, // @ C05_SKILL_THRUST + k6_ChampionSkillClub = 6, // @ C06_SKILL_CLUB + k7_ChampionSkillParry = 7, // @ C07_SKILL_PARRY + k8_ChampionSkillSteal = 8, // @ C08_SKILL_STEAL + k9_ChampionSkillFight = 9, // @ C09_SKILL_FIGHT + k10_ChampionSkillThrow = 10, // @ C10_SKILL_THROW + k11_ChampionSkillShoot = 11, // @ C11_SKILL_SHOOT + k12_ChampionSkillIdentify = 12, // @ C12_SKILL_IDENTIFY + k13_ChampionSkillHeal = 13, // @ C13_SKILL_HEAL + k14_ChampionSkillInfluence = 14, // @ C14_SKILL_INFLUENCE + k15_ChampionSkillDefend = 15, // @ C15_SKILL_DEFEND + k16_ChampionSkillFire = 16, // @ C16_SKILL_FIRE + k17_ChampionSkillAir = 17, // @ C17_SKILL_AIR + k18_ChampionSkillEarth = 18, // @ C18_SKILL_EARTH + k19_ChampionSkillWater = 19 // @ C19_SKILL_WATER }; enum ChampionSlot { - kChampionSlotLeaderHand = -1, // @ CM1_SLOT_LEADER_HAND - kChampionSlotReadyHand = 0, // @ C00_SLOT_READY_HAND - kChampionSlotActionHand = 1, // @ C01_SLOT_ACTION_HAND - kChampionSlotHead = 2, // @ C02_SLOT_HEAD - kChampionSlotTorso = 3, // @ C03_SLOT_TORSO - kChampionSlotLegs = 4, // @ C04_SLOT_LEGS - kChampionSlotFeet = 5, // @ C05_SLOT_FEET - kChampionSlotPouch_2 = 6, // @ C06_SLOT_POUCH_2 - kChampionSlotQuiverLine_2_1 = 7, // @ C07_SLOT_QUIVER_LINE2_1 - kChampionSlotQuiverLine_1_2 = 8, // @ C08_SLOT_QUIVER_LINE1_2 - kChampionSlotQuiverLine_2_2 = 9, // @ C09_SLOT_QUIVER_LINE2_2 - kChampionSlotNeck = 10, // @ C10_SLOT_NECK - kChampionSlotPouch_1 = 11, // @ C11_SLOT_POUCH_1 - kChampionSlotQuiverLine_1_1 = 12, // @ C12_SLOT_QUIVER_LINE1_1 - kChampionSlotBackpackLine_1_1 = 13, // @ C13_SLOT_BACKPACK_LINE1_1 - kChampionSlotBackpackLine_2_2 = 14, // @ C14_SLOT_BACKPACK_LINE2_2 - kChampionSlotBackpackLine_2_3 = 15, // @ C15_SLOT_BACKPACK_LINE2_3 - kChampionSlotBackpackLine_2_4 = 16, // @ C16_SLOT_BACKPACK_LINE2_4 - kChampionSlotBackpackLine_2_5 = 17, // @ C17_SLOT_BACKPACK_LINE2_5 - kChampionSlotBackpackLine_2_6 = 18, // @ C18_SLOT_BACKPACK_LINE2_6 - kChampionSlotBackpackLine_2_7 = 19, // @ C19_SLOT_BACKPACK_LINE2_7 - kChampionSlotBackpackLine_2_8 = 20, // @ C20_SLOT_BACKPACK_LINE2_8 - kChampionSlotBackpackLine_2_9 = 21, // @ C21_SLOT_BACKPACK_LINE2_9 - kChampionSlotBackpackLine_1_2 = 22, // @ C22_SLOT_BACKPACK_LINE1_2 - kChampionSlotBackpackLine_1_3 = 23, // @ C23_SLOT_BACKPACK_LINE1_3 - kChampionSlotBackpackLine_1_4 = 24, // @ C24_SLOT_BACKPACK_LINE1_4 - kChampionSlotBackpackLine_1_5 = 25, // @ C25_SLOT_BACKPACK_LINE1_5 - kChampionSlotBackpackLine_1_6 = 26, // @ C26_SLOT_BACKPACK_LINE1_6 - kChampionSlotBackpackLine_1_7 = 27, // @ C27_SLOT_BACKPACK_LINE1_7 - kChampionSlotBackpackLine_1_8 = 28, // @ C28_SLOT_BACKPACK_LINE1_8 - kChampionSlotBackpackLine_1_9 = 29, // @ C29_SLOT_BACKPACK_LINE1_9 - kChampionSlotChest_1 = 30, // @ C30_SLOT_CHEST_1 - kChampionSlotChest_2 = 31, // @ C31_SLOT_CHEST_2 - kChampionSlotChest_3 = 32, // @ C32_SLOT_CHEST_3 - kChampionSlotChest_4 = 33, // @ C33_SLOT_CHEST_4 - kChampionSlotChest_5 = 34, // @ C34_SLOT_CHEST_5 - kChampionSlotChest_6 = 35, // @ C35_SLOT_CHEST_6 - kChampionSlotChest_7 = 36, // @ C36_SLOT_CHEST_7 - kChampionSlotChest_8 = 37 // @ C37_SLOT_CHEST_8 + kM1_ChampionSlotLeaderHand = -1, // @ CM1_SLOT_LEADER_HAND + k0_ChampionSlotReadyHand = 0, // @ C00_SLOT_READY_HAND + k1_ChampionSlotActionHand = 1, // @ C01_SLOT_ACTION_HAND + k2_ChampionSlotHead = 2, // @ C02_SLOT_HEAD + k3_ChampionSlotTorso = 3, // @ C03_SLOT_TORSO + k4_ChampionSlotLegs = 4, // @ C04_SLOT_LEGS + k5_ChampionSlotFeet = 5, // @ C05_SLOT_FEET + k6_ChampionSlotPouch_2 = 6, // @ C06_SLOT_POUCH_2 + k7_ChampionSlotQuiverLine_2_1 = 7, // @ C07_SLOT_QUIVER_LINE2_1 + k8_ChampionSlotQuiverLine_1_2 = 8, // @ C08_SLOT_QUIVER_LINE1_2 + k9_ChampionSlotQuiverLine_2_2 = 9, // @ C09_SLOT_QUIVER_LINE2_2 + k10_ChampionSlotNeck = 10, // @ C10_SLOT_NECK + k11_ChampionSlotPouch_1 = 11, // @ C11_SLOT_POUCH_1 + k12_ChampionSlotQuiverLine_1_1 = 12, // @ C12_SLOT_QUIVER_LINE1_1 + k13_ChampionSlotBackpackLine_1_1 = 13, // @ C13_SLOT_BACKPACK_LINE1_1 + k14_ChampionSlotBackpackLine_2_2 = 14, // @ C14_SLOT_BACKPACK_LINE2_2 + k15_ChampionSlotBackpackLine_2_3 = 15, // @ C15_SLOT_BACKPACK_LINE2_3 + k16_ChampionSlotBackpackLine_2_4 = 16, // @ C16_SLOT_BACKPACK_LINE2_4 + k17_ChampionSlotBackpackLine_2_5 = 17, // @ C17_SLOT_BACKPACK_LINE2_5 + k18_ChampionSlotBackpackLine_2_6 = 18, // @ C18_SLOT_BACKPACK_LINE2_6 + k19_ChampionSlotBackpackLine_2_7 = 19, // @ C19_SLOT_BACKPACK_LINE2_7 + k20_ChampionSlotBackpackLine_2_8 = 20, // @ C20_SLOT_BACKPACK_LINE2_8 + k21_ChampionSlotBackpackLine_2_9 = 21, // @ C21_SLOT_BACKPACK_LINE2_9 + k22_ChampionSlotBackpackLine_1_2 = 22, // @ C22_SLOT_BACKPACK_LINE1_2 + k23_ChampionSlotBackpackLine_1_3 = 23, // @ C23_SLOT_BACKPACK_LINE1_3 + k24_ChampionSlotBackpackLine_1_4 = 24, // @ C24_SLOT_BACKPACK_LINE1_4 + k25_ChampionSlotBackpackLine_1_5 = 25, // @ C25_SLOT_BACKPACK_LINE1_5 + k26_ChampionSlotBackpackLine_1_6 = 26, // @ C26_SLOT_BACKPACK_LINE1_6 + k27_ChampionSlotBackpackLine_1_7 = 27, // @ C27_SLOT_BACKPACK_LINE1_7 + k28_ChampionSlotBackpackLine_1_8 = 28, // @ C28_SLOT_BACKPACK_LINE1_8 + k29_ChampionSlotBackpackLine_1_9 = 29, // @ C29_SLOT_BACKPACK_LINE1_9 + k30_ChampionSlotChest_1 = 30, // @ C30_SLOT_CHEST_1 + k31_ChampionSlotChest_2 = 31, // @ C31_SLOT_CHEST_2 + k32_ChampionSlotChest_3 = 32, // @ C32_SLOT_CHEST_3 + k33_ChampionSlotChest_4 = 33, // @ C33_SLOT_CHEST_4 + k34_ChampionSlotChest_5 = 34, // @ C34_SLOT_CHEST_5 + k35_ChampionSlotChest_6 = 35, // @ C35_SLOT_CHEST_6 + k36_ChampionSlotChest_7 = 36, // @ C36_SLOT_CHEST_7 + k37_ChampionSlotChest_8 = 37 // @ C37_SLOT_CHEST_8 }; enum ChampionAction { - kChampionActionN = 0, // @ C000_ACTION_N - kChampionActionBlock = 1, // @ C001_ACTION_BLOCK - kChampionActionChop = 2, // @ C002_ACTION_CHOP - kChampionActionX_C003 = 3, // @ C003_ACTION_X - kChampionActionBlowHorn = 4, // @ C004_ACTION_BLOW_HORN - kChampionActionFlip = 5, // @ C005_ACTION_FLIP - kChampionActionPunch = 6, // @ C006_ACTION_PUNCH - kChampionActionKick = 7, // @ C007_ACTION_KICK - kChampionActionWarCry = 8, // @ C008_ACTION_WAR_CRY - kChampionActionStab_C009 = 9, // @ C009_ACTION_STAB - kChampionActionClimbDown = 10, // @ C010_ACTION_CLIMB_DOWN - kChampionActionFreezeLife = 11, // @ C011_ACTION_FREEZE_LIFE - kChampionActionHit = 12, // @ C012_ACTION_HIT - kChampionActionSwing = 13, // @ C013_ACTION_SWING - kChampionActionStab_C014 = 14, // @ C014_ACTION_STAB - kChampionActionThrust = 15, // @ C015_ACTION_THRUST - kChampionActionJab = 16, // @ C016_ACTION_JAB - kChampionActionParry = 17, // @ C017_ACTION_PARRY - kChampionActionHack = 18, // @ C018_ACTION_HACK - kChampionActionBerzerk = 19, // @ C019_ACTION_BERZERK - kChampionActionFireball = 20, // @ C020_ACTION_FIREBALL - kChampionActionDispel = 21, // @ C021_ACTION_DISPELL - kChampionActionConfuse = 22, // @ C022_ACTION_CONFUSE - kChampionActionLightning = 23, // @ C023_ACTION_LIGHTNING - kChampionActionDisrupt = 24, // @ C024_ACTION_DISRUPT - kChampionActionMelee = 25, // @ C025_ACTION_MELEE - kChampionActionX_C026 = 26, // @ C026_ACTION_X - kChampionActionInvoke = 27, // @ C027_ACTION_INVOKE - kChampionActionSlash = 28, // @ C028_ACTION_SLASH - kChampionActionCleave = 29, // @ C029_ACTION_CLEAVE - kChampionActionBash = 30, // @ C030_ACTION_BASH - kChampionActionStun = 31, // @ C031_ACTION_STUN - kChampionActionShoot = 32, // @ C032_ACTION_SHOOT - kChampionActionSpellshield = 33, // @ C033_ACTION_SPELLSHIELD - kChampionActionFireshield = 34, // @ C034_ACTION_FIRESHIELD - kChampionActionFluxcage = 35, // @ C035_ACTION_FLUXCAGE - kChampionActionHeal = 36, // @ C036_ACTION_HEAL - kChampionActionCalm = 37, // @ C037_ACTION_CALM - kChampionActionLight = 38, // @ C038_ACTION_LIGHT - kChampionActionWindow = 39, // @ C039_ACTION_WINDOW - kChampionActionSpit = 40, // @ C040_ACTION_SPIT - kChampionActionBrandish = 41, // @ C041_ACTION_BRANDISH - kChampionActionThrow = 42, // @ C042_ACTION_THROW - kChampionActionFuse = 43, // @ C043_ACTION_FUSE - kChampionActionNone = 255 // @ C255_ACTION_NONE + k0_ChampionActionN = 0, // @ C000_ACTION_N + k1_ChampionActionBlock = 1, // @ C001_ACTION_BLOCK + k2_ChampionActionChop = 2, // @ C002_ACTION_CHOP + k3_ChampionActionX_C003 = 3, // @ C003_ACTION_X + k4_ChampionActionBlowHorn = 4, // @ C004_ACTION_BLOW_HORN + k5_ChampionActionFlip = 5, // @ C005_ACTION_FLIP + k6_ChampionActionPunch = 6, // @ C006_ACTION_PUNCH + k7_ChampionActionKick = 7, // @ C007_ACTION_KICK + k8_ChampionActionWarCry = 8, // @ C008_ACTION_WAR_CRY + k9_ChampionActionStab_C009 = 9, // @ C009_ACTION_STAB + k10_ChampionActionClimbDown = 10, // @ C010_ACTION_CLIMB_DOWN + k11_ChampionActionFreezeLife = 11, // @ C011_ACTION_FREEZE_LIFE + k12_ChampionActionHit = 12, // @ C012_ACTION_HIT + k13_ChampionActionSwing = 13, // @ C013_ACTION_SWING + k14_ChampionActionStab_C014 = 14, // @ C014_ACTION_STAB + k15_ChampionActionThrust = 15, // @ C015_ACTION_THRUST + k16_ChampionActionJab = 16, // @ C016_ACTION_JAB + k17_ChampionActionParry = 17, // @ C017_ACTION_PARRY + k18_ChampionActionHack = 18, // @ C018_ACTION_HACK + k19_ChampionActionBerzerk = 19, // @ C019_ACTION_BERZERK + k20_ChampionActionFireball = 20, // @ C020_ACTION_FIREBALL + k21_ChampionActionDispel = 21, // @ C021_ACTION_DISPELL + k22_ChampionActionConfuse = 22, // @ C022_ACTION_CONFUSE + k23_ChampionActionLightning = 23, // @ C023_ACTION_LIGHTNING + k24_ChampionActionDisrupt = 24, // @ C024_ACTION_DISRUPT + k25_ChampionActionMelee = 25, // @ C025_ACTION_MELEE + k26_ChampionActionX_C026 = 26, // @ C026_ACTION_X + k27_ChampionActionInvoke = 27, // @ C027_ACTION_INVOKE + k28_ChampionActionSlash = 28, // @ C028_ACTION_SLASH + k29_ChampionActionCleave = 29, // @ C029_ACTION_CLEAVE + k30_ChampionActionBash = 30, // @ C030_ACTION_BASH + k31_ChampionActionStun = 31, // @ C031_ACTION_STUN + k32_ChampionActionShoot = 32, // @ C032_ACTION_SHOOT + k33_ChampionActionSpellshield = 33, // @ C033_ACTION_SPELLSHIELD + k34_ChampionActionFireshield = 34, // @ C034_ACTION_FIRESHIELD + k35_ChampionActionFluxcage = 35, // @ C035_ACTION_FLUXCAGE + k36_ChampionActionHeal = 36, // @ C036_ACTION_HEAL + k37_ChampionActionCalm = 37, // @ C037_ACTION_CALM + k38_ChampionActionLight = 38, // @ C038_ACTION_LIGHT + k39_ChampionActionWindow = 39, // @ C039_ACTION_WINDOW + k40_ChampionActionSpit = 40, // @ C040_ACTION_SPIT + k41_ChampionActionBrandish = 41, // @ C041_ACTION_BRANDISH + k42_ChampionActionThrow = 42, // @ C042_ACTION_THROW + k43_ChampionActionFuse = 43, // @ C043_ACTION_FUSE + k255_ChampionActionNone = 255 // @ C255_ACTION_NONE }; @@ -386,7 +386,7 @@ public: _attributes &= ~flag; } } - void clearAttributes(ChampionAttribute attribute = kChampionAttributNone) { _attributes = attribute; } + void clearAttributes(ChampionAttribute attribute = k0x0000_ChampionAttributNone) { _attributes = attribute; } uint16 getWounds() { return _wounds; } void setWoundsFlag(ChampionWound flag, bool value) { @@ -397,7 +397,7 @@ public: } } uint16 getWoundsFlag(ChampionWound wound) { return _wounds & wound; } - void clearWounds() { _wounds = kChampionWoundNone; } + void clearWounds() { _wounds = k0x0000_ChampionWoundNone; } void resetToZero() { // oh boy > . < for (int16 i = 0; i < 30; ++i) _slots[i] = Thing::_none; @@ -409,7 +409,7 @@ public: memset(_title, '\0', 20); _dir = kDirNorth; _cell = k0_ViewCellFronLeft; - _actionIndex = kChampionActionN; + _actionIndex = k0_ChampionActionN; _symbolStep = 0; memset(_symbols, '\0', 5); _directionMaximumDamageReceived = _maximumDamageReceived = _poisonEventCount = _enableActionEventIndex = 0; @@ -435,18 +435,18 @@ class ChampionMan { uint16 handSlotIndex(uint16 slotBoxIndex);// @ M70_HAND_SLOT_INDEX public: Champion _champions[4]; - uint16 _partyChampionCount; // @ G0305_ui_PartyChampionCount - bool _partyDead; // @ G0303_B_PartyDead - Thing _leaderHandObject; // @ G0414_T_LeaderHandObject - ChampionIndex _leaderIndex; // @ G0411_i_LeaderIndex - uint16 _candidateChampionOrdinal; // @ G0299_ui_CandidateChampionOrdinal - bool _partyIsSleeping; // @ G0300_B_PartyIsSleeping - uint16 _actingChampionOrdinal; // @ G0506_ui_ActingChampionOrdinal - IconIndice _leaderHandObjectIconIndex; // @ G0413_i_LeaderHandObjectIconIndex - bool _leaderEmptyHanded; // @ G0415_B_LeaderEmptyHanded - Party _party; // @ G0407_s_Party - ChampionIndex _magicCasterChampionIndex; // @ G0514_i_MagicCasterChampionIndex - bool _mousePointerHiddenToDrawChangedObjIconOnScreen; // @ G0420_B_MousePointerHiddenToDrawChangedObjectIconOnScreen + uint16 _g305_partyChampionCount; // @ G0305_ui_PartyChampionCount + bool _303_partyDead; // @ G0303_B_PartyDead + Thing _414_leaderHandObject; // @ G0414_T_LeaderHandObject + ChampionIndex _g411_leaderIndex; // @ G0411_i_LeaderIndex + uint16 _g299_candidateChampionOrdinal; // @ G0299_ui_CandidateChampionOrdinal + bool _g300_partyIsSleeping; // @ G0300_B_PartyIsSleeping + uint16 _g506_actingChampionOrdinal; // @ G0506_ui_ActingChampionOrdinal + IconIndice _g413_leaderHandObjectIconIndex; // @ G0413_i_LeaderHandObjectIconIndex + bool _g415_leaderEmptyHanded; // @ G0415_B_LeaderEmptyHanded + Party _g407_party; // @ G0407_s_Party + ChampionIndex _g514_magicCasterChampionIndex; // @ G0514_i_MagicCasterChampionIndex + bool _g420_mousePointerHiddenToDrawChangedObjIconOnScreen; // @ G0420_B_MousePointerHiddenToDrawChangedObjectIconOnScreen explicit ChampionMan(DMEngine *vm); void resetDataToStartGame(); // @ F0278_CHAMPION_ResetDataToStartGame diff --git a/engines/dm/dm.cpp b/engines/dm/dm.cpp index bf584fd6fe..adc842b0ab 100644 --- a/engines/dm/dm.cpp +++ b/engines/dm/dm.cpp @@ -170,10 +170,10 @@ void DMEngine::startGame() { _stopPressingMouth = false; _highlightBoxInversionRequested = false; _eventMan->_highlightBoxEnabled = false; - _championMan->_partyIsSleeping = false; - _championMan->_actingChampionOrdinal = indexToOrdinal(kChampionNone); + _championMan->_g300_partyIsSleeping = false; + _championMan->_g506_actingChampionOrdinal = indexToOrdinal(kM1_ChampionNone); _menuMan->_actionAreaContainsIcons = true; - _eventMan->_useChampionIconOrdinalAsMousePointerBitmap = indexToOrdinal(kChampionNone); + _eventMan->_useChampionIconOrdinalAsMousePointerBitmap = indexToOrdinal(kM1_ChampionNone); _eventMan->_primaryMouseInput = gPrimaryMouseInput_Interface; _eventMan->_secondaryMouseInput = gSecondaryMouseInput_Movement; @@ -251,7 +251,7 @@ void DMEngine::gameloop() { _eventMan->processCommandQueue(); //} while (!_stopWaitingForPlayerInput || !_gameTimeTicking); - if (!_inventoryMan->_inventoryChampionOrdinal && !_championMan->_partyIsSleeping) { + if (!_inventoryMan->_inventoryChampionOrdinal && !_championMan->_g300_partyIsSleeping) { Box box(0, 224, 0, 126); _displayMan->clearScreenBox(k0_ColorBlack, box, g296_DungeonViewport); // dummy code _displayMan->drawDungeon(_dungeonMan->_currMap._partyDir, _dungeonMan->_currMap._partyPosX, _dungeonMan->_currMap._partyPosY); diff --git a/engines/dm/eventman.cpp b/engines/dm/eventman.cpp index 1adb396ab9..82fd07caac 100644 --- a/engines/dm/eventman.cpp +++ b/engines/dm/eventman.cpp @@ -479,28 +479,28 @@ void EventManager::commandSetLeader(ChampionIndex champIndex) { ChampionMan &cm = *_vm->_championMan; ChampionIndex leaderIndex; - if ((cm._leaderIndex == champIndex) || ((champIndex != kChampionNone) && !cm._champions[champIndex]._currHealth)) + if ((cm._g411_leaderIndex == champIndex) || ((champIndex != kM1_ChampionNone) && !cm._champions[champIndex]._currHealth)) return; - if (cm._leaderIndex != kChampionNone) { - leaderIndex = cm._leaderIndex; - cm._champions[leaderIndex].setAttributeFlag(kChampionAttributeLoad, true); - cm._champions[leaderIndex].setAttributeFlag(kChampionAttributeNameTitle, true); - cm._champions[leaderIndex]._load -= _vm->_dungeonMan->getObjectWeight(cm._leaderHandObject); - cm._leaderIndex = kChampionNone; + if (cm._g411_leaderIndex != kM1_ChampionNone) { + leaderIndex = cm._g411_leaderIndex; + cm._champions[leaderIndex].setAttributeFlag(k0x0200_ChampionAttributeLoad, true); + cm._champions[leaderIndex].setAttributeFlag(k0x0080_ChampionAttributeNameTitle, true); + cm._champions[leaderIndex]._load -= _vm->_dungeonMan->getObjectWeight(cm._414_leaderHandObject); + cm._g411_leaderIndex = kM1_ChampionNone; cm.drawChampionState(leaderIndex); } - if (champIndex == kChampionNone) { - cm._leaderIndex = kChampionNone; + if (champIndex == kM1_ChampionNone) { + cm._g411_leaderIndex = kM1_ChampionNone; return; } - cm._leaderIndex = champIndex; - Champion *champion = &cm._champions[cm._leaderIndex]; + cm._g411_leaderIndex = champIndex; + Champion *champion = &cm._champions[cm._g411_leaderIndex]; champion->_dir = _vm->_dungeonMan->_currMap._partyDir; - cm._champions[champIndex]._load += _vm->_dungeonMan->getObjectWeight(cm._leaderHandObject); - if (_vm->indexToOrdinal(champIndex) != cm._candidateChampionOrdinal) { - champion->setAttributeFlag(kChampionAttributeIcon, true); - champion->setAttributeFlag(kChampionAttributeNameTitle, true); + cm._champions[champIndex]._load += _vm->_dungeonMan->getObjectWeight(cm._414_leaderHandObject); + if (_vm->indexToOrdinal(champIndex) != cm._g299_candidateChampionOrdinal) { + champion->setAttributeFlag(k0x0400_ChampionAttributeIcon, true); + champion->setAttributeFlag(k0x0080_ChampionAttributeNameTitle, true); cm.drawChampionState(champIndex); } } @@ -521,10 +521,10 @@ void EventManager::commandProcessType80ClickInDungeonView(int16 posX, int16 posY CurrMapData &currMap = _vm->_dungeonMan->_currMap; if (dunMan._squareAheadElement == kElementTypeDoorFront) { - if (champMan._leaderIndex == kChampionNone) + if (champMan._g411_leaderIndex == kM1_ChampionNone) return; - if (champMan._leaderEmptyHanded) { + if (champMan._g415_leaderEmptyHanded) { int16 mapX = currMap._partyPosX + _vm->_dirIntoStepCountEast[currMap._partyDir]; int16 mapY = currMap._partyPosY + _vm->_dirIntoStepCountNorth[currMap._partyDir]; @@ -540,7 +540,7 @@ void EventManager::commandProcessType80ClickInDungeonView(int16 posX, int16 posY } } - if (champMan._leaderEmptyHanded) { + if (champMan._g415_leaderEmptyHanded) { for (int16 viewCell = k0_ViewCellFronLeft; viewCell <= k5_ViewCellDoorButtonOrWallOrn; viewCell++) { if (dunMan._dungeonViewClickableBoxes[viewCell].isPointInside(Common::Point(posX, posY - 33))) { if (viewCell == k5_ViewCellDoorButtonOrWallOrn) { @@ -554,7 +554,7 @@ void EventManager::commandProcessType80ClickInDungeonView(int16 posX, int16 posY } } } else { - Thing thing = champMan._leaderHandObject; + Thing thing = champMan._414_leaderHandObject; uint16 *rawThingPointer = dunMan.getThingData(thing); if (dunMan._squareAheadElement == kElementTypeWall) { for (int16 viewCell = k0_ViewCellFronLeft; viewCell <= k1_ViewCellFrontRight; ++viewCell) { @@ -571,15 +571,15 @@ void EventManager::commandProcessType80ClickInDungeonView(int16 posX, int16 posY if (dunMan._isFacingFountain) { uint16 iconIndex = _vm->_objectMan->getIconIndex(thing); int16 weight = dunMan.getObjectWeight(thing); - if ((iconIndex >= kIconIndiceJunkWater) && (iconIndex <= kIconIndiceJunkWaterSkin)) { + if ((iconIndex >= k8_IconIndiceJunkWater) && (iconIndex <= k9_IconIndiceJunkWaterSkin)) { ((Junk*)rawThingPointer)->setChargeCount(3); - } else if (iconIndex == kIconIndicePotionEmptyFlask) { + } else if (iconIndex == k195_IconIndicePotionEmptyFlask) { ((Potion*)rawThingPointer)->setType(kPotionTypeWaterFlask); } else { goto T0377019; } champMan.drawChangedObjectIcons(); - champMan._champions[champMan._leaderIndex]._load += dunMan.getObjectWeight(thing) - weight; + champMan._champions[champMan._g411_leaderIndex]._load += dunMan.getObjectWeight(thing) - weight; } T0377019: commandProcessType80ClickInDungeonViewTouchFrontWall(); @@ -604,15 +604,15 @@ void EventManager::commandProcessCommands160To162ClickInResurrectReincarnatePane CurrMapData &currMap = _vm->_dungeonMan->_currMap; DungeonMan &dunMan = *_vm->_dungeonMan; - uint16 championIndex = champMan._partyChampionCount - 1; + uint16 championIndex = champMan._g305_partyChampionCount - 1; Champion *champ = &champMan._champions[championIndex]; if (commandType == kCommandClickInPanelCancel) { - invMan.toggleInventory(kChampionCloseInventory); - champMan._candidateChampionOrdinal = _vm->indexToOrdinal(kChampionNone); - if (champMan._partyChampionCount == 1) { - commandSetLeader(kChampionNone); + invMan.toggleInventory(k4_ChampionCloseInventory); + champMan._g299_candidateChampionOrdinal = _vm->indexToOrdinal(kM1_ChampionNone); + if (champMan._g305_partyChampionCount == 1) { + commandSetLeader(kM1_ChampionNone); } - champMan._partyChampionCount--; + champMan._g305_partyChampionCount--; Box box; box._y1 = 0; box._y2 = 28 + 1; @@ -620,17 +620,17 @@ void EventManager::commandProcessCommands160To162ClickInResurrectReincarnatePane box._x2 = box._x1 + 66 + 1; dispMan._g578_useByteBoxCoordinates = false; dispMan.clearScreenBox(k0_ColorBlack, box); - dispMan.clearScreenBox(k0_ColorBlack, gBoxChampionIcons[champMan.championIconIndex(champ->_cell, currMap._partyDir) * 2]); + dispMan.clearScreenBox(k0_ColorBlack, g54_BoxChampionIcons[champMan.championIconIndex(champ->_cell, currMap._partyDir) * 2]); warning("F0457_START_DrawEnabledMenus_CPSF"); warning("F0078_MOUSE_ShowPointer"); return; } - champMan._candidateChampionOrdinal = _vm->indexToOrdinal(kChampionNone); + champMan._g299_candidateChampionOrdinal = _vm->indexToOrdinal(kM1_ChampionNone); int16 mapX = currMap._partyPosX + _vm->_dirIntoStepCountEast[currMap._partyDir]; int16 mapY = currMap._partyPosY + _vm->_dirIntoStepCountNorth[currMap._partyDir]; - for (uint16 slotIndex = kChampionSlotReadyHand; slotIndex < kChampionSlotChest_1; slotIndex++) { + for (uint16 slotIndex = k0_ChampionSlotReadyHand; slotIndex < k30_ChampionSlotChest_1; slotIndex++) { Thing thing = champ->getSlot((ChampionSlot)slotIndex); if (thing != Thing::_none) { warning("MISSING CODE: F0164_DUNGEON_UnlinkThingFromList"); @@ -651,25 +651,25 @@ void EventManager::commandProcessCommands160To162ClickInResurrectReincarnatePane for (uint16 i = 0; i < 12; i++) { uint16 statIndex = _vm->_rnd->getRandomNumber(7); - champ->getStatistic((ChampionStatisticType)statIndex, kChampionStatCurrent)++; // returns reference - champ->getStatistic((ChampionStatisticType)statIndex, kChampionStatMaximum)++; // returns reference + champ->getStatistic((ChampionStatisticType)statIndex, k1_ChampionStatCurrent)++; // returns reference + champ->getStatistic((ChampionStatisticType)statIndex, k0_ChampionStatMaximum)++; // returns reference } } - if (champMan._partyChampionCount == 1) { + if (champMan._g305_partyChampionCount == 1) { warning("MISSING CODE: setting time, G0362_l_LastPartyMovementTime , G0313_ul_GameTime"); - commandSetLeader(kChampionFirst); - _vm->_menuMan->setMagicCasterAndDrawSpellArea(kChampionFirst); + commandSetLeader(k0_ChampionFirst); + _vm->_menuMan->setMagicCasterAndDrawSpellArea(k0_ChampionFirst); } else { - _vm->_menuMan->drawSpellAreaControls(champMan._magicCasterChampionIndex); + _vm->_menuMan->drawSpellAreaControls(champMan._g514_magicCasterChampionIndex); } warning("MISSING CODE: F0051_TEXT_MESSAGEAREA_PrintLineFeed"); - Color champColor = gChampionColor[championIndex]; // unreferenced because of missing code + Color champColor = g46_ChampionColor[championIndex]; // unreferenced because of missing code warning("MISSING CODE: F0047_TEXT_MESSAGEAREA_PrintMessage"); warning("MISSING CODE: F0047_TEXT_MESSAGEAREA_PrintMessage"); - invMan.toggleInventory(kChampionCloseInventory); + invMan.toggleInventory(k4_ChampionCloseInventory); warning("MISSING CODE: F0457_START_DrawEnabledMenus_CPSF"); warning("MISSING CODE: F0067_MOUSE_SetPointerToNormal"); } @@ -681,14 +681,14 @@ void EventManager::commandProcess81ClickInPanel(int16 x, int16 y) { CommandType commandType; switch (invMan._panelContent) { case kPanelContentChest: - if (champMan._leaderIndex == kChampionNone) // if no leader + if (champMan._g411_leaderIndex == kM1_ChampionNone) // if no leader return; commandType = getCommandTypeFromMouseInput(gMouseInput_PanelChest, Common::Point(x, y), kLeftMouseButton); if (commandType != kCommandNone) warning("MISSING CODE: F0302_CHAMPION_ProcessCommands28To65_ClickOnSlotBox"); break; case kPanelContentResurrectReincarnate: - if (!champMan._leaderEmptyHanded) + if (!champMan._g415_leaderEmptyHanded) break; commandType = getCommandTypeFromMouseInput(gMouseInput_PanelResurrectReincarnateCancel, Common::Point(x, y), kLeftMouseButton); if (commandType != kCommandNone) diff --git a/engines/dm/inventory.cpp b/engines/dm/inventory.cpp index 11ccd944d5..0779a7ee0f 100644 --- a/engines/dm/inventory.cpp +++ b/engines/dm/inventory.cpp @@ -55,29 +55,29 @@ void InventoryMan::toggleInventory(ChampionIndex championIndex) { EventManager &em = *_vm->_eventMan; DisplayMan &dm = *_vm->_displayMan; - if ((championIndex != kChampionCloseInventory) && !cm._champions[championIndex]._currHealth) + if ((championIndex != k4_ChampionCloseInventory) && !cm._champions[championIndex]._currHealth) return; if (_vm->_pressingEye || _vm->_pressingMouth) return; _vm->_stopWaitingForPlayerInput = true; int16 invChampOrdinal = _inventoryChampionOrdinal; // copy, as the original will be edited if (_vm->indexToOrdinal(championIndex) == invChampOrdinal) { - championIndex = kChampionCloseInventory; + championIndex = k4_ChampionCloseInventory; } Champion *champion; if (invChampOrdinal) { - _inventoryChampionOrdinal = _vm->indexToOrdinal(kChampionNone); + _inventoryChampionOrdinal = _vm->indexToOrdinal(kM1_ChampionNone); closeChest(); champion = &cm._champions[_vm->ordinalToIndex(invChampOrdinal)]; - if (champion->_currHealth && !cm._candidateChampionOrdinal) { - champion->setAttributeFlag(kChampionAttributeStatusBox, true); + if (champion->_currHealth && !cm._g299_candidateChampionOrdinal) { + champion->setAttributeFlag(k0x1000_ChampionAttributeStatusBox, true); cm.drawChampionState((ChampionIndex)_vm->ordinalToIndex(invChampOrdinal)); } - if (cm._partyIsSleeping) { + if (cm._g300_partyIsSleeping) { return; } - if (championIndex == kChampionCloseInventory) { + if (championIndex == k4_ChampionCloseInventory) { em._refreshMousePointerInMainLoop = true; _vm->_menuMan->drawMovementArrows(); em._secondaryMouseInput = gSecondaryMouseInput_Movement; @@ -97,23 +97,23 @@ void InventoryMan::toggleInventory(ChampionIndex championIndex) { int16 w = dm.getWidth(k17_InventoryGraphicIndice); int16 h = dm.getHeight(k17_InventoryGraphicIndice); dm.blitToScreen(dm.getBitmap(k17_InventoryGraphicIndice), w, 0, 0, 0, w, 0, h, k255_ColorNoTransparency, g296_DungeonViewport); - if (cm._candidateChampionOrdinal) { + if (cm._g299_candidateChampionOrdinal) { dm.clearScreenBox(k12_ColorDarkestGray, gBoxFloppyZzzCross, g296_DungeonViewport); } _vm->_textMan->printToViewport(5, 116, k13_ColorLightestGray, "HEALTH"); _vm->_textMan->printToViewport(5, 124, k13_ColorLightestGray, "STAMINA"); _vm->_textMan->printToViewport(5, 132, k13_ColorLightestGray, "MANA"); - for (uint16 slotIndex = kChampionSlotReadyHand; slotIndex < kChampionSlotChest_1; slotIndex++) { + for (uint16 slotIndex = k0_ChampionSlotReadyHand; slotIndex < k30_ChampionSlotChest_1; slotIndex++) { _vm->_championMan->drawSlot(championIndex, (ChampionSlot)slotIndex); } - champion->setAttributeFlag(kChampionAttributeViewport, true); - champion->setAttributeFlag(kChampionAttributeStatusBox, true); - champion->setAttributeFlag(kChampionAttributePanel, true); - champion->setAttributeFlag(kChampionAttributeLoad, true); - champion->setAttributeFlag(kChampionAttributeStatistics, true); - champion->setAttributeFlag(kChampionAttributeNameTitle, true); + champion->setAttributeFlag(k0x4000_ChampionAttributeViewport, true); + champion->setAttributeFlag(k0x1000_ChampionAttributeStatusBox, true); + champion->setAttributeFlag(k0x0800_ChampionAttributePanel, true); + champion->setAttributeFlag(k0x0200_ChampionAttributeLoad, true); + champion->setAttributeFlag(k0x0100_ChampionAttributeStatistics, true); + champion->setAttributeFlag(k0x0080_ChampionAttributeNameTitle, true); cm.drawChampionState(championIndex); em._mousePointerBitmapUpdated = true; @@ -183,12 +183,12 @@ void InventoryMan::drawPanel() { closeChest(); // possibility of BUG0_48 ChampionMan &cm = *_vm->_championMan; - if (cm._candidateChampionOrdinal) { + if (cm._g299_candidateChampionOrdinal) { drawPanelResurrectReincarnate(); return; } - Thing thing = cm._champions[_vm->ordinalToIndex(_inventoryChampionOrdinal)].getSlot(kChampionSlotActionHand); + Thing thing = cm._champions[_vm->ordinalToIndex(_inventoryChampionOrdinal)].getSlot(k1_ChampionSlotActionHand); _panelContent = kPanelContentFoodWaterPoisoned; switch (thing.getType()) { @@ -308,7 +308,7 @@ void InventoryMan::openAndDrawChest(Thing thingToOpen, Container* chest, bool is _openChest = thingToOpen; if (!isPressingEye) { - objMan.drawIconInSlotBox(kSlotBoxInventoryActionHand, kIconIndiceContainerChestOpen); + objMan.drawIconInSlotBox(kSlotBoxInventoryActionHand, k145_IconIndiceContainerChestOpen); } dispMan.blitToScreen(dispMan.getBitmap(k25_PanelOpenChestIndice), 144, 0, 0, gBoxPanel, k8_ColorRed); @@ -325,7 +325,7 @@ void InventoryMan::openAndDrawChest(Thing thingToOpen, Container* chest, bool is thing = _vm->_dungeonMan->getNextThing(thing); } while (chestSlotIndex < 8) { - objMan.drawIconInSlotBox(chestSlotIndex + kSlotBoxChestFirstSlot, kIconIndiceNone); + objMan.drawIconInSlotBox(chestSlotIndex + kSlotBoxChestFirstSlot, kM1_IconIndiceNone); _chestSlots[chestSlotIndex++] = Thing::_none; } } @@ -448,15 +448,15 @@ void InventoryMan::drawPanelObject(Thing thingToDraw, bool pressingEye) { char *descString = nullptr; char str[40]; - if (iconIndex == kIconIndiceJunkChampionBones) { + if (iconIndex == k147_IconIndiceJunkChampionBones) { strcpy(str, champMan._champions[((Junk*)rawThingPtr)->getChargeCount()]._name); // TODO: localization strcat(str, " "); // TODO: localization strcat(str, objMan._objectNames[iconIndex]); // TODO: localization descString = str; } else if ((thingType == kPotionThingType) - && (iconIndex != kIconIndicePotionWaterFlask) - && (champMan.getSkillLevel((ChampionIndex)_vm->ordinalToIndex(_inventoryChampionOrdinal), kChampionSkillPriest) > 1)) { + && (iconIndex != k163_IconIndicePotionWaterFlask) + && (champMan.getSkillLevel((ChampionIndex)_vm->ordinalToIndex(_inventoryChampionOrdinal), k2_ChampionSkillPriest) > 1)) { str[0] = '_' + ((Potion*)rawThingPtr)->getPower() / 40; str[1] = ' '; str[2] = '\0'; @@ -480,8 +480,8 @@ void InventoryMan::drawPanelObject(Thing thingToDraw, bool pressingEye) { potentialAttribMask = kDescriptionMaskCursed | kDescriptionMaskPoisoned | kDescriptionMaskBroken; Weapon *weapon = (Weapon*)rawThingPtr; actualAttribMask = (weapon->getCursed() << 3) | (weapon->getPoisoned() << 1) | (weapon->getBroken() << 2); - if ((iconIndex >= kIconIndiceWeaponTorchUnlit) - && (iconIndex <= kIconIndiceWeaponTorchLit) + if ((iconIndex >= k4_IconIndiceWeaponTorchUnlit) + && (iconIndex <= k7_IconIndiceWeaponTorchLit) && (weapon->getChargeCount() == 0)) { drawPanelObjectDescriptionString("(BURNT OUT)"); // TODO: localization } @@ -501,7 +501,7 @@ void InventoryMan::drawPanelObject(Thing thingToDraw, bool pressingEye) { } case kJunkThingType: { Junk *junk = (Junk*)rawThingPtr; - if ((iconIndex >= kIconIndiceJunkWater) && (iconIndex <= kIconIndiceJunkWaterSkin)) { + if ((iconIndex >= k8_IconIndiceJunkWater) && (iconIndex <= k9_IconIndiceJunkWaterSkin)) { potentialAttribMask = 0; switch (junk->getChargeCount()) { case 0: @@ -518,7 +518,7 @@ void InventoryMan::drawPanelObject(Thing thingToDraw, bool pressingEye) { break; } drawPanelObjectDescriptionString(descString); - } else if ((iconIndex >= kIconIndiceJunkCompassNorth) && (iconIndex <= kIconIndiceJunkCompassWest)) { + } else if ((iconIndex >= k0_IconIndiceJunkCompassNorth) && (iconIndex <= k3_IconIndiceJunkCompassWest)) { potentialAttribMask = 0; strcpy(str, "PARTY FACING "); // TODO: localization static char* directionName[4] = {"NORTH", "EAST", "SOUTH", "WEST"}; // G0430_apc_DirectionNames // TODO: localization diff --git a/engines/dm/loadsave.cpp b/engines/dm/loadsave.cpp index 463e02dade..42f8bad5e0 100644 --- a/engines/dm/loadsave.cpp +++ b/engines/dm/loadsave.cpp @@ -44,8 +44,8 @@ LoadgameResponse LoadsaveMan::loadgame() { if (newGame) { _vm->_restartGameAllowed = false; - cm._partyChampionCount = 0; - cm._leaderHandObject = Thing::_none; + cm._g305_partyChampionCount = 0; + cm._414_leaderHandObject = Thing::_none; _vm->_gameId = _vm->_rnd->getRandomNumber(65536) * _vm->_rnd->getRandomNumber(65536); } else { assert(false); @@ -61,7 +61,7 @@ LoadgameResponse LoadsaveMan::loadgame() { assert(false); // MISSING CODE: load game } - cm._partyDead = false; + cm._303_partyDead = false; return kLoadgameSuccess; } diff --git a/engines/dm/menus.cpp b/engines/dm/menus.cpp index 74ca0ac00c..19912adc0a 100644 --- a/engines/dm/menus.cpp +++ b/engines/dm/menus.cpp @@ -68,11 +68,11 @@ void MenuMan::drawMovementArrows() { }
void MenuMan::clearActingChampion() {
ChampionMan &cm = *_vm->_championMan;
- if (cm._actingChampionOrdinal) {
- cm._actingChampionOrdinal--;
- cm._champions[cm._actingChampionOrdinal].setAttributeFlag(kChampionAttributeActionHand, true);
- cm.drawChampionState((ChampionIndex)cm._actingChampionOrdinal);
- cm._actingChampionOrdinal = _vm->indexToOrdinal(kChampionNone);
+ if (cm._g506_actingChampionOrdinal) {
+ cm._g506_actingChampionOrdinal--;
+ cm._champions[cm._g506_actingChampionOrdinal].setAttributeFlag(k0x8000_ChampionAttributeActionHand, true);
+ cm.drawChampionState((ChampionIndex)cm._g506_actingChampionOrdinal);
+ cm._g506_actingChampionOrdinal = _vm->indexToOrdinal(kM1_ChampionNone);
_refreshActionArea = true;
}
}
@@ -94,10 +94,10 @@ void MenuMan::drawActionIcon(ChampionIndex championIndex) { return;
}
byte *bitmapIcon = dm._g74_tmpBitmap;
- Thing thing = champion.getSlot(kChampionSlotActionHand);
+ Thing thing = champion.getSlot(k1_ChampionSlotActionHand);
IconIndice iconIndex;
if (thing == Thing::_none) {
- iconIndex = kIconIndiceActionEmptyHand;
+ iconIndex = k201_IconIndiceActionEmptyHand;
} else if (gObjectInfo[_vm->_dungeonMan->getObjectInfoIndex(thing)]._actionSetIndex) {
iconIndex = _vm->_objectMan->getIconIndex(thing);
} else {
@@ -114,13 +114,13 @@ T0386006: box2._y1 = 95;
box2._y2 = 110 + 1;
dm.blitToScreen(bitmapIcon, 16, 0, 0, box2._x1, box2._x2, box2._y1, box2._y2);
- if (champion.getAttributes(kChampionAttributeDisableAction) || _vm->_championMan->_candidateChampionOrdinal || _vm->_championMan->_partyIsSleeping) {
+ if (champion.getAttributes(k0x0008_ChampionAttributeDisableAction) || _vm->_championMan->_g299_candidateChampionOrdinal || _vm->_championMan->_g300_partyIsSleeping) {
warning("MISSING CODE: F0136_VIDEO_ShadeScreenBox");
}
}
void MenuMan::drawDisabledMenu() {
- if (!_vm->_championMan->_partyIsSleeping) {
+ if (!_vm->_championMan->_g300_partyIsSleeping) {
warning("MISSING CODE: F0363_COMMAND_HighlightBoxDisable");
_vm->_displayMan->_g578_useByteBoxCoordinates = false;
if (_vm->_inventoryMan->_inventoryChampionOrdinal) {
@@ -139,39 +139,39 @@ void MenuMan::drawDisabledMenu() { void MenuMan::refreshActionAreaAndSetChampDirMaxDamageReceived() {
ChampionMan &champMan = *_vm->_championMan;
- if (!champMan._partyChampionCount)
+ if (!champMan._g305_partyChampionCount)
return;
Champion *champ = nullptr;
- if (champMan._partyIsSleeping || champMan._candidateChampionOrdinal) {
- if (champMan._actingChampionOrdinal) {
+ if (champMan._g300_partyIsSleeping || champMan._g299_candidateChampionOrdinal) {
+ if (champMan._g506_actingChampionOrdinal) {
clearActingChampion();
return;
}
- if (!champMan._candidateChampionOrdinal)
+ if (!champMan._g299_candidateChampionOrdinal)
return;
} else {
champ = champMan._champions;
- int16 champIndex = kChampionFirst;
+ int16 champIndex = k0_ChampionFirst;
do {
- if ((champIndex != champMan._leaderIndex)
- && (_vm->indexToOrdinal(champIndex) != champMan._actingChampionOrdinal)
+ if ((champIndex != champMan._g411_leaderIndex)
+ && (_vm->indexToOrdinal(champIndex) != champMan._g506_actingChampionOrdinal)
&& (champ->_maximumDamageReceived)
&& (champ->_dir != champ->_directionMaximumDamageReceived)) {
champ->_dir = (direction)champ->_directionMaximumDamageReceived;
- champ->setAttributeFlag(kChampionAttributeIcon, true);
+ champ->setAttributeFlag(k0x0400_ChampionAttributeIcon, true);
champMan.drawChampionState((ChampionIndex)champIndex);
}
champ->_maximumDamageReceived = 0;
champ++;
champIndex++;
- } while (champIndex < champMan._partyChampionCount);
+ } while (champIndex < champMan._g305_partyChampionCount);
}
if (_refreshActionArea) {
- if (!champMan._actingChampionOrdinal) {
+ if (!champMan._g506_actingChampionOrdinal) {
if (_actionDamage) {
warning("MISSING CODE: F0385_MENUS_DrawActionDamage");
_actionDamage = 0;
@@ -181,8 +181,8 @@ void MenuMan::refreshActionAreaAndSetChampDirMaxDamageReceived() { }
} else {
_actionAreaContainsIcons = false;
- champ->setAttributeFlag(kChampionAttributeActionHand, true);
- champMan.drawChampionState((ChampionIndex)_vm->ordinalToIndex(champMan._actingChampionOrdinal));
+ champ->setAttributeFlag(k0x8000_ChampionAttributeActionHand, true);
+ champMan.drawChampionState((ChampionIndex)_vm->ordinalToIndex(champMan._g506_actingChampionOrdinal));
warning("MISSING CODE: F0387_MENUS_DrawActionArea");
}
}
@@ -200,16 +200,16 @@ void MenuMan::drawActionArea() { dispMan._g578_useByteBoxCoordinates = false;
dispMan.clearScreenBox(k0_ColorBlack, gBoxActionArea);
if (_actionAreaContainsIcons) {
- for (uint16 champIndex = kChampionFirst; champIndex < champMan._partyChampionCount; ++champIndex)
+ for (uint16 champIndex = k0_ChampionFirst; champIndex < champMan._g305_partyChampionCount; ++champIndex)
drawActionIcon((ChampionIndex)champIndex);
- } else if (champMan._actingChampionOrdinal) {
+ } else if (champMan._g506_actingChampionOrdinal) {
Box box = gBoxActionArea3ActionMenu;
- if (_actionList._actionIndices[2] == kChampionActionNone)
+ if (_actionList._actionIndices[2] == k255_ChampionActionNone)
box = gBoxActionArea2ActionMenu;
- if (_actionList._actionIndices[1] == kChampionActionNone)
+ if (_actionList._actionIndices[1] == k255_ChampionActionNone)
box = gBoxActionArea1ActionMenu;
dispMan.blitToScreen(dispMan.getBitmap(k10_MenuActionAreaIndice), 96, 0, 0, box, k255_ColorNoTransparency);
- textMan.printWithTrailingSpacesToScreen(235, 83, k0_ColorBlack, k4_ColorCyan, champMan._champions[_vm->ordinalToIndex(champMan._actingChampionOrdinal)]._name,
+ textMan.printWithTrailingSpacesToScreen(235, 83, k0_ColorBlack, k4_ColorCyan, champMan._champions[_vm->ordinalToIndex(champMan._g506_actingChampionOrdinal)]._name,
kChampionNameMaximumLength);
for (uint16 actionListIndex = 0; actionListIndex < 3; actionListIndex++) {
textMan.printWithTrailingSpacesToScreen(241, 93 + actionListIndex * 12, k4_ColorCyan, k0_ColorBlack,
@@ -232,7 +232,7 @@ const char *gChampionActionNames[44] = { "BRANDISH", "THROW", "FUSE"};
const char* MenuMan::getActionName(ChampionAction actionIndex) {
- return (actionIndex == kChampionActionNone) ? "" : gChampionActionNames[actionIndex];
+ return (actionIndex == k255_ChampionActionNone) ? "" : gChampionActionNames[actionIndex];
}
@@ -249,9 +249,9 @@ void MenuMan::drawSpellAreaControls(ChampionIndex champIndex) { champCurrHealth[i] = champMan._champions[i]._currHealth;
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
dispMan.clearScreenBox(k0_ColorBlack, gBoxSpellAreaControls);
- int16 champCount = champMan._partyChampionCount;
+ int16 champCount = champMan._g305_partyChampionCount;
switch (champIndex) {
- case kChampionFirst:
+ case k0_ChampionFirst:
warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
textMan.printTextToScreen(235, 48, k0_ColorBlack, k4_ColorCyan, champ._name);
if (champCount) {
@@ -272,14 +272,14 @@ labelChamp3: }
}
break;
- case kChampionSecond:
+ case k1_ChampionSecond:
if (champCurrHealth[0]) {
warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
}
warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
textMan.printTextToScreen(249, 48, k0_ColorBlack, k4_ColorCyan, champ._name);
goto labelChamp2;
- case kChampionThird:
+ case k2_ChampionThird:
if (champCurrHealth[0]) {
warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
}
@@ -289,7 +289,7 @@ labelChamp3: warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
textMan.printTextToScreen(263, 48, k0_ColorBlack, k4_ColorCyan, champ._name);
goto labelChamp3;
- case kChampionFourth:
+ case k3_ChampionFourth:
if (champCurrHealth[0]) {
warning("MISSING CODE: F0006_MAIN_HighlightScreenBox");
}
@@ -312,7 +312,7 @@ labelChamp3: void MenuMan::buildSpellAreaLine(int16 spellAreaBitmapLine) {
DisplayMan &dispMan = *_vm->_displayMan;
- Champion &champ = _vm->_championMan->_champions[_vm->_championMan->_magicCasterChampionIndex];
+ Champion &champ = _vm->_championMan->_champions[_vm->_championMan->_g514_magicCasterChampionIndex];
if (spellAreaBitmapLine == kSpellAreaAvailableSymbols) {
dispMan._g578_useByteBoxCoordinates = false;
dispMan.blitToBitmap(dispMan.getBitmap(k11_MenuSpellAreLinesIndice), 96, 0, 12, _bitmapSpellAreaLine, 96, gBoxSpellAreaLine, k255_ColorNoTransparency);
@@ -340,16 +340,16 @@ void MenuMan::setMagicCasterAndDrawSpellArea(int16 champIndex) { ChampionMan &champMan = *_vm->_championMan;
DisplayMan &dispMan = *_vm->_displayMan;
- if ((champIndex == champMan._magicCasterChampionIndex)
- || ((champIndex != kChampionNone) && !champMan._champions[champIndex]._currHealth))
+ if ((champIndex == champMan._g514_magicCasterChampionIndex)
+ || ((champIndex != kM1_ChampionNone) && !champMan._champions[champIndex]._currHealth))
return;
- if (champMan._magicCasterChampionIndex == kChampionNone) {
+ if (champMan._g514_magicCasterChampionIndex == kM1_ChampionNone) {
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
dispMan.blitToScreen(dispMan.getBitmap(k9_MenuSpellAreaBackground), 96, 0, 0, gBoxSpellArea);
warning("MISSING CODE: F0078_MOUSE_ShowPointer");
}
- if (champIndex == kChampionNone) {
- champMan._magicCasterChampionIndex = kChampionNone;
+ if (champIndex == kM1_ChampionNone) {
+ champMan._g514_magicCasterChampionIndex = kM1_ChampionNone;
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
dispMan._g578_useByteBoxCoordinates = false;
dispMan.clearScreenBox(k0_ColorBlack, gBoxSpellArea);
@@ -357,7 +357,7 @@ void MenuMan::setMagicCasterAndDrawSpellArea(int16 champIndex) { return;
}
- champMan._magicCasterChampionIndex = (ChampionIndex)champIndex;
+ champMan._g514_magicCasterChampionIndex = (ChampionIndex)champIndex;
buildSpellAreaLine(kSpellAreaAvailableSymbols);
warning("MISSING CODE: F0077_MOUSE_HidePointer_CPSE");
drawSpellAreaControls((ChampionIndex)champIndex);
diff --git a/engines/dm/menus.h b/engines/dm/menus.h index a8df73531f..b591872011 100644 --- a/engines/dm/menus.h +++ b/engines/dm/menus.h @@ -43,7 +43,7 @@ public: ActionList() { for (uint16 i = 0; i < 3; ++i) { _minimumSkillLevel[i] = 0; - _actionIndices[i] = kChampionActionNone; + _actionIndices[i] = k255_ChampionActionNone; } } }; // @ ACTION_LIST diff --git a/engines/dm/movesens.cpp b/engines/dm/movesens.cpp index 1511146d69..0aca699aaf 100644 --- a/engines/dm/movesens.cpp +++ b/engines/dm/movesens.cpp @@ -44,7 +44,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 bool atLeastOneSensorWasTriggered = false; - Thing leaderHandObject = champMan._leaderHandObject; + Thing leaderHandObject = champMan._414_leaderHandObject; int16 sensorCountToProcessPerCell[4]; uint16 cell; for (cell = kCellNorthWest; cell < kCellSouthWest; ++cell) { @@ -73,7 +73,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 SensorType sensorType = sensor->getType(); if (sensorType == kSensorDisabled) goto T0275058_ProceedToNextThing; - if ((champMan._leaderIndex == kChampionNone) && (sensorType != kSensorWallChampionPortrait)) + if ((champMan._g411_leaderIndex == kM1_ChampionNone) && (sensorType != kSensorWallChampionPortrait)) goto T0275058_ProceedToNextThing; if (cell != cellParam) goto T0275058_ProceedToNextThing; @@ -88,7 +88,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 } break; case kSensorWallOrnClickWithAnyObj: - doNotTriggerSensor = (champMan._leaderEmptyHanded != sensor->getRevertEffectA()); + doNotTriggerSensor = (champMan._g415_leaderEmptyHanded != sensor->getRevertEffectA()); break; case kSensorWallOrnClickWithSpecObjRemovedSensor: case kSensorWallOrnClickWithSpecObjRemovedRotateSensors: @@ -111,13 +111,13 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 case kSensorWallObjGeneratorRotateSensors: if (sensorCountToProcessPerCell[cell]) goto T0275058_ProceedToNextThing; - doNotTriggerSensor = !champMan._leaderEmptyHanded; + doNotTriggerSensor = !champMan._g415_leaderEmptyHanded; if (!doNotTriggerSensor) { warning("MISSING CODE: F0270_SENSOR_TriggerLocalEffect"); } break; case kSensorWallSingleObjStorageRotateSensors: - if (champMan._leaderEmptyHanded) { + if (champMan._g415_leaderEmptyHanded) { warning("MISSING CODE: F0273_SENSOR_GetObjectOfTypeInCell"); warning("MISSING CODE: F0164_DUNGEON_UnlinkThingFromList"); warning("MISSING CODE: F0297_CHAMPION_PutObjectInLeaderHand"); @@ -128,7 +128,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 leaderHandObject = Thing::_none; } warning("MISSING CODE: F0270_SENSOR_TriggerLocalEffect"); - if ((sensorEffect == kSensorEffHold) && !champMan._leaderEmptyHanded) { + if ((sensorEffect == kSensorEffHold) && !champMan._g415_leaderEmptyHanded) { doNotTriggerSensor = true; } else { doNotTriggerSensor = false; @@ -164,7 +164,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 if (sensor->getAudibleA()) { warning("MISSING CODE: F0064_SOUND_RequestPlay_CPSD"); } - if (!champMan._leaderEmptyHanded && + if (!champMan._g415_leaderEmptyHanded && ((sensorType == kSensorWallOrnClickWithSpecObjRemoved) || (sensorType == kSensorWallOrnClickWithSpecObjRemovedRotateSensors) || (sensorType == kSensorWallOrnClickWithSpecObjRemovedSensor))) { @@ -174,7 +174,7 @@ bool MovesensMan::sensorIsTriggeredByClickOnWall(int16 mapX, int16 mapY, uint16 leaderHandObject = Thing::_none; } else { warning("MISSING CODE: (leaderHandObject = F0167_DUNGEON_GetObjectForProjectileLauncherOrObjectGenerator(sensorData)"); - if (champMan._leaderEmptyHanded && (sensorType == kSensorWallObjGeneratorRotateSensors) && (leaderHandObject != Thing::_none)) { + if (champMan._g415_leaderEmptyHanded && (sensorType == kSensorWallObjGeneratorRotateSensors) && (leaderHandObject != Thing::_none)) { warning("MISSING CODE: F0297_CHAMPION_PutObjectInLeaderHand"); } } diff --git a/engines/dm/objectman.cpp b/engines/dm/objectman.cpp index dd3550200d..ae67904beb 100644 --- a/engines/dm/objectman.cpp +++ b/engines/dm/objectman.cpp @@ -123,7 +123,7 @@ void ObjectMan::loadObjectNames() { IconIndice ObjectMan::getObjectType(Thing thing) { if (thing == Thing::_none) - return kIconIndiceNone; + return kM1_IconIndiceNone; int16 objectInfoIndex = _vm->_dungeonMan->getObjectInfoIndex(thing); if (objectInfoIndex != -1) { @@ -137,41 +137,41 @@ byte gChargeCountToTorchType[16] = {0, 1, 1, 1, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3, 3, IconIndice ObjectMan::getIconIndex(Thing thing) { IconIndice iconIndex = getObjectType(thing); - if ((iconIndex != kIconIndiceNone) && - (((iconIndex < kIconIndiceWeaponDagger) && (iconIndex >= kIconIndiceJunkCompassNorth)) || // < instead of <= is no error - ((iconIndex >= kIconIndicePotionMaPotionMonPotion) && (iconIndex <= kIconIndicePotionWaterFlask)) || - (iconIndex == kIconIndicePotionEmptyFlask)) + if ((iconIndex != kM1_IconIndiceNone) && + (((iconIndex < k32_IconIndiceWeaponDagger) && (iconIndex >= k0_IconIndiceJunkCompassNorth)) || // < instead of <= is no error + ((iconIndex >= k148_IconIndicePotionMaPotionMonPotion) && (iconIndex <= k163_IconIndicePotionWaterFlask)) || + (iconIndex == k195_IconIndicePotionEmptyFlask)) ) { uint16 *rawType = _vm->_dungeonMan->getThingData(thing); switch (iconIndex) { - case kIconIndiceJunkCompassNorth: + case k0_IconIndiceJunkCompassNorth: iconIndex = (IconIndice)(iconIndex + _vm->_dungeonMan->_currMap._partyDir); break; - case kIconIndiceWeaponTorchUnlit: { + case k4_IconIndiceWeaponTorchUnlit: { Weapon weapon(rawType); if (weapon.isLit()) { iconIndex = (IconIndice)(iconIndex + gChargeCountToTorchType[weapon.getChargeCount()]); } break; } - case kIconIndiceScrollOpen: + case k30_IconIndiceScrollOpen: if (Scroll(rawType).getClosed()) { iconIndex = (IconIndice)(iconIndex + 1); } break; - case kIconIndiceJunkWater: - case kIconIndiceJunkIllumuletUnequipped: - case kIconIndiceJunkJewelSymalUnequipped: + case k8_IconIndiceJunkWater: + case k12_IconIndiceJunkIllumuletUnequipped: + case k10_IconIndiceJunkJewelSymalUnequipped: if (Junk(rawType).getChargeCount()) { iconIndex = (IconIndice)(iconIndex + 1); } break; - case kIconIndiceWeaponBoltBladeStormEmpty: - case kIconIndiceWeaponFlamittEmpty: - case kIconIndiceWeaponStormringEmpty: - case kIconIndiceWeaponFuryRaBladeEmpty: - case kIconIndiceWeaponEyeOfTimeEmpty: - case kIconIndiceWeaponStaffOfClawsEmpty: + case k23_IconIndiceWeaponBoltBladeStormEmpty: + case k14_IconIndiceWeaponFlamittEmpty: + case k18_IconIndiceWeaponStormringEmpty: + case k25_IconIndiceWeaponFuryRaBladeEmpty: + case k16_IconIndiceWeaponEyeOfTimeEmpty: + case k20_IconIndiceWeaponStaffOfClawsEmpty: if (Weapon(rawType).getChargeCount()) { iconIndex = (IconIndice)(iconIndex + 1); } @@ -201,7 +201,7 @@ void ObjectMan::extractIconFromBitmap(uint16 iconIndex, byte *destBitmap) { void ObjectMan::drawIconInSlotBox(uint16 slotBoxIndex, int16 iconIndex) { SlotBox *slotBox = &_slotBoxes[slotBoxIndex]; slotBox->_iconIndex = iconIndex; // yes, this modifies the global array - if (slotBox->_iconIndex == kIconIndiceNone) { + if (slotBox->_iconIndex == kM1_IconIndiceNone) { return; } @@ -237,7 +237,7 @@ void ObjectMan::drawLeaderObjectName(Thing thing) { IconIndice iconIndex = getIconIndex(thing); char *objName; char objectNameBuffer[16]; - if (iconIndex == kIconIndiceJunkChampionBones) { + if (iconIndex == k147_IconIndiceJunkChampionBones) { Junk *junk = (Junk*)_vm->_dungeonMan->getThingData(thing); strcpy(objectNameBuffer, _vm->_championMan->_champions[junk->getChargeCount()]._name); strcat(objectNameBuffer, _objectNames[iconIndex]); |