answersLogoWhite

0


Best Answer

Goto:

http://wiki.garrysmod.com/?title=Add-On_Creation_%26_Folder_Structure#The_Info_File

OR Read The Simple Tutorial Below:

To create an addon for Garry's Mod, you need to place the relevent folders such as "lua", "settings", "maps", "materials" into a folder. The folder can be called anything, but a name that identifies the addon will help. You then need to create an addon information file. This can be done on any text editor but must be saved as "info.txt" and be placed in the root of the addon folder.

The Layout Of The Text Inside The File Is As Follows:

"AddonInfo"

{

"name" "<ADDON NAME>"

"version" "<ADDON VERSION>"

"author_name" "<ADDON AUTHOR'S NAME>"

"author_url" "<ADDON AUTHOR'S WEBSITE>"

"author_email" "<ADDON AUTHOR'S email ADDRESS>"

"info" "<DETAILS OF THE ADDON>"

"override" "<WHETHER THE ADDON WILL OVERRIDE ANOTHER ADDON OF THE SAME NAME, DELIMITED BY A "1" OR A "0".>"

}

NOTE: YOU DON'T NEED TO INLCUDE ALL OF THESE THINGS IN AN ADDON FILE. THE IMPORTANT ONES ARE:

-NAME

-VERSION

The rest can be left out, but it's better to complete all of the lines you can.

The "OVERRIDE" function can also be left out, because the default is 0.

Below is an example of an addon folder structure:

CAR MOD V6 (folder)¬

cfg (folder)

data (folder)

models (folder)

lua (folder)

materials (folder)

info.txt (file)

The "info.txt" file would look something like this:

"AddonInfo"

{

"name" "Car Mod"

"version" "6"

"author_name" "carcreator68"

"info" "THIS IS AN EXAMPLE FILE."

}

Ok Some Quick Rules TO Make Sure It Goes Well...

1) You MUST include the "AddonInfo" with capitals on the first line of the file.

2) You MUST include the { and } at the start and end of the info

3) The gaps between titles and values (e.g "name" and "Car Mod") can be as big or small, as long as they are at least one space. However, It helps to organize it like in the example above. The best way to do it is to use indents/tabs.

4) The Addon Folder (e.g Car Mod V6) must be placed in:

%STEAM FOLDER%\steamapps\%STEAM USERNAME%\garrysmod\garrysmod\addons

5) If you want to check the addon has been included in Garry's Mod, (i.e if it doesn't appear to be working) go to the Garry's Mod Main Menu And Click "Extensions". Then, find the tab that says "Addons" and a list of all the loaded addons will be displayed. The addon will be shown with the name that you typed in the "name" category in the "info.txt" file. (e.g Car Mod)

If you have followed the instructions correctly, and the mod itself works, it will be included in Garry's Mod.

IMPORTANT NOTE: MANY OF THE MODS YOU CAN DOWNLOAD FOR GARRY'S MOD COME COMPLETE IN ADDON FOLDERS.

User Avatar

Wiki User

14y ago
This answer is:
User Avatar

Add your answer:

Earn +20 pts
Q: How do you create an add-on file for Garry's Mod?
Write your answer...
Submit
Still have questions?
magnify glass
imp