diff --git a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/HardcodedProvider.cs b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/HardcodedProvider.cs index 2c65c7b0..8f5856d5 100644 --- a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/HardcodedProvider.cs +++ b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/HardcodedProvider.cs @@ -71,8 +71,11 @@ internal class HardcodedProvider : INewbieInfoProvider 97512825, // a9 }; - private const long NewbieGroupId = 595985887; - private const long NewbieGroup2Id = 928936255; + private const long LegacyNewbieGroupId = 595985887; // 即将删除 + private const long NewbieGroupId = 231094840; + private const long AdvancedGroupId = 928936255; + private const long HyperGroupId = 281624271; + private const long GraveyardGroupId = 293129929; public static INewbieInfoProvider GetProvider() => new HardcodedProvider(); @@ -80,13 +83,14 @@ internal class HardcodedProvider : INewbieInfoProvider public IEnumerable MonitoredGroups { get; } = new List { + LegacyNewbieGroupId, NewbieGroupId, - NewbieGroup2Id, + AdvancedGroupId }.AsReadOnly(); #pragma warning disable CS1998 public async Task ShouldIgnoreAsync(long qq) => IgnoreList.Contains(qq); - public async Task ShouldIgnorePerformanceAsync(long group, long qq) => group == NewbieGroupId ? IgnorePerformanceListBase.Contains(qq) : false; + public async Task ShouldIgnorePerformanceAsync(long group, long qq) => (group == NewbieGroupId || group == LegacyNewbieGroupId) ? IgnorePerformanceListBase.Contains(qq) : false; #pragma warning restore CS1998 public double? PerformanceLimit(long group) => group == NewbieGroupId ? (double?)2500 : null; } diff --git a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/NotifyOnJoinRequest.cs b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/NotifyOnJoinRequest.cs index 0a7cac58..be1b7296 100644 --- a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/NotifyOnJoinRequest.cs +++ b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/NotifyOnJoinRequest.cs @@ -34,7 +34,8 @@ public partial class NotifyOnJoinRequest : Service, IMessageCommand #endif private static readonly IReadOnlyDictionary ManagedGroups = new Dictionary { - [595985887] = 2800, + [595985887] = 2800, // 即将删除 + [231094840] = 2800, [928936255] = 4300, [281624271] = 5800, [758120648] = null, diff --git "a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/\347\273\237\350\256\241\346\226\260\344\272\272\347\276\244\346\210\220\345\221\230.cs" "b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/\347\273\237\350\256\241\346\226\260\344\272\272\347\276\244\346\210\220\345\221\230.cs" index 5e2142c0..3b26d28c 100644 --- "a/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/\347\273\237\350\256\241\346\226\260\344\272\272\347\276\244\346\210\220\345\221\230.cs" +++ "b/Bleatingsheep.NewHydrant.Bot.Private/Osu/Newbie/\347\273\237\350\256\241\346\226\260\344\272\272\347\276\244\346\210\220\345\221\230.cs" @@ -29,7 +29,8 @@ public class 统计新人群成员 : Service, IMessageCommand private static readonly Dictionary s_groups = new() { - { "新人群", (595985887, 3000, 190) }, + { "旧新人群", (595985887, 3000, 190) }, + { "新人群", (231094840, 3000, 190) }, { "进阶群", (928936255, 4500, 280) }, { "高阶群", (281624271, 6000, 360) }, }; diff --git a/Bleatingsheep.NewHydrant.Bot.Public/Osu/PerformancePlusUser.cs b/Bleatingsheep.NewHydrant.Bot.Public/Osu/PerformancePlusUser.cs index 2674ea52..a0a3882f 100644 --- a/Bleatingsheep.NewHydrant.Bot.Public/Osu/PerformancePlusUser.cs +++ b/Bleatingsheep.NewHydrant.Bot.Public/Osu/PerformancePlusUser.cs @@ -143,7 +143,7 @@ public async Task ProcessAsync(Sisters.WudiLib.Posts.Message message, HttpApiCli } catch (ExceptionPlus) { - await api.SendMessageAsync(message.Endpoint, "查询PP+失败。"); + await api.SendMessageAsync(message.Endpoint, "查询 PP+ 失败。"); return; } } @@ -165,7 +165,7 @@ public bool ShouldResponse(Sisters.WudiLib.Posts.Message message) { if (!message.Content.IsPlaintext) return false; - if (message is GroupMessage g && g.GroupId == 595985887) + if (message is GroupMessage g && (g.GroupId == 595985887 || g.GroupId == 231094840)) return false; // ignored in newbie group. string text = message.Content.Text.Trim(); if (text.StartsWith("+", StringComparison.Ordinal)) diff --git a/Bleatingsheep.NewHydrant.Bot.Public/Osu/Plus/PlusPlus.cs b/Bleatingsheep.NewHydrant.Bot.Public/Osu/Plus/PlusPlus.cs index 12e015a2..e90d1a11 100644 --- a/Bleatingsheep.NewHydrant.Bot.Public/Osu/Plus/PlusPlus.cs +++ b/Bleatingsheep.NewHydrant.Bot.Public/Osu/Plus/PlusPlus.cs @@ -65,7 +65,7 @@ public async Task ProcessAsync(MessageContext context, HttpApiClient api) public bool ShouldResponse(MessageContext context) { - if (context is GroupMessage g && g.GroupId == 595985887) + if (context is GroupMessage g && (g.GroupId == 595985887 || g.GroupId == 231094840)) return false; // ignored in newbie group. return context.Content.TryGetPlainText(out var text) && text == "++"; } diff --git a/Bleatingsheep.NewHydrant.Bot.Public/Osu/PpTth2.cs b/Bleatingsheep.NewHydrant.Bot.Public/Osu/PpTth2.cs index 251619fd..d4b25537 100644 --- a/Bleatingsheep.NewHydrant.Bot.Public/Osu/PpTth2.cs +++ b/Bleatingsheep.NewHydrant.Bot.Public/Osu/PpTth2.cs @@ -123,7 +123,7 @@ await page.SetViewportAsync(new ViewPortOptions public bool ShouldResponse(MessageContext message) { - if (message is GroupMessage g && g.GroupId == 595985887) + if (message is GroupMessage g && (g.GroupId == 595985887 || g.GroupId == 231094840)) return false; // ignored in newbie group. if (message.Content.TryGetPlainText(out string text)) { diff --git "a/Bleatingsheep.NewHydrant.Bot.Public/\345\225\245\347\216\251\346\204\217\345\204\277\345\225\212/Moebooru/AdvancedKonachan.cs" "b/Bleatingsheep.NewHydrant.Bot.Public/\345\225\245\347\216\251\346\204\217\345\204\277\345\225\212/Moebooru/AdvancedKonachan.cs" index dacce5bc..a31cfca6 100644 --- "a/Bleatingsheep.NewHydrant.Bot.Public/\345\225\245\347\216\251\346\204\217\345\204\277\345\225\212/Moebooru/AdvancedKonachan.cs" +++ "b/Bleatingsheep.NewHydrant.Bot.Public/\345\225\245\347\216\251\346\204\217\345\204\277\345\225\212/Moebooru/AdvancedKonachan.cs" @@ -206,6 +206,6 @@ private async Task TrySendImage(Endpoint endpoint, HttpApiClient api, int private record struct ImageCacheEntry(bool IsSuccess, byte[] Data); public bool ShouldResponse(MessageContext context) - => RegexCommand(s_regex, context.Content) && (!(context is GroupMessage g) || !(g.GroupId == 595985887)); + => RegexCommand(s_regex, context.Content) && (!(context is GroupMessage g) || !(g.GroupId == 595985887 || g.GroupId == 231094840)); } }