From bc2f1801062ec7fd41125b6c0576ef0c9e4e7535 Mon Sep 17 00:00:00 2001 From: milimoe Date: Sun, 27 Jul 2025 23:44:44 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BC=98=E5=8C=96=E5=95=86=E5=BA=97=E6=98=BE?= =?UTF-8?q?=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- Entity/Trade/Store.cs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/Entity/Trade/Store.cs b/Entity/Trade/Store.cs index 0725926..d7ba4b9 100644 --- a/Entity/Trade/Store.cs +++ b/Entity/Trade/Store.cs @@ -69,11 +69,18 @@ namespace Milimoe.FunGame.Core.Entity } builder.AppendLine($"☆--- 商品列表 ---☆"); Goods[] goodsValid = [.. Goods.Values.Where(g => !g.ExpireTime.HasValue || g.ExpireTime.Value > DateTime.Now)]; - foreach (Goods goods in goodsValid) + if (goodsValid.Length == 0) { - builder.AppendLine(goods.ToString(user)); + builder.AppendLine("当前没有商品可供购买,过一段时间再来吧。"); + } + else + { + foreach (Goods goods in goodsValid) + { + builder.AppendLine(goods.ToString(user)); + } + builder.AppendLine("提示:使用【商店查看+序号】查看物品详细信息,使用【商店购买+序号】购买物品(指令在 2 分钟内可用)。"); } - builder.AppendLine("提示:使用【商店查看+序号】查看物品详细信息,使用【商店购买+序号】购买物品(指令在 2 分钟内可用)。"); if (AutoRefresh) { builder.AppendLine($"商品将在 {NextRefreshDate.ToString(General.GeneralDateTimeFormatChinese)} 刷新。");