Garry's Mod Wiki

File Search Paths

File Search Paths

File Search Paths

Here is a list of file search paths for use by the file library.

Search Path Description
"GAME" Structured like base folder (garrysmod/), searches all the mounted content (main folder, addons, mounted games, etc)
"LUA" All Lua folders (lua/) including gamemodes and addons
"lcl" All Lua files and subfolders (lua/) visible to the client state.
"lsv" All Lua files and subfolders (lua/) visible to the server state.
"LuaMenu" All Lua files and subfolders (lua/) visible to the menu state.
"DATA" Data folder (garrysmod/data)
"DOWNLOAD" Downloads folder (garrysmod/download/)
"MOD" Strictly the game folder (garrysmod/), ignores mounting.
"BASE_PATH" Location of the root folder (where hl2.exe, bin and etc. are)
"EXECUTABLE_PATH" Bin folder and root folder
"THIRDPARTY" Contains content from installed addons or gamemodes.
"WORKSHOP" Contains only the content from workshop addons. This includes all mounted .gma files.
<mounted folder> Strictly within the folder of a mounted game specified, e.g. "cstrike", see note below
<mounted Workshop addon title> Strictly within the specified Workshop addon. See engine.GetAddons.

Listing all active search paths in-game

Garry's Mod provide a useful command that lists all currently active search paths for the current game state: path

The command will out text like this:

--------------- Paths: --- ENGINECORE --- "path_to_folder1" "EXECUTABLE_PATH" "path_to_folder2" "BASE_PATH" "path_to_folder3" "GAMEBIN" "path_to_folder4" "LOGDIR" ... --- GAMECONTENT --- "path_to_vpk1" "GAME" (VPK) "path_to_vpk2" "hl2" (VPK) "path_to_vpk3" "GAME" (VPK) "path_to_vpk4" "cstrike" (VPK)

Each line will contain the real filesystem path and its Search Path designation that can be used with the file library.

This may also be useful for general debugging. Content from paths that appear first will override content from paths that appear last.

Special Pages



Render Time: 73ms

DB GetPage 22
Generate Html 5
SaveChanges (1) 35
Render Body 0
Render Sidebar 8