コミットメタ情報

リビジョン56a5c6ce64b6631139b833d36c1a2bf64f620931 (tree)
日時2018-05-12 20:25:04
作者Kazuhiro Fujieda <fujieda@user...>
コミッターKazuhiro Fujieda

ログメッセージ

艦隊情報で艦隊の火力の合計と燃費を表示する

変更サマリ

差分

--- a/KancolleSniffer/FleetPanel.cs
+++ b/KancolleSniffer/FleetPanel.cs
@@ -28,7 +28,7 @@ namespace KancolleSniffer
2828 private Record[] _table;
2929 private readonly List<FleetLabels> _labelList = new List<FleetLabels>();
3030 private readonly List<Panel> _panelList = new List<Panel>();
31- private readonly ResizableToolTip _toolTip = new ResizableToolTip {ShowAlways = true};
31+ private readonly ResizableToolTip _toolTip = new ResizableToolTip {ShowAlways = true, AutoPopDelay = 10000};
3232
3333 private class Record
3434 {
@@ -68,8 +68,11 @@ namespace KancolleSniffer
6868 var drumTotal = 0;
6969 var drumShips = 0;
7070 var levelTotal = 0;
71+ var fpTotal = 0;
7172 var aswTotal = 0;
7273 var antiAirTotal = 0;
74+ var fuelTotal = 0;
75+ var bullTotal = 0;
7376 var losTotal = 0;
7477 var ships = new List<Record>();
7578 foreach (var s in sniffer.GetShipStatuses(f))
@@ -114,9 +117,12 @@ namespace KancolleSniffer
114117 drumShips++;
115118 drumTotal += drum;
116119 levelTotal += s.Level;
120+ fpTotal += s.Firepower;
117121 aswTotal += s.MissionAntiSubmarine;
118122 antiAirTotal += s.AntiAir;
119123 losTotal += s.LoS;
124+ fuelTotal += Math.Max((int)(s.Spec.FuelMax * (s.Level >= 100 ? 0.85 : 1.0)), 1);
125+ bullTotal += Math.Max((int)(s.Spec.BullMax * (s.Level >= 100 ? 0.85 : 1.0)), 1);
120126 var fire = s.EffectiveFirepower;
121127 var subm = s.EffectiveAntiSubmarine;
122128 var torp = s.EffectiveTorpedo;
@@ -147,12 +153,15 @@ namespace KancolleSniffer
147153 list.Add(new Record
148154 {
149155 Fleet = fn[f] + (levelTotal == 0 ? "" : " Lv" + levelTotal) +
150- (drumTotal == 0 ? "" : " 缶" + drumTotal + "(" + drumShips + "隻)") +
151- (aswTotal > 0 ? $" 潜{CutOverFlow(aswTotal)}" : "") +
152- (antiAirTotal > 0 ? $" 空{CutOverFlow(antiAirTotal)}" : "") +
153- (losTotal > 0 ? $" 索{CutOverFlow(losTotal)}" : ""),
154- Fleet2 = (sniffer.CombinedFleetType != 0 && f == 1 ? "" : $"TP:S{(int)tp}A{(int)(tp * 0.7)}") +
155- (daihatsu > 0 ? $" 発{daihatsu * 100:f1}%" : "")
156+ (drumTotal == 0 ? "" : " ドラム缶" + drumTotal + "(" + drumShips + "隻)") +
157+ (daihatsu > 0 ? $" 大発{daihatsu * 100:f1}%" : ""),
158+ Fleet2 = "計:" +
159+ "火" + CutOverFlow(fpTotal) +
160+ " 空" + CutOverFlow(antiAirTotal) +
161+ " 潜" + CutOverFlow(aswTotal) +
162+ " 索" + CutOverFlow(losTotal) + "\r\n" +
163+ $"戦闘:燃{fuelTotal / 5}弾{bullTotal / 5} 支援:燃{fuelTotal / 2}弾{(int)(bullTotal * 0.8)}" +
164+ (sniffer.CombinedFleetType != 0 && f == 1 ? "" : $"\r\nTP:S{(int)tp} A{(int)(tp * 0.7)}")
156165 });
157166 list.AddRange(ships);
158167 }
旧リポジトリブラウザで表示