Browse Source

Remove hardcoded constant

Ivan Savenko 2 years ago
parent
commit
a42dc923e4
1 changed files with 2 additions and 2 deletions
  1. 2 2
      client/battle/BattleActionsController.cpp

+ 2 - 2
client/battle/BattleActionsController.cpp

@@ -689,14 +689,14 @@ void BattleActionsController::actionRealize(PossiblePlayerBattleAction action, B
 				if (action.spell() == SpellID::SACRIFICE)
 				{
 					heroSpellToCast->aimToHex(targetHex);
-					possibleActions.push_back({PossiblePlayerBattleAction::SACRIFICE, SpellID::SACRIFICE});
+					possibleActions.push_back({PossiblePlayerBattleAction::SACRIFICE, action.spell()});
 					owner.stacksController->setSelectedStack(targetStack);
 					return;
 				}
 				if (action.spell() == SpellID::TELEPORT)
 				{
 					heroSpellToCast->aimToUnit(targetStack);
-					possibleActions.push_back({PossiblePlayerBattleAction::TELEPORT, SpellID::TELEPORT});
+					possibleActions.push_back({PossiblePlayerBattleAction::TELEPORT, action.spell()});
 					owner.stacksController->setSelectedStack(targetStack);
 					return;
 				}