diff --git a/src/Snap.Hutao/Snap.Hutao.Test/IncomingFeature/UnlockerIslandFunctionOffsetTest.cs b/src/Snap.Hutao/Snap.Hutao.Test/IncomingFeature/UnlockerIslandFunctionOffsetTest.cs index 0327d5116..22bce36ed 100644 --- a/src/Snap.Hutao/Snap.Hutao.Test/IncomingFeature/UnlockerIslandFunctionOffsetTest.cs +++ b/src/Snap.Hutao/Snap.Hutao.Test/IncomingFeature/UnlockerIslandFunctionOffsetTest.cs @@ -14,19 +14,19 @@ public class UnlockerIslandFunctionOffsetTest [TestMethod] public void GenerateJson() { - // FunctionOffsetMickeyWonderMethod: + // MickeyWonderMethod: // public static byte[] AnonymousMethod43(int nType) -> jmp xxxxxxxx -> another xref to xxxxxxxx - // FunctionOffsetMickeyWonderMethodPartner: + // MickeyWonderMethodPartner: // public static string get_unityVersion() -> jmp - // FunctionOffsetMickeyWonderMethodPartner2: + // MickeyWonderMethodPartner2: // "4C 8B 05 ?? ?? ?? ?? 4C 89 F1 48 89 FA E8 ?? ?? ?? ?? 90 48 83 C4 28 5B 5F 5E 41 5E C3" - // FunctionOffsetSetFieldOfView: + // SetFieldOfView: // Camera: public void set_fieldOfView(float value) -> jmp xxxxxxxx - // FunctionOffsetSetTargetFrameRate: + // SetTargetFrameRate: // public static void set_targetFrameRate(int value) -> jmp xxxxxxxxx (to the end) - // FunctionOffsetSetEnableFogRendering: + // SetEnableFogRendering: // public static void set_enableFogRendering(bool value) -> jmp xxxxxxxxx (to the end) - // FunctionOffsetOpenTeam: FunctionOffsetOpenTeamPageAccordingly: GOD HELP US + // OpenTeam: OpenTeamPageAccordingly: CheckCanEnter GOD HELP US UnlockerIslandConfigurationWrapper wrapper = new() { Chinese = new() @@ -39,6 +39,7 @@ public void GenerateJson() SetEnableFogRendering = 0x013F6B00, OpenTeam = 0x08699B90, OpenTeamPageAccordingly = 0x08695AE0, + CheckCanEnter = 0x0724A030 }, Oversea = new() { @@ -50,6 +51,7 @@ public void GenerateJson() SetEnableFogRendering = 0x013FBA20, OpenTeam = 0x086A32A0, OpenTeamPageAccordingly = 0x086A4C60, + CheckCanEnter = 0x0711ED60 }, }; @@ -80,5 +82,7 @@ private sealed class UnlockerIslandFunctionOffset public required uint OpenTeam { get; set; } public required uint OpenTeamPageAccordingly { get; set; } + + public required uint CheckCanEnter { get; set; } } } \ No newline at end of file diff --git a/src/Snap.Hutao/Snap.Hutao/Model/Calculable/CalculableSkill.cs b/src/Snap.Hutao/Snap.Hutao/Model/Calculable/CalculableSkill.cs index bfc0a1a29..f5fb412bf 100644 --- a/src/Snap.Hutao/Snap.Hutao/Model/Calculable/CalculableSkill.cs +++ b/src/Snap.Hutao/Snap.Hutao/Model/Calculable/CalculableSkill.cs @@ -75,7 +75,7 @@ public static CalculableSkill From(SkillView source, SkillType type) return new(source, type); } - [MethodImpl(methodImplOptions: MethodImplOptions.AggressiveInlining)] + [MethodImpl(MethodImplOptions.AggressiveInlining)] private static string SettingKeyCurrentFromSkillType(SkillType type) { return type switch @@ -87,7 +87,7 @@ private static string SettingKeyCurrentFromSkillType(SkillType type) }; } - [MethodImpl(methodImplOptions: MethodImplOptions.AggressiveInlining)] + [MethodImpl(MethodImplOptions.AggressiveInlining)] private static string SettingKeyTargetFromSkillType(SkillType type) { return type switch diff --git a/src/Snap.Hutao/Snap.Hutao/Service/Feature/FeatureService.cs b/src/Snap.Hutao/Snap.Hutao/Service/Feature/FeatureService.cs index 1599e3cc8..55790eb6c 100644 --- a/src/Snap.Hutao/Snap.Hutao/Service/Feature/FeatureService.cs +++ b/src/Snap.Hutao/Snap.Hutao/Service/Feature/FeatureService.cs @@ -22,14 +22,6 @@ internal sealed partial class FeatureService : IFeatureService { using (IServiceScope scope = serviceScopeFactory.CreateScope()) { -#if DEBUG || IS_ALPHA_BUILD - // TODO: Remove this code block when we have a completed plan. - if (!scope.ServiceProvider.GetRequiredService().IsLicensedDeveloper) - { - return null; - } -#endif - IHttpClientFactory httpClientFactory = scope.ServiceProvider.GetRequiredService(); using (HttpClient httpClient = httpClientFactory.CreateClient(nameof(FeatureService))) { diff --git a/src/Snap.Hutao/Snap.Hutao/Service/Game/Unlocker/Island/IslandFunctionOffsets.cs b/src/Snap.Hutao/Snap.Hutao/Service/Game/Unlocker/Island/IslandFunctionOffsets.cs index fe313556d..a69cfb8cb 100644 --- a/src/Snap.Hutao/Snap.Hutao/Service/Game/Unlocker/Island/IslandFunctionOffsets.cs +++ b/src/Snap.Hutao/Snap.Hutao/Service/Game/Unlocker/Island/IslandFunctionOffsets.cs @@ -22,4 +22,6 @@ internal struct IslandFunctionOffsets public uint OpenTeam; [JsonInclude] public uint OpenTeamPageAccordingly; + [JsonInclude] + public uint CheckCanEnter; } \ No newline at end of file diff --git a/src/Snap.Hutao/Snap.Hutao/Snap.Hutao.csproj b/src/Snap.Hutao/Snap.Hutao/Snap.Hutao.csproj index 40c878a56..8c0f79302 100644 --- a/src/Snap.Hutao/Snap.Hutao/Snap.Hutao.csproj +++ b/src/Snap.Hutao/Snap.Hutao/Snap.Hutao.csproj @@ -327,7 +327,7 @@ all runtime; build; native; contentfiles; analyzers; buildtransitive - + all runtime; build; native; contentfiles; analyzers; buildtransitive