From 0152ba827804605ade2ae4251f82354d1893e597 Mon Sep 17 00:00:00 2001 From: ZouJin Date: Sun, 17 Sep 2023 23:49:08 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E8=B6=85=E6=A8=A1=E6=A3=80?= =?UTF-8?q?=E6=9F=A5=E5=88=A4=E6=96=AD=E9=94=99=E8=AF=AF?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ExtensionFunction.cs | 2 +- VPet-Simulator.Windows/MainWindow.cs | 12 +++++++----- 2 files changed, 8 insertions(+), 6 deletions(-) diff --git a/VPet-Simulator.Windows.Interface/ExtensionFunction.cs b/VPet-Simulator.Windows.Interface/ExtensionFunction.cs index a092a6d..6da7952 100644 --- a/VPet-Simulator.Windows.Interface/ExtensionFunction.cs +++ b/VPet-Simulator.Windows.Interface/ExtensionFunction.cs @@ -20,7 +20,7 @@ namespace VPet_Simulator.Windows.Interface /// 是否超模 public static bool IsOverLoad(this Work work) {//判断这个工作是否超模 - if (work.FinishBonus <= 0) + if (work.FinishBonus < 0) return true; var spend = ((work.StrengthFood >= 0 ? 1 : -1) * Math.Pow(work.StrengthFood * 2 + 1, 2) / 6 + (work.StrengthDrink >= 0 ? 1 : -1) * Math.Pow(work.StrengthDrink * 2 + 1, 2) / 9 + diff --git a/VPet-Simulator.Windows/MainWindow.cs b/VPet-Simulator.Windows/MainWindow.cs index 0c7f924..e0eef61 100644 --- a/VPet-Simulator.Windows/MainWindow.cs +++ b/VPet-Simulator.Windows/MainWindow.cs @@ -48,7 +48,7 @@ namespace VPet_Simulator.Windows /// /// 版本号 /// - public int version { get; } = 105; + public int version { get; } = 106; /// /// 版本号 /// @@ -875,16 +875,18 @@ namespace VPet_Simulator.Windows //看看是否超模 if (HashCheck && work.IsOverLoad()) { - var spend = (Math.Pow(work.StrengthFood * 2 + 1, 2) / 6 + Math.Pow(work.StrengthDrink * 2 + 1, 2) / 9 + - Math.Pow(work.Feeling * 2 + 1, 2) / 12) * (Math.Pow(work.LevelLimit / 2 + 1, 0.5) / 4 + 1) - 0.5; + var spend = ((work.StrengthFood >= 0 ? 1 : -1) * Math.Pow(work.StrengthFood * 2 + 1, 2) / 6 + + (work.StrengthDrink >= 0 ? 1 : -1) * Math.Pow(work.StrengthDrink * 2 + 1, 2) / 9 + + (work.Feeling >= 0 ? 1 : -1) * Math.Pow((work.Type == Work.WorkType.Play ? -1 : 1) * work.Feeling * 2 + 1, 2) / 12) * + (Math.Pow(work.LevelLimit / 2 + 1, 0.5) / 4 + 1) - 0.5; var get = (work.MoneyBase + work.MoneyLevel * 10) * (work.MoneyLevel + 1) * (1 + work.FinishBonus / 2); if (work.Type != Work.WorkType.Work) { get /= 12;//经验值换算 } var rel = get / spend; - if (MessageBoxX.Show("当前工作数据属性超模,是否继续工作?\n超模工作可能会导致游戏发生不可预料的错误\n超模工作不影响大部分成就解锁\n当前数据比率 {0:f2}\n推荐比率<1.5" - .Translate(rel), "超模工作提醒".Translate(), MessageBoxButton.YesNo) != MessageBoxResult.Yes) + if (MessageBoxX.Show("当前工作数据属性超模,是否继续工作?\n超模工作可能会导致游戏发生不可预料的错误\n超模工作不影响大部分成就解锁\n当前数据比率 {0:f2} 推荐<1.5\n盈利速度:{1:f0} 推荐<{2}" + .Translate(rel, get, (work.LevelLimit + 4) * 6), "超模工作提醒".Translate(), MessageBoxButton.YesNo) != MessageBoxResult.Yes) { return false; }