OSDN Git Service

テスト用表示を修正
authormasakih <masakih@users.sourceforge.jp>
Fri, 24 Nov 2017 15:22:26 +0000 (00:22 +0900)
committermasakih <masakih@users.sourceforge.jp>
Fri, 24 Nov 2017 15:22:26 +0000 (00:22 +0900)
KCD/CalculateDamageCommand.swift

index 968d4f4..3be176d 100644 (file)
@@ -117,17 +117,29 @@ extension CalculateDamageCommand {
             
             guard let ship = aStore.ship(by: $0.shipID) else { return }
             
-            if ship.nowhp != $0.hp {
-                
-                Debug.print("\(ship.name)(\(ship.id)),HP \(ship.nowhp) -> \($0.hp)", level: .debug)
-            }
-            
             ship.nowhp = $0.hp
             
             if $0.useDamageControl { removeFirstDamageControl(of: ship) }
         }
         
-        Debug.print("------- End Battle", level: .debug)
+        Debug.excute(level: .debug) {
+            
+            print("-------")
+            
+            totalDamages.forEach {
+                
+                guard let ship = aStore.ship(by: $0.shipID) else { return }
+                
+                if ship.nowhp != $0.hp {
+                    
+                    print("\(ship.name)(\(ship.id)),HP \(ship.nowhp) -> \($0.hp)")
+                }
+            }
+            
+
+            print("------- End Battle")
+        }
+        
     }
     
     func updateBattleCell() {