From 4514cf8633eab1bcc71688ea8077ed882430bd6d Mon Sep 17 00:00:00 2001 From: ZouJin Date: Sun, 17 Sep 2023 13:58:31 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=20=E5=B7=A5=E4=BD=9C?= =?UTF-8?q?=E8=B6=85=E6=A8=A1=E5=88=A4=E5=AE=9A=E6=BC=8F=E6=B4=9E=20Fix=20?= =?UTF-8?q?#214?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- VPet-Simulator.Windows.Interface/ExtensionFunction.cs | 2 ++ 1 file changed, 2 insertions(+) diff --git a/VPet-Simulator.Windows.Interface/ExtensionFunction.cs b/VPet-Simulator.Windows.Interface/ExtensionFunction.cs index 4c8b137..a092a6d 100644 --- a/VPet-Simulator.Windows.Interface/ExtensionFunction.cs +++ b/VPet-Simulator.Windows.Interface/ExtensionFunction.cs @@ -20,6 +20,8 @@ namespace VPet_Simulator.Windows.Interface /// 是否超模 public static bool IsOverLoad(this Work work) {//判断这个工作是否超模 + 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 + (work.Feeling >= 0 ? 1 : -1) * Math.Pow((work.Type == Work.WorkType.Play ? -1 : 1) * work.Feeling * 2 + 1, 2) / 12) *