ソースを参照

Fixes build warning in Potential Targets

Opuszek 1 ヶ月 前
コミット
10a4a3adee
2 ファイル変更2 行追加2 行削除
  1. 1 1
      AI/BattleAI/PotentialTargets.cpp
  2. 1 1
      lib/battle/CBattleInfoCallback.h

+ 1 - 1
AI/BattleAI/PotentialTargets.cpp

@@ -23,7 +23,7 @@ PotentialTargets::PotentialTargets(
 
 	//FIXME: this should part of battleGetAvailableHexes
 	bool isBerserk = attackerInfo->hasBonusOfType(BonusType::ATTACKS_NEAREST_CREATURE);
-	ForcedAction forcedAction;
+	ForcedAction forcedAction = {};
 
 	if(isBerserk)
 		forcedAction = state->getBerserkForcedAction(attackerInfo);

+ 1 - 1
lib/battle/CBattleInfoCallback.h

@@ -53,7 +53,7 @@ struct DLL_LINKAGE BattleClientInterfaceData
 };
 
 struct ForcedAction {
-	EActionType type;
+	EActionType type = EActionType::NO_ACTION;
 	BattleHex position;
 	const battle::Unit * target;
 };