I need help with a mod I am currently coding. This mod will allow the main menu to be changed in a way to allow all options (sp, mp, options...) to be placed to the left, and then a "News" section to be placed to the right. Underneath the news section will be (obviously) news. If you click on the button, you will be brought to a new page, that will take about the topics in more detail. There is a picture below demonstrating how this will work.
EXAMPLE:
Mod so far:
Code so far (in guimainmenu.java):
StringTranslate stringtranslate = StringTranslate.getInstance();
int i = height / 4 + 48;
controlList.add(new GuiButton(1, width / 3 - 100, i, stringtranslate.translateKey("menu.singleplayer")));
controlList.add(multiplayerButton = new GuiButton(2, width / 3 - 100, i + 24, stringtranslate.translateKey("menu.multiplayer")));
controlList.add(new GuiButton(3, width / 3 - 100, i + 48, stringtranslate.translateKey("menu.mods")));
controlList.add(new GuiButton(3, width / 2 + 30, i + 1, 30, 72, stringtranslate.translateKey("News")));
if(mc.hideQuitButton)
{
controlList.add(new GuiButton(0, width / 3 - 100, i + 72, stringtranslate.translateKey("menu.options")));
} else
What I need help with:
In the second picture the news section is totally messed up, I need help with two things:
1. I need to know how to re-size the main menu buttons (sp, mp, etc.)
2. I also need to know how to positions the news button correctly so that the button will be to the right of the other buttons, the length will be the same as the other buttons, but the height will be as big as all of the buttons combined (from sp to options will be the height.) The last thing for this part is to make the white part of the button go away.
Thank you for all of your help in advance. :smile.gif:
I need help with a mod I am currently coding. This mod will allow the main menu to be changed in a way to allow all options (sp, mp, options...) to be placed to the left, and then a "News" section to be placed to the right. Underneath the news section will be (obviously) news. If you click on the button, you will be brought to a new page, that will take about the topics in more detail. There is a picture below demonstrating how this will work.
EXAMPLE:
Mod so far:
Code so far (in guimainmenu.java):
StringTranslate stringtranslate = StringTranslate.getInstance();
int i = height / 4 + 48;
controlList.add(new GuiButton(1, width / 3 - 100, i, stringtranslate.translateKey("menu.singleplayer")));
controlList.add(multiplayerButton = new GuiButton(2, width / 3 - 100, i + 24, stringtranslate.translateKey("menu.multiplayer")));
controlList.add(new GuiButton(3, width / 3 - 100, i + 48, stringtranslate.translateKey("menu.mods")));
controlList.add(new GuiButton(3, width / 2 + 30, i + 1, 30, 72, stringtranslate.translateKey("News")));
if(mc.hideQuitButton)
{
controlList.add(new GuiButton(0, width / 3 - 100, i + 72, stringtranslate.translateKey("menu.options")));
} else
What I need help with:
In the second picture the news section is totally messed up, I need help with two things:
1. I need to know how to re-size the main menu buttons (sp, mp, etc.)
2. I also need to know how to positions the news button correctly so that the button will be to the right of the other buttons, the length will be the same as the other buttons, but the height will be as big as all of the buttons combined (from sp to options will be the height.) The last thing for this part is to make the white part of the button go away.
Thank you for all of your help in advance. :smile.gif: