From Garry's Mod
Attempts to open a file with the given mode.
The mode to open the file in. Possible values are:
- r - read mode
- w - write mode
- a - append mode
- rb - binary read mode
- wb - binary write mode
- ab - binary append mode
The path type.
- "GAME" Structured like base folder (garrysmod/), searches all the mounted content (main folder, addons, mounted games etc)
- "LUA" or "lsv" - All Lua folders (lua/) including gamesmodes and addons
- "DATA" Data folder (garrysmod/data)
- "MOD" Strictly the game folder (garrysmod/), ignores mounting.
The opened file object, or nil if it failed to open due to it not existing or being used by another process.