diff --git a/src/MaaWpfGui/Constants/AchievementIds.cs b/src/MaaWpfGui/Constants/AchievementIds.cs index 7282bac16f..f0369c38e8 100644 --- a/src/MaaWpfGui/Constants/AchievementIds.cs +++ b/src/MaaWpfGui/Constants/AchievementIds.cs @@ -94,6 +94,7 @@ public static class AchievementIds public const string QuickCloser = "QuickCloser"; public const string TacticalRetreat = "TacticalRetreat"; public const string Martian = "Martian"; + public const string AnnouncementStubbornClick = "AnnouncementStubbornClick"; public const string RecruitGroup = "Recruit"; public const string RecruitNoSixStar = "RecruitNoSixStar"; diff --git a/src/MaaWpfGui/Helper/AchievementTrackerHelper.cs b/src/MaaWpfGui/Helper/AchievementTrackerHelper.cs index d3942d5fb8..66fdb9105d 100644 --- a/src/MaaWpfGui/Helper/AchievementTrackerHelper.cs +++ b/src/MaaWpfGui/Helper/AchievementTrackerHelper.cs @@ -174,7 +174,7 @@ public class AchievementTrackerHelper : PropertyChangedBase return new([.. id.TakeWhile(char.IsLetter)]); } - public void Unlock(string id, bool staysOpen = true) + public void Unlock(string id, bool staysOpen = true, bool forceStayOpen = false) { if (!_achievements.TryGetValue(id, out var achievement) || achievement.IsUnlocked) { @@ -190,7 +190,7 @@ public class AchievementTrackerHelper : PropertyChangedBase { IsCustom = true, Message = $"{LocalizationHelper.GetString("AchievementCelebrate")}: {achievement.Title}\n{achievement.Description}", - StaysOpen = staysOpen && !SettingsViewModel.AchievementSettings.AchievementPopupAutoClose, + StaysOpen = forceStayOpen || (staysOpen && !SettingsViewModel.AchievementSettings.AchievementPopupAutoClose), WaitTime = 15, IconKey = "HangoverGeometry", IconBrushKey = achievement.MedalBrushKey, @@ -466,6 +466,7 @@ public class AchievementTrackerHelper : PropertyChangedBase Humor(id: AchievementIds.QuickCloser, isHidden: true), // 快速关闭弹窗 Humor(id: AchievementIds.TacticalRetreat), // 停止任务 Humor(id: AchievementIds.Martian, isHidden: true), // 90 天没更新 + Humor(id: AchievementIds.AnnouncementStubbornClick, isHidden: true), // 不看公告 Humor(id: AchievementIds.RecruitNoSixStar, group: AchievementIds.RecruitGroup, target: 500), // 公招中累计 500 次没出现六星tag Humor(id: AchievementIds.RecruitNoSixStarStreak, group: AchievementIds.RecruitGroup, target: 500, isHidden: true), // 公招中连续 500 次没出现六星tag diff --git a/src/MaaWpfGui/Res/Localizations/en-us.xaml b/src/MaaWpfGui/Res/Localizations/en-us.xaml index 06c5ab18a1..c85e2ff844 100644 --- a/src/MaaWpfGui/Res/Localizations/en-us.xaml +++ b/src/MaaWpfGui/Res/Localizations/en-us.xaml @@ -1370,6 +1370,10 @@ If you want to run multiple MAA at the same time, please copy the whole MAA and Resource or version date is more than 3 months old Resource or version date is more than {0} months old + Stubborn + Even after being prompted so many times, you still choose not to read the announcement. + Click the close button more than 20 times without scrolling to the bottom + Serious Erro- I'll be watching you. MAA Employee Guidelines diff --git a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml index 836103af9e..e6d92a060d 100644 --- a/src/MaaWpfGui/Res/Localizations/ja-jp.xaml +++ b/src/MaaWpfGui/Res/Localizations/ja-jp.xaml @@ -1371,6 +1371,10 @@ MAA を複数開くには、新しい MAA を他のフォルダにコピーし リソースまたはバージョンの時間が3ヶ月以上経過している リソースまたはバージョンの時間が{0}ヶ月以上経過している + 頑固者 + 何度も通知されているのに、それでもお知らせを読まずに閉じ続ける。 + 下までスクロールせずに閉じるボタンを20回以上クリックする + 重大エラー 私はずっとあなたを見つめています。 MAAのスタッフ規則 diff --git a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml index 11a576a641..4f508da41c 100644 --- a/src/MaaWpfGui/Res/Localizations/ko-kr.xaml +++ b/src/MaaWpfGui/Res/Localizations/ko-kr.xaml @@ -1372,6 +1372,10 @@ MAA를 독립된 새 폴더에 압축 해제하거나, MAA에 속하지 않는 D 리소스 또는 버전이 현재로부터 3개월 초과 리소스 또는 버전이 현재로부터 {0}개월 초과 + 고집불통 + 수차례 안내를 받았음에도 불구하고 공지를 보지 않고 닫기를 선택했습니다. + 맨 아래로 스크롤하지 않은 상태에서 닫기 버튼을 20회 이상 클릭함 + 서약 완료 약속한 거예요? 제가 옆에서 지켜볼게요 MAA 이용 약관 diff --git a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml index f8b6ad65e3..6258e38f57 100644 --- a/src/MaaWpfGui/Res/Localizations/zh-cn.xaml +++ b/src/MaaWpfGui/Res/Localizations/zh-cn.xaml @@ -1371,6 +1371,10 @@ C:\\leidian\\LDPlayer9。\n 资源时间或版本时间距今超过 3 个月 资源时间或版本时间距今超过 {0} 个月 + 死不悔改 + 即使提示了这么多次,你依然选择不看公告。 + 在未滚动到底部的情况下点击关闭按钮超过 20 次 + 严重错讠 我会一直注视着你。 MAA 员工守则 diff --git a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml index 8884a96f47..2d5dc3f267 100644 --- a/src/MaaWpfGui/Res/Localizations/zh-tw.xaml +++ b/src/MaaWpfGui/Res/Localizations/zh-tw.xaml @@ -1371,6 +1371,10 @@ C:\\leidian\\LDPlayer9。\n 資源時間或版本時間距今超過 3 個月 資源時間或版本時間距今超過 {0} 個月 + 死不悔改 + 即使提示了這麼多次,你依然選擇不看公告。 + 在未滾動到底部的情況下點擊關閉按鈕超過 20 次 + 嚴重錯訁 我會一直注視著你。 MAA 員工守則 diff --git a/src/MaaWpfGui/ViewModels/UI/AnnouncementViewModel.cs b/src/MaaWpfGui/ViewModels/UI/AnnouncementViewModel.cs index 2dfd915772..b651746444 100644 --- a/src/MaaWpfGui/ViewModels/UI/AnnouncementViewModel.cs +++ b/src/MaaWpfGui/ViewModels/UI/AnnouncementViewModel.cs @@ -275,7 +275,7 @@ public class AnnouncementViewModel : Screen ETagCache.Save(); } - private int _notFinishedClickIndex = 0; + private int _notFinishedClick = 0; private static readonly string[] _notFinishedMessages = [ LocalizationHelper.GetString("AnnouncementNotFinishedConfirm"), LocalizationHelper.GetString("AnnouncementNotFinishedConfirm2"), @@ -298,13 +298,19 @@ public class AnnouncementViewModel : Screen } else { - if (_notFinishedClickIndex < _notFinishedMessages.Length) + if (_notFinishedClick < _notFinishedMessages.Length) { - ButtonContent = _notFinishedMessages[_notFinishedClickIndex++]; + ButtonContent = _notFinishedMessages[_notFinishedClick++]; } else { ButtonContent += "?\u200B"; + _notFinishedClick++; + if (_notFinishedClick > 20) + { + AchievementTrackerHelper.Instance.Unlock(AchievementIds.AnnouncementStubbornClick, forceStayOpen: true); + RequestClose(); + } } } }