For Starters: To make sure everything goes fine, we are going to make sure menufile is new one and not raw one. First: Copy paste main.menu from raw/ui folder to mods/mapname/ui folder (if you don't have this folder, then create it) Second: Rename it to something new, like hit_main.menu. Third: Call it in mod.csv via: Now that we have new menufile only mod-related, we can start modifying it. HOX: Sometimes, when menufile is in mods folder, it doesn't let you save it. Just copy paste the file in desktop, do modifications, save and then put it back to the mods folder. Also, build mod twice, when doing modifications to menufiles. Usually menufile changes don't get build in mod the first time, so second one is needed.
Removing Buttons: Let's look up how to remove credits button as a starter. At about 1/3rd of the menufile, you will see these lines:
You can see line 474 and 475 have stuff related to credits. Comment them out, so they look like this: But if you were to compile now and go in-game, you would leave a gap between Quit and Mods buttons. What you have to do is to change the first value of Quit button. Credits uses number 8 and Quit uses number 9, so we change 9 to 8: The number is basically the button slot, so the smaller the value = the more up it is.
Fixing Alien Font: You probably will get Alien Font, when installing a font due to objectivefont not being loaded in by World At War. To fix this, first look up For Starters-section for copying the necessary menufiles. Go through menufiles and look for: Change that to: After that, save and you should be done.
Adding Background: Now, in raw/ui, there is a file called bg.inc. Take that and do 1st step. Open the file and look for: Change that to your background image, for example: Then in bg.inc file, remove these 2 lines: Then in Asset Manager, you need to convert material with power of 2 image. This images type has to be set to 2D, so that it works in menufiles. Example:
When that is done, move the image in modname/images, tick in Launcher and add this in mod.csv: Now to apply it in mainmenu. Open main.menu file we have created and look for: Change the bg.inc to your menufile, for example: Now to add the file in mod.csv, you do: HOX: To have background in all pages of your menu, then you need to go in several menufiles and add that include line. Maybe in later date I will add all the files to modify.
If done all the steps as shown, you can have menu looking like this:
Errors And How To Fix: (!) UNRECOVERABLE ERROR: duplicate menu name 'main' -You have menufile added in twice in mod.csv, remove the old line, since it's still calling in unmodified menufile.
More to come in later date. If you have something I should add, then ask. If I don't know how to add it, then help is appreciated Thanks to Andy Whelan for testing this tutorial and getting screenshot from in-game.
Are you kidding me after i spend all my time learning menus people make a menu tutorial anyways good tutorial havnt tried it out but looks like it would work
I tried but failed multiple times to put the actual bg. Am i supposed to have a textures.gdt file in the source_data? I tried to to put new asset in asset manager with the respective values show in the picture, them open my bg.dds but i failed. the backgound is just purple and green with withe squares. At least i managed to do the first part of the tutorial thx.