Skip to content

2. Configuration Guide

Corey D edited this page Oct 18, 2022 · 8 revisions

How to configure Ultra-VIP

This guide will first explain some important information about how the plugin works and then will explain the details about how to configure Ultra-VIP.

The text below is just a more detailed version of the documentation included in the Ultra-VIP main config file addons/sourcemod/configs/ultra_vip_main.cfg.


Where are the settings I'm looking for?

The config file has 2 main sections:

Section Description
Global configuration Settings for the whole plugin. These affect every service. These are right at the top below the big documentation comment.
Services A list of each service that can be given to players and its settings.

What is a "service"?

A "service" is what Ultra-VIP calls a group of settings that can be applied to a player.
Think of them as groups of bonuses (similar to how discord roles are groups of different permissions, if that is clearer).

A service is automatically given to a player if they have the required admin permissions.
The plugin supports an unlimited number of services, but players can only have access to 1 at a time.

Services can be assigned to players using any of the following:

  1. Admin Flags (Legacy permission system)
  2. Admin Overrides (Group permission system)
  3. Manually assigning to a Steam ID.

Pick any combination of these you prefer to use for your server.

If a player has access to more than one service, they will only get whichever service has the higher "priority" setting.

Adding a service

In the config file you will see a section like:

"Services"
{
   // list of services in here
}

Add a new service by copying this example service template OR this minimal service template (same thing but without comments) into where it says // list of services in here.

Make sure to add it onto the end of the list if you already have other services there, like this

"Services"
{
    ////////////////////////////////
    // VIP
    ////////////////////////////////

    "VIP"
    {
        // VIP Settings
    }

    ////////////////////////////////
    // END OF VIP SETTINGS
    ////////////////////////////////

    ////////////////////////////////
    // Super-VIP
    ////////////////////////////////

    "Super-VIP"
    {
        // Super-VIP Settings
    }

    ////////////////////////////////
    // END OF Super-VIP SETTINGS
    ////////////////////////////////
}

The large comments with //// are to make scrolling through the file easier. They're completely optional.

Be sure to configure the name of the service as well as the chat tags in the Main Configuration!

Inheriting Services

To make it easier to create multiple services, a service can "inherit" (copy) all of the settings from another service. Allowing you to only change the values that are different between them.

The only settings that are always required are:

  • "service_enabled"
  • "flag" (if original service has it set)
  • "override" (if original service has it set)

To inherit a service, simply add the following into the "Main Configuration" section:

"inherit_from_service"      "Name of original service"

Example:

"Admin"
{
    "Main Configuration"
    {
        "inherit_from_service"  "VIP"
        "service_enabled"       "1"

        "flag"                  "b"

        "scoreboard_tag"        "[Admin]"
    }
}

Rounds

Features can be enabled by a specific round. The number always refers to the rounds since the start of the half, with "1" being the pistol round.

Round numbers can also use the following special values:

Special Value Description
"WARMUP ONLY" Enable only during warmup.
"MATCH POINT" Enable when the game is at match point.
"PISTOL ROUND" Enable only during the first round of each half.
"LAST OF HALF" Enable only during the last round of a half.

Root Admin

Root admins will not get any service unless the root_service setting is set (in the Global Configuration section).

Chat Colors

Some features will say they support chat colors. This is the list of colours that are supported:

Color Codes
{default} {darkred} {green} {lightgreen}
{red} {blue} {olive} {lime}
{lightred} {purple} {grey} {yellow}
{orange} {bluegrey} {lightblue} {darkblue}
{grey2} {orchid} {lightred2}


Configuring a Service

For the most part, configuring each setting is explained by the default config file.

There are a few things to know:

  • Each section must exist for every service.
  • Each setting can be left out which will use the same values as the default config (it's recommended to not do this and just leave the settings in the file so you know what value is being used).
  • A lot of settings have a _round setting which just controls which round the bonus starts applying on (and after).
  • All of the comments (everything after a // in the file) are optional and can be removed if you think they make the file too hard to read.

The rest of this section will explain any important details for each section of the config file.
If you're not sure what it's talking about then use your brain a little bit and look at the default config file for reference.


Main Configuration

The most important settings are setting_enabled, flag and override, which are the main settings used to give out services to a player.

SteamID Access can also be used to give out a service but it is not recommended (except for specific cases such as giving it to an admin manually).

chat_name_color is currently the only setting that supports the {teamcolor} color code.


Player Spawn Bonuses

This section is for bonuses that apply to a player when they spawn.

player_max_hp only controls how the max HP given by Ultra-VIP and does not set the players actual max HP.


Grenades On Spawn

This section sets the number of grenades given to the player when they spawn.
This number obeys the grenade limit ConVars and wont give more than the player can hold (otherwise the extra grenades will drop onto the ground).

In the Global Configuration section (before the services in the config) you can set "fix_grenade_limits" to "1" to allow Ultra-VIP to automatically let all players hold enough grenades to fit whatever you set in the config file.

By all players, that is including players without any service.

"strip_grenades" can be set to "1" to reset the grenades a player is holding when they spawn, forcing them to have the exact loadout you choose in the config file.

Both bump mines and breach charges are limited to 32 each to avoid entity limit problems.


Special Bonuses

This section is for bonuses that aren't applied when spawning.
Nothing else to say, really.


Events Bonuses

This section controls the money/HP given to players when performing certain actions (different kinds of kills or objectives).
Set the values (or the _round settings) to 0 to disable the rewards.


Welcome/Leave Messages

This section sets any announcement messages to the server when a player with the service connects/disconnects.
Messages can be in the chat (with color support) or as a HUD message.

HUD positions (either X or Y) each range from 0.0 to 1.0, with -1.0 being a special value for the center.


Weapons Menu

The Advanced Weapons Menu section has a terrible name because it's not that complicated. Its structure looks like this:

"Advanced Weapons Menu"
{
    "menu_display_time"           "30"  // For how long weapon menu should be displayed for player (0 = forever).
    "menu_block_outside_buyzone"  "0"   // Prevent players from using the weapon menu outside of the buy zone (1 = Yes | 0 = No).   

    "Rifles"
    {
        "rifles_menu_enabled"       "1" // Enable the "Rifles" menu.
        "rifles_menu_round"         "3" // The first round that the "Rifles" menu displays.

        "➣ AK-47"
        {
            "weapon_entity"     "weapon_ak47"
            "team"              "T"
            "price"             "0"
        }

        // More rifles here

    }

    "Pistols"
    {
        "pistols_menu_enabled"      "1" // Enable the "Pistols" menu.
        "pistols_menu_round"        "1" // The first round that the "Pistols" menu displays.

        "➣ DEAGLE"
        {
            "weapon_entity"     "weapon_deagle"
            "team"              ""
            "price"             "0"
        }

        // More pistols here

    }
}

Each menu can be set to become available on a different round.
Add a weapon to either "Rifles" or "Pistols" depending on when you want the weapon to be select-able.

The team that can select the weapon, and the price the player must pay for the weapon (if any; use 0 to make it free) can be set per-weapon.

A few very important things to be aware of:

  • Any valid weapon entity classname (starting with weapon_) can be added to the menu.
  • The name of the weapon on the menu can be anything you want, but because of Valve's KeyValues logic you may have issues with capital letters not displaying properly (unless you add a decorator to the name like )
  • You can add any weapons to either menu, but you currently cannot add the same weapon to both menus (issue #1).

Configuring a Module

Please see the module configuration guide.
I promise it's much shorter than this one ;)