Posted March 29, 20169 yr I have a button on my Custom GUI that goes to a website, but it opens the "Are you sure you want to visit this link" message: public void actionPerformed(GuiButton button) { if (button.id == 1) { Minecraft.getMinecraft().displayGuiScreen(new GuiMainMenuHome()); } //DISPLAY UPDATES if (button.id == 10) { Minecraft.getMinecraft().displayGuiScreen(new GuiMainMenuUpdates()); } if (button.id == 2) { Minecraft.getMinecraft().displayGuiScreen(new GuiMainMenuPlay()); } if (button.id == 25565) { Minecraft.getMinecraft().displayGuiScreen(new GuiConnecting(this, mc, MainMenu.instance.IP, MainMenu.instance.PORT)); } //DISPLAY NEWS if (button.id == 11) { guiContainerDisplayText.setContent(MainMenu.instance.news.getNews()); } if (button.id == 3) { Minecraft.getMinecraft().displayGuiScreen(new GuiConfirmOpenLink(this, URL, 20, true)); } if (button.id == { Minecraft.getMinecraft().displayGuiScreen(new GuiConfirmOpenLink(this, URL2, 22, true)); } if (button.id == 5) { Minecraft.getMinecraft().displayGuiScreen(new GuiOptions(this, mc.gameSettings)); } if (button.id == 6) { Minecraft.getMinecraft().shutdown(); } } The "URL" and "URL2" are the links Strings, anyone know what GUI I should go to instead of ConfirmOpenLink http://i.imgur.com/vmqyxTE.png[/img]
March 29, 20169 yr Look at how GuiScreen#openWebLink opens the URI it's given. Please don't PM me to ask for help. Asking your question in a public thread preserves it for people who are having the same problem in the future.
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.