Xcube-Studio / Natsurainko.FluentLauncher

Natsurainko.FluentLauncher A Minecraft launcher designed for Windows 11
https://fluentlauncher.natsurainko.work/
MIT License
290 stars 15 forks source link

[Bug] GameService.ActiveGameInfo 未修改导致的错误 #191

Closed vanja-san closed 11 months ago

vanja-san commented 12 months ago

Describe the bug

Bug 1: I click on "home." this error pops up.

Bug 2: I click on arrow to right above "Launch Minecraft".

Steps to reproduce the bug

Bug 1 and 2: Need to remove all cores.

Expected behavior

Actually nothing.

Environment

Windows 11 22H2 (22621.2428) FL 2.2.3.0

Attachment

Bug 1:

System.ArgumentException
System.ArgumentException: Not an game managed by GameService (Parameter 'gameInfo')
   at Natsurainko.FluentLauncher.Services.Launch.GameService.ActivateGameInfo(ExtendedGameInfo gameInfo)
   at Natsurainko.FluentLauncher.ViewModels.Home.HomeViewModel.OnPropertyChanged(PropertyChangedEventArgs e)
   at Natsurainko.FluentLauncher.ViewModels.Home.HomeViewModel.set_ActiveGameInfo(ExtendedGameInfo value)
   at Natsurainko.FluentLauncher.ViewModels.Home.HomeViewModel..ctor(GameService gameService, AccountService accountService, LaunchService launchService, INavigationService navigationService)
   at InvokeStub_HomeViewModel..ctor(Object, Object, IntPtr*)
   at System.Reflection.RuntimeConstructorInfo.Invoke(BindingFlags invokeAttr, Binder binder, Object[] parameters, CultureInfo culture)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitConstructor(ConstructorCallSite constructorCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.VisitDisposeCache(ServiceCallSite transientCallSite, RuntimeResolverContext context)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteVisitor`2.VisitCallSite(ServiceCallSite callSite, TArgument argument)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.CallSiteRuntimeResolver.Resolve(ServiceCallSite callSite, ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.DynamicServiceProviderEngine.<>c__DisplayClass2_0.<RealizeService>b__0(ServiceProviderEngineScope scope)
   at Microsoft.Extensions.DependencyInjection.ServiceProvider.GetService(Type serviceType, ServiceProviderEngineScope serviceProviderEngineScope)
   at Microsoft.Extensions.DependencyInjection.ServiceLookup.ServiceProviderEngineScope.GetService(Type serviceType)
   at Microsoft.Extensions.DependencyInjection.ServiceProviderServiceExtensions.GetRequiredService(IServiceProvider provider, Type serviceType)
   at Natsurainko.FluentLauncher.Services.UI.Navigation.NavigationService.ConfigureFrameContent(String key, Object parameter)
   at Natsurainko.FluentLauncher.Services.UI.Navigation.NavigationService.NavigateTo(String key, Object parameter)
   at Natsurainko.FluentLauncher.Views.ShellPage.NavigationViewControl_ItemInvoked(NavigationView _, NavigationViewItemInvokedEventArgs args)
   at WinRT._EventSource_global__Windows_Foundation_TypedEventHandler_global__Microsoft_UI_Xaml_Controls_NavigationView__global__Microsoft_UI_Xaml_Controls_NavigationViewItemInvokedEventArgs_.EventState.<GetEventInvoke>b__1_0(NavigationView sender, NavigationViewItemInvokedEventArgs args)
   at ABI.Windows.Foundation.TypedEventHandler`2.Do_Abi_Invoke[TSenderAbi,TResultAbi](Void* thisPtr, TSenderAbi sender, TResultAbi args)

Bug 2:

System.NullReferenceException
System.NullReferenceException: Object reference not set to an instance of an object.
   at Natsurainko.FluentLauncher.Views.Home.NewHomePage.Button_Click(Object sender, RoutedEventArgs e)
   at ABI.Microsoft.UI.Xaml.RoutedEventHandler.Do_Abi_Invoke(IntPtr thisPtr, IntPtr sender, IntPtr e)
natsurainko commented 12 months ago

fixed

vanja-san commented 12 months ago

@natsurainko please see my translation in FluentLauncher.LocalizationPoroject pull request #5

natsurainko commented 11 months ago

@natsurainko please see my translation in FluentLauncher.LocalizationPoroject pull request #5

OK, I will update the corresponding language files in the next version