• R/O
  • HTTP
  • SSH
  • HTTPS

提交

Frequently used words (click to add to your profile)

javac++androidlinuxc#windowsobjective-ccocoa誰得qtpythonphprubygameguibathyscaphec計画中(planning stage)翻訳omegatframeworktwitterdomtestvb.netdirectxゲームエンジンbtronarduinopreviewer

Mac用艦これ専用ブラウザ おまけ機能付き


Commit MetaInfo

修訂57f656742a017a851367961c576205d3ecd9397c (tree)
時間2014-06-04 22:25:08
作者masakih <masakih@user...>
Commitermasakih

Log Message

完全勝利の時エラーログが出力される問題を解消

Change Summary

差異

--- a/KCD/HMCalculateDamageCommand.m
+++ b/KCD/HMCalculateDamageCommand.m
@@ -135,8 +135,10 @@
135135 } while(NO);
136136
137137 // hougeki1
138- {
138+ do {
139139 id targetShips = [self.json valueForKeyPath:@"api_data.api_hougeki1.api_df_list"];
140+ if(!targetShips || [targetShips isKindOfClass:[NSNull class]]) break;
141+
140142 id hougeki1Damages = [self.json valueForKeyPath:@"api_data.api_hougeki1.api_damage"];
141143 NSInteger i = 0;
142144 for(NSArray *array in targetShips) {
@@ -162,7 +164,7 @@
162164 }
163165 i++;
164166 }
165- }
167+ } while(NO);
166168
167169 // hougeki2
168170 do {
@@ -218,8 +220,10 @@
218220 NSArray *damages = [self damages];
219221
220222 // hougeki
221- {
223+ do {
222224 id targetShips = [self.json valueForKeyPath:@"api_data.api_hougeki.api_df_list"];
225+ if(!targetShips || [targetShips isKindOfClass:[NSNull class]]) break;
226+
223227 id hougeki1Damages = [self.json valueForKeyPath:@"api_data.api_hougeki.api_damage"];
224228 NSInteger i = 0;
225229 for(NSArray *array in targetShips) {
@@ -245,7 +249,7 @@
245249 }
246250 i++;
247251 }
248- }
252+ } while(NO);
249253
250254 [self.store saveAction:nil];
251255 }