修复生命值回复问题

This commit is contained in:
milimoe 2025-01-09 01:21:32 +08:00
parent 7a44c13138
commit b5231db724
Signed by: milimoe
GPG Key ID: 05D280912DA6C69E
3 changed files with 7 additions and 5 deletions

View File

@ -3974,7 +3974,7 @@ namespace Oshima.Core.Controllers
builer.AppendLine($"是否公开:{(club.IsPublic ? "" : "")}");
if (club.IsPublic) builer.AppendLine($"加入规则:{(club.IsNeedApproval ? "" : "")}");
builer.AppendLine($"成员数量:{club.Members.Count}");
if (club.Master?.Id == userid && club.Admins.ContainsKey(userid))
if (club.Master?.Id == userid || club.Admins.ContainsKey(userid))
{
builer.AppendLine($"管理员数量:{club.Admins.Count}");
builer.AppendLine($"申请人数量:{club.Applicants.Count}");

View File

@ -11,10 +11,12 @@
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Debug|AnyCPU'">
<NoWarn>1701;1702;IDE0130;CA1822;IDE1006</NoWarn>
<DebugType>embedded</DebugType>
</PropertyGroup>
<PropertyGroup Condition="'$(Configuration)|$(Platform)'=='Release|AnyCPU'">
<NoWarn>1701;1702;IDE0130;CA1822;IDE1006</NoWarn>
<DebugType>embedded</DebugType>
</PropertyGroup>
<ItemGroup>

View File

@ -501,9 +501,9 @@ namespace Oshima.Core.Utils
double recoveryHP = realCharacter.HR * seconds;
double recoveryMP = realCharacter.MR * seconds;
double recoveryEP = realCharacter.ER * seconds;
realCharacter.HP = inventoryCharacter.HP + recoveryHP;
realCharacter.MP = inventoryCharacter.MP + recoveryMP;
realCharacter.EP = inventoryCharacter.EP + recoveryEP;
realCharacter.HP += recoveryHP;
realCharacter.MP += recoveryMP;
realCharacter.EP += recoveryEP;
// 减少所有技能的冷却时间
foreach (Skill skill in realCharacter.Skills)
{
@ -1986,7 +1986,7 @@ namespace Oshima.Core.Utils
public static bool SettleQuest(User user, EntityModuleConfig<Quest> quests)
{
bool result = false;
IEnumerable<Quest> workingQuests = quests.Values.Where(q => q.Status == QuestState.InProgress);
IEnumerable<Quest> workingQuests = quests.Values.Where(q => q.QuestType == QuestType.Continuous && q.Status == QuestState.InProgress);
foreach (Quest quest in workingQuests)
{
if (quest.StartTime.HasValue && quest.StartTime.Value.AddMinutes(quest.EstimatedMinutes) <= DateTime.Now)