StrataSource / Portal-2-Community-Edition

Task tracker for Portal 2: Community Edition
https://www.portal2communityedition.com
146 stars 3 forks source link

Feature: [Workshop] Add ability to mount Steam games in `addon.kv` #1611

Open Equalizer5118 opened 7 months ago

Equalizer5118 commented 7 months ago

Which component should be improved?

Other

Describe your suggestion

This feature would enable addons to mount Steam games for custom content, and he structured in a similar way to mounts.kv, where there would be a specific section of the addons.kv file where the creator can specify the appid and folders/vpks to mount. E.G:

...
"Mounts"
{
    "####" 
    {
        "required"  "1" // If specified, the addon will not mount unless this game can be successfully mounted
        "name"      "Portal Reloaded" //used for mounting error
        "<folder name>"
            {
                "vpk" "..."
            }
        ...
    }
}

If required is set to 1, the game specified must be installed for the addon to mount. Otherwise, the addon will not mount and throw a warning on startup: Screenshot 2023-11-29 10 08 33 AM