Raised This Month: $32 Target: $400
 8% 

[Any] UMC Downloader ( v1.0.0 )


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Pheubel
New Member
Join Date: Jul 2021
Plugin ID:
7738
Plugin Version:
1.0.0
Plugin Category:
All
Plugin Game:
Any
Plugin Dependencies:
Servers with this Plugin:
 
Plugin Description:
A simple plugin that loads and precached files and directories based on UMC groups and map names.
Old 07-31-2021 , 06:44   [Any] UMC Downloader ( v1.0.0 )
Reply With Quote #1

By setting up download rules you can trim down the amount of files a client has to download when first visiting a server to the essentials for each group. It can recursively add files in directories by listing a directory path.

This plugin was inspired by SWAT_88's SM Downloader


Get the plugin: https://github.com/Pheubel/UMC-Downloader/releases
Source code hosted on github: https://github.com/Pheubel/UMC-Downloader



Setting up
  1. In order to set up this plugin on your server follow these steps:
  2. Download the plugin and put it in your plugins folder.
  3. Set up your "umc_mapcycle.txt" file with the groups you want.
  4. Create a file named "umc_downloader.json" in your game's root folder.
  5. Set up your "umc_downloader.json" file. Bellow is an example
Code:
{
    "always": {
        "sounds": [
            "sound/exampleSound.mp3",
        ],
        "models": [
            "models/exampleModels"
        ]
    },
    "groups": {
        "example group": {
            "files": [
                "exampleFile.txt"
            ]
        }
    },
    "maps": {
        "ctf_2fort": {
            "generic": [
                "genericCachedFile.txt"
            ],
            "decals": [
                "exampleDecals.vtf"
            ]
        }
    }
}
The structure works as follows:
In the top level you have 3 different categories: "always", "groups" and "maps".

"always" - Files and directories assigned here will be put in the downloads table no matter which map is selected.
"groups" - divides files and folders over UMC groups, for example "Dodgeball" or "prophunt", each would require their own set of files.
"maps" - With this category you can specify files to be put in the downloads table on a map by map basis.

There are 5 different categories your files can belong to:
  1. "files"
  2. "generic"
  3. "decals"
  4. "sounds"
  5. "models"

When files are listed under "files" they will not be precached.

Dependencies:

Suggesting features/reporting bugs:
If you want to suggest any features for this plugin or if you found any bugs caused by the plugin, you can create an issue ticket with details on this github page.
Attached Files
File Type: sp Get Plugin or Get Source (umc_downloader.sp - 86 views - 8.7 KB)
File Type: inc umc_downloader.inc (423 Bytes, 90 views)

Last edited by Pheubel; 07-31-2021 at 06:58. Reason: added section for feature request/bug reporting
Pheubel is offline
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 03:43.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode