added Error screen for Bedrock authentication

This commit is contained in:
FlorianMichael 2023-03-20 17:37:41 +01:00
parent 1d24260638
commit 1ac8d9fb18
2 changed files with 5 additions and 1 deletions

View File

@ -50,6 +50,9 @@ public class BedrockSettings extends SettingGroup {
Util.getOperatingSystem().open(new URI(msaDeviceCode.verificationUri())); Util.getOperatingSystem().open(new URI(msaDeviceCode.verificationUri()));
} catch (URISyntaxException e) { } catch (URISyntaxException e) {
e.printStackTrace(); e.printStackTrace();
MinecraftClient.getInstance().execute(() -> MinecraftClient.getInstance().setScreen(new NoticeScreen(() -> {
Thread.currentThread().interrupt();
}, Text.literal("Microsoft Bedrock login"), Text.translatable("bedrocklogin.viafabricplus.error"), Text.translatable("words.viafabricplus.cancel"), false)));
} }
})); }));
ProtocolSelectionScreen.open(new MultiplayerScreen(new TitleScreen())); ProtocolSelectionScreen.open(new MultiplayerScreen(new TitleScreen()));

View File

@ -46,5 +46,6 @@
"visual.viafabricplus.classic": "Replace creative inventory", "visual.viafabricplus.classic": "Replace creative inventory",
"visual.viafabricplus.walkanimation": "Old walking animation", "visual.viafabricplus.walkanimation": "Old walking animation",
"bedrocklogin.viafabricplus.text": "Your browser should have opened.\nPlease enter the following Code: %s\nClosing this screen will cancel the process!" "bedrocklogin.viafabricplus.text": "Your browser should have opened.\nPlease enter the following Code: %s\nClosing this screen will cancel the process!",
"bedrocklogin.viafabricplus.error": "An error has occurred! See the latest.log for more information,\nplease report the bug at: \nhttps://github.com/FlorianMichael/ViaFabricPlus/issues"
} }