Skip to content

Instantly share code, notes, and snippets.

@JJL772
Last active April 24, 2023 09:36
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save JJL772/8617ad988fdf54e26f69a73a6301ce49 to your computer and use it in GitHub Desktop.
Save JJL772/8617ad988fdf54e26f69a73a6301ce49 to your computer and use it in GitHub Desktop.
Generic mod config
addonsystem:
- handle mounting/unmounting of addons
- download/upload of UGC files
- mounting/unmounting of games too?
// Goals:
// - Common config configuring mod search paths, game data, instance paths and workshop settings
// - Use modern keyvalues3 syntax
// - Config should work for non-workshop mods and custom folder mods
{
mod = "Portal 2: CE"
id = 1234 // Workshop ID of the mod, If 0, none. (Default: 0)
// Short description (Default: "")
description = "Portal 2 on Chaos Engine with various enhancements"
// List of authors. (Default: [])
authors =
[
"Chaos Initiative"
]
// Paths to the output directories for everything. These are defaults but may be overridden
asset_paths =
{
materials = "materials"
models = "models"
maps = "maps"
}
// All instance paths, default just includes the root one
instance_paths =
[
"${root}/sdk_content/instances", // ${root} == P2CE install dir
"instances" // This is relative to the directory where this file lives
]
// Dependencies, either games or workshop items (Default: [])
dependencies =
[
"workshop:123456",
"game:440",
"game:320",
"game:220"
]
// Basically same as GameData in gameinfo but an array. (Default: [])
gamedata =
[
"p2ce.fgd", // Relative to this file
"${game:440}/bin/tf.fgd",
"${workshop:123456}/mymod.fgd"
]
// Workshop tags (Default: [])
tags =
[
"realism", "fun", "crap"
]
// Workshop mod type (Default: "map")
type = "campaign"
// Arbitrary info that may be attached to this addon. Can be read via API pretty easily.
metadata =
{
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment