Garry's Mod

Garry's Mod

Not enough ratings
How to Use the GIMP to Make Custom Menu Backgrounds
By Doctor Timbrwulf
Hey there! Timbrwulf here! This time around, we're going to make it where you can make impressive custom backgrounds using a simple art program called the GIMP.

There are already plenty of guides out here that cover how to add backgrounds, but depending on what you import, images with different aspect ratios will make others look stretched or crushed, due to Garry's Mod trying to make all other images match the aspect ratio of the first one it loads. This also covers some basic techniques you can apply to make your backgrounds more impressive.

Before you guys point it out, yes, you can use most any artwork program you prefer to do these very things - I only show how to do it with the GIMP because it is completely free and popular in opensource communities.
   
Award
Favorite
Favorited
Unfavorite
Step One - Get What You Need
The GIMP is opensource, and it's completely free! You can download it directly from their website: https://www.gimp.org/downloads/

Then, you need to find an image that you want to use. It can be a family digital photo, an image from the internet, or just about anything that has the JPG or PNG extension or can be converted to that extension easily.

For the purpose of this guide, I will be using this wallpaper I currently use on one of the desktops on my computer:

Step Two - Find the Backgrounds
Find Garry's Mod in your Steam Library, and click on the gear icon.

Open the local files by going to the Installed Files tab, then go to "Browse".

Navigate to garrysmod/backgrounds. This is where most of the main menu backgrounds are stored.

Some are also located in the garrysmod/gamemodes/GAMEMODE/backgrounds folders, where GAMEMODE is the folder where a specific game mode installed on your system stores its files (for example, terrortown for Trouble in Terrorist Town).
Step Three - Resize the Backdrop with the GIMP
If your image matches your monitor resolution...
...Then all you need to do is copy the image to the appropriate backgrounds folder. Simple!

If your image DOESN'T match your monitor resolution...
Open up the GIMP and go to File > Open. Navigate to the folder where you put your image and open it.


Cropping
The most basic way to make the image fit is to go to Image > Canvas Size..., then set your monitor's pixel width and height. Move the rectangle in the viewer over the portion of the image you want to focus on, or hit "Center" to force the rectangle in the center of the image, then click "Resize".


Scaling
This method takes a little time, but can produce good results if done right.

Go to Image > Scale. Set the width property to your monitor's pixel width. Make sure the link icon shows that the two properties are linked, else it also won't change height. Click "Resize" when done.


Open up the Canvas Size dialog. Set your monitor's height and click the "Center" button, then "Resize".


Don't worry about invisible bars on the top and bottom! You could use this as an opportunity to add a border or other special effects, but for now, we're just going to fill the background with a solid color.


There should be a Layers box in the GIMP by default. Find it on one of the sidebars (you may have to click on its tab to focus it), then click the "New Layer" icon, which should look like a box with a plus sign on it.


Change the "Fill With" drop-down to either "Foreground Color" (black by default) or "Background Color" (white by default). Hit "OK".


Reorder the layers by dragging the new layer entry in the Layers box under the name of your image, and your picture should be on top of a solid color background!


Exporting
Choose File > Export As..., choose one of the backgrounds folders mentioned earlier, then save it with either a JPG (make sure Image Quality is set to 100) or PNG (recommended).
Bonus! - Manipulate the Background Animation Effects
If you really want your backgrounds to pop, you can do a little Lua programming without even knowing how! As long as you know which lines to mess with, you can make your own background animations.

To start, go to GAMEFOLDER/garrysmod/lua/menu/background.lua. I recommend opening it in a program like Bluefish, but you can also use a text editor, if you'd rather.

Hot Tip: Back up the original script before continuing, in case you break something and need to recover.

Find these lines near the end of the script (I've already modified mine, so the default values will be different):


Here are the properties you can mess around with:
  • Size changes the starting size of each background image. 1 is the default, but you can make it smaller or bigger depending on your preferences.
  • Angle changes the starting angle of each image. Default is 0.
  • AngleVel changes the speed of the angle. Default is -0.3 / 30 (approximately one-third over 30, or one-third divided by 30). It's a decimal number in a fraction because any whole number makes the images spin very fast. Negative values spin clockwise, positive values spin counter-clockwise. Experiment with different values to find a velocity that suits you.
  • SizeVel changes the speed of the zoom. Default is 0.3 / 30, because of the same issue as AngleVel. Negative values zoom the images out, and positive values zoom in.
  • Alpha adjusts the opacity of the images, from 0 for fully transparent to 255 for fully opaque. Default is 255.
  • DieTime is the duration, in seconds, each image is shown before it transitions to the next image. Default is 30.
Thank YOU for Reading This Guide!


Hopefully this guide does well in helping you make Garry's Mod more yours! I plan on making more "How To" guides like this, so everybody can take advantage of its moddable features!

Don't forget to like if this helped you, or disliked (let me know if you had issues from following this guide!), and favorite this guide for easy reference later!
4 Comments
Pyro Gaming (Alt Acc) 30 Jun @ 6:49am 
ok
Doctor Timbrwulf  [author] 30 Jun @ 5:31am 
Hence the complicated GIMP stuff.
Doctor Timbrwulf  [author] 30 Jun @ 5:30am 
@Pyro Gaming (Alt Acc) Well... obviously, this guide is not for everybody. That doesn't mean no one will make good use of it.

This is for people who care about images looking blurred or stretched in the game, just as I do. If it doesn't bother you, however, then just put whatever JPGs and PNGs in your backgrounds folder and ignore everything I wrote above. Plenty of guides say that already, though, so I thought I'd try a different approach.
Pyro Gaming (Alt Acc) 29 Jun @ 11:58am 
or... just put a screenshot or smth into the backgrounds folder. no need for complicated gimp stuff