Jump to content
View in the app

A better way to browse. Learn more.

Forge Forums

A full-screen app on your home screen with push notifications, badges and more.

To install this app on iOS and iPadOS
  1. Tap the Share icon in Safari
  2. Scroll the menu and tap Add to Home Screen.
  3. Tap Add in the top-right corner.
To install this app on Android
  1. Tap the 3-dot menu (⋮) in the top-right corner of the browser.
  2. Tap Add to Home screen or Install app.
  3. Confirm by tapping Install.

Featured Replies

Posted

Hello, I was wondering how would I go about changing panorama in main menu. I know that there's no reason to mess with the main menu but this seems like a good example to learn how to change other data types than basic Java data types. I tried using

ObfuscationReflectionHelper#setPrivateValue

but it didn't work because "titlePanoramaPaths" (which I wanted to change to my own image) is "ResourceLocation[]". How can I do this?

 

It wants an array of ResourceLocations, so just give it that. If you don't know what a ResourceLocation is, read the docs.

I'm eager to learn and am prone to mistakes. Don't hesitate to tell me how I can improve.

6 minutes ago, imacatlolol said:

It wants an array of ResourceLocations, so just give it that. If you don't know what a ResourceLocation is, read the docs.

I know, I came up with this:

ResourceLocation[] background = new ResourceLocation[]{new ResourceLocation("mod/splash.png")};
ObfuscationReflectionHelper.setPrivateValue(GuiMainMenu.class, (GuiMainMenu) e.gui, background, "titlePanoramaPaths");

e is InitGuiEvent

"mod/splash.png" is in "assets/minecraft/mod/splash.png"

Edited by Vert3xo

GuiMainMenu is not a thing in modern Minecraft, and the version you're using is no longer supported. You need to update to 1.14/1.15.

I'm eager to learn and am prone to mistakes. Don't hesitate to tell me how I can improve.

3 minutes ago, imacatlolol said:

GuiMainMenu is not a thing in modern Minecraft, and the version you're using is no longer supported. You need to update to 1.14/1.15.

Do you have any example code for 1.15? Maybe I'll be able to then apply it to older versions myself.

  • Guest locked this topic
Guest
This topic is now closed to further replies.

Important Information

By using this site, you agree to our Terms of Use.

Configure browser push notifications

Chrome (Android)
  1. Tap the lock icon next to the address bar.
  2. Tap Permissions → Notifications.
  3. Adjust your preference.
Chrome (Desktop)
  1. Click the padlock icon in the address bar.
  2. Select Site settings.
  3. Find Notifications and adjust your preference.