Révision | e85d4b349cb3241bcd6ec657ae85593b4929aa90 (tree) |
---|---|
l'heure | 2020-05-09 19:59:35 |
Auteur | Kazuhiro Fujieda <fujieda@user...> |
Commiter | Kazuhiro Fujieda |
練習航海及び警備任務を実施せよ!のカウンターを実装する
@@ -165,7 +165,8 @@ namespace KancolleSniffer.Test | ||
165 | 165 | new QuestCount {Id = 280, NowArray = new[] {1, 1, 1, 1}}, |
166 | 166 | new QuestCount {Id = 872, NowArray = new[] {1, 1, 1, 1}}, |
167 | 167 | new QuestCount {Id = 284, NowArray = new[] {1, 1, 1, 1}}, |
168 | - new QuestCount {Id = 226, Now = 2} | |
168 | + new QuestCount {Id = 226, Now = 2}, | |
169 | + new QuestCount {Id = 436, NowArray = new[] {1, 0, 1, 1, 1}}, | |
169 | 170 | } |
170 | 171 | }; |
171 | 172 | new QuestInfo().LoadState(status); |
@@ -208,6 +209,9 @@ namespace KancolleSniffer.Test | ||
208 | 209 | var q226 = status.QuestCountList.First(q => q.Id == 226); |
209 | 210 | Assert.AreEqual("2/5", q226.ToString()); |
210 | 211 | Assert.AreEqual("", q226.ToToolTip()); |
212 | + var q436 = status.QuestCountList.First(q => q.Id == 436); | |
213 | + Assert.AreEqual("1\u200a0\u200a1\u200a1\u200a1", q436.ToString()); | |
214 | + Assert.AreEqual("練習航海1 長距離練習航海0 警備任務1 対潜警戒任務1 強行偵察任務1", q436.ToToolTip()); | |
211 | 215 | } |
212 | 216 | } |
213 | 217 |
@@ -1464,6 +1468,37 @@ namespace KancolleSniffer.Test | ||
1464 | 1468 | } |
1465 | 1469 | |
1466 | 1470 | /// <summary> |
1471 | + /// 436: 練習航海及び警備任務を実施せよ! | |
1472 | + /// </summary> | |
1473 | + [TestMethod] | |
1474 | + public void MissionResult_436() | |
1475 | + { | |
1476 | + var count = InjectQuest(436); | |
1477 | + | |
1478 | + _questCounter.InspectDeck(Js( | |
1479 | + new[] | |
1480 | + { | |
1481 | + new {api_id = 2, api_mission = new[] {2, 1}}, | |
1482 | + new {api_id = 3, api_mission = new[] {2, 2}}, | |
1483 | + new {api_id = 4, api_mission = new[] {2, 3}} | |
1484 | + })); | |
1485 | + _questCounter.InspectMissionResult("api%5Fdeck%5Fid=2", Js(new {api_clear_result = 1})); | |
1486 | + _questCounter.InspectMissionResult("api%5Fdeck%5Fid=3", Js(new {api_clear_result = 1})); | |
1487 | + _questCounter.InspectMissionResult("api%5Fdeck%5Fid=4", Js(new {api_clear_result = 1})); | |
1488 | + PAssert.That(() => count.NowArray.SequenceEqual(new[] {1, 1, 1, 0, 0})); | |
1489 | + | |
1490 | + _questCounter.InspectDeck(Js( | |
1491 | + new[] | |
1492 | + { | |
1493 | + new {api_id = 2, api_mission = new[] {2, 4}}, | |
1494 | + new {api_id = 3, api_mission = new[] {2, 10}} | |
1495 | + })); | |
1496 | + _questCounter.InspectMissionResult("api%5Fdeck%5Fid=2", Js(new {api_clear_result = 1})); | |
1497 | + _questCounter.InspectMissionResult("api%5Fdeck%5Fid=3", Js(new {api_clear_result = 1})); | |
1498 | + PAssert.That(() => count.NowArray.SequenceEqual(new[] {1, 1, 1, 1, 1})); | |
1499 | + } | |
1500 | + | |
1501 | + /// <summary> | |
1467 | 1502 | /// 503: 艦隊大整備! |
1468 | 1503 | /// 504: 艦隊酒保祭り! |
1469 | 1504 | /// </summary> |
@@ -23,7 +23,8 @@ namespace KancolleSniffer.Model | ||
23 | 23 | private const QuestInterval Weekly = QuestInterval.Weekly; |
24 | 24 | private const QuestInterval Monthly = QuestInterval.Monthly; |
25 | 25 | private const QuestInterval Quarterly = QuestInterval.Quarterly; |
26 | - private const QuestInterval Yearly = QuestInterval.Yearly; | |
26 | + private const QuestInterval Yearly2 = QuestInterval.Yearly2; | |
27 | + private const QuestInterval Yearly3 = QuestInterval.Yearly3; | |
27 | 28 | |
28 | 29 | /// <summary> |
29 | 30 | /// このテーブルは七四式電子観測儀を参考に作成した。 |
@@ -73,8 +74,8 @@ namespace KancolleSniffer.Model | ||
73 | 74 | {893, new QuestSortie {Interval = Quarterly, MaxArray = new[] {3, 3, 3, 3}, Rank = "S", Maps = new[] {15, 71, 721, 722}, Material = new[] {0, 0, 0, 0}}}, // 893: 泊地周辺海域の安全確保を徹底せよ! |
74 | 75 | {894, new QuestSortie {Interval = Quarterly, MaxArray = new[] {1, 1, 1, 1, 1}, Rank = "S", Maps = new[] {13, 14, 21, 22, 23}, Material = new[] {0, 0, 0, 0}}}, // 894: 空母戦力の投入による兵站線戦闘哨戒 |
75 | 76 | {903, new QuestSortie {Interval = Quarterly, MaxArray = new[] {1, 1, 1, 1}, Rank = "S", Maps = new[] {51, 54, 64, 65}, Material = new[] {0, 10, 0, 0}}}, // 903: 拡張「六水戦」、最前線へ! |
76 | - {904, new QuestSortie {Interval = Yearly, MaxArray = new[] {1, 1, 1, 1}, Rank = "S", Maps = new[] {25, 34, 45, 53}, Material = new[] {0, 8, 10, 4}}}, // 904: 精鋭「十九駆」、躍り出る! | |
77 | - {905, new QuestSortie {Interval = Yearly, MaxArray = new[] {1, 1, 1, 1, 1}, Rank = "A", Maps = new[] {11, 12, 13, 15, 16}, Material = new[] {0, 6, 8, 0}}}, // 905: 「海防艦」、海を護る! | |
77 | + {904, new QuestSortie {Interval = Yearly2, MaxArray = new[] {1, 1, 1, 1}, Rank = "S", Maps = new[] {25, 34, 45, 53}, Material = new[] {0, 8, 10, 4}}}, // 904: 精鋭「十九駆」、躍り出る! | |
78 | + {905, new QuestSortie {Interval = Yearly2, MaxArray = new[] {1, 1, 1, 1, 1}, Rank = "A", Maps = new[] {11, 12, 13, 15, 16}, Material = new[] {0, 6, 8, 0}}}, // 905: 「海防艦」、海を護る! | |
78 | 79 | |
79 | 80 | {303, new QuestPractice {Interval = Daily, Max = 3, Rank = "E", Material = new[] {1, 0, 0, 0}}}, // 303: 「演習」で練度向上! |
80 | 81 | {304, new QuestPractice {Interval = Daily, Max = 5, Rank = "B", Material = new[] {0, 0, 1, 0}}}, // 304: 「演習」で他提督を圧倒せよ! |
@@ -94,6 +95,7 @@ namespace KancolleSniffer.Model | ||
94 | 95 | {424, new QuestMission {Interval = Monthly, Max = 4, Shift = 1, Ids = new[] {5}, Material = new[] {0, 0, 0, 0}}}, // 424: 輸送船団護衛を強化せよ! |
95 | 96 | {426, new QuestMission {Interval = Quarterly, MaxArray = new[] {1, 1, 1, 1}, Ids = new[] {3, 4, 5, 10}, Material = new[] {0, 0, 4, 0}}}, // 426: 海上通商航路の警戒を厳とせよ! |
96 | 97 | {428, new QuestMission {Interval = Quarterly, MaxArray = new[] {2, 2, 2}, Ids = new[] {4, 101, 102}, Material = new[] {0, 0, 0, 3}}}, // 428: 近海に侵入する敵潜を制圧せよ! |
98 | + {436, new QuestMission {Interval = Yearly3, MaxArray = new[] {1, 1, 1, 1, 1}, Ids = new[] {1, 2, 3, 4, 10}, Material = new [] {0, 4, 0, 0}}}, // 436: 練習航海及び警備任務を実施せよ! | |
97 | 99 | |
98 | 100 | {503, new QuestSpec {Interval = Daily, Max = 5, Material = new[] {0, 2, 0, 0}}}, // 503: 艦隊大整備! |
99 | 101 | {504, new QuestSpec {Interval = Daily, Max = 15, Material = new[] {1, 0, 1, 0}}}, // 504: 艦隊酒保祭り! |
@@ -123,6 +123,7 @@ namespace KancolleSniffer.Model | ||
123 | 123 | { |
124 | 124 | 426 => new[] {"警備任務", "対潜警戒任務", "海上護衛任務", "強硬偵察任務"}, |
125 | 125 | 428 => new[] {"対潜警戒任務", "海峡警備行動", "長時間対潜警戒"}, |
126 | + 436 => new[] {"練習航海", "長距離練習航海", "警備任務", "対潜警戒任務", "強行偵察任務"}, | |
126 | 127 | 688 => new[] {"艦戦", "艦爆", "艦攻", "水偵"}, |
127 | 128 | _ => new string[0] |
128 | 129 | }).Zip(NowArray, (entry, n) => $"{entry}{n}")); |
@@ -63,7 +63,8 @@ namespace KancolleSniffer.Model | ||
63 | 63 | Weekly, |
64 | 64 | Monthly, |
65 | 65 | Quarterly, |
66 | - Yearly | |
66 | + Yearly2, | |
67 | + Yearly3 | |
67 | 68 | } |
68 | 69 | |
69 | 70 | public class QuestInfo : IHaveState |
@@ -118,7 +119,7 @@ namespace KancolleSniffer.Model | ||
118 | 119 | private readonly QuestInterval[] _intervals = |
119 | 120 | { |
120 | 121 | QuestInterval.Daily, QuestInterval.Weekly, QuestInterval.Monthly, |
121 | - QuestInterval.Other, QuestInterval.Quarterly, QuestInterval.Yearly | |
122 | + QuestInterval.Other, QuestInterval.Quarterly, QuestInterval.Yearly2 | |
122 | 123 | }; |
123 | 124 | |
124 | 125 | private readonly int[] _progress = {0, 50, 80}; |
@@ -219,7 +220,7 @@ namespace KancolleSniffer.Model | ||
219 | 220 | QuestInterval.Weekly => CrossBoundary(LastMonday.AddHours(5)), |
220 | 221 | QuestInterval.Monthly => CrossBoundary(new DateTime(_now.Year, _now.Month, 1, 5, 0, 0)), |
221 | 222 | QuestInterval.Quarterly => CrossBoundary(QuarterlyBoundary.AddHours(5)), |
222 | - QuestInterval.Yearly => CrossBoundary(new DateTime(_now.Year, 2, 1, 5, 0, 0)), | |
223 | + QuestInterval.Yearly2 => CrossBoundary(new DateTime(_now.Year, 2, 1, 5, 0, 0)), | |
223 | 224 | _ => false |
224 | 225 | }; |
225 | 226 | } |