Allows plugin developers and server administrators to categorize files and make them optional downloads.
I originally wrote this to work with a server that had tons of optional sound downloads (specifically music during humiliation), but it can be useful to make any downloads opt-in (like gee, what am I supposed to do with all these Quake Sounds).
There's still a bit more to improve on to make it easily accessible to non-developers, and there's a few improvements for efficiency and stability (no control over which plugins have control over which categories yet, have to do a query for every preference instead of caching it meaning no equivalent to OnClientCookiesCached(), eugh), but I think it's in a relatively good enough state to do an alpha for. I mean, it doesn't burst into flames.
- SourceMod's SQLite Driver, preferably.
- A PHP installation, SQLite3 support, and a supported web server with the ability to use rewrite rules. (This does not necessarily have to be the same as your fast download server.)
- There is very little support for a non-developer to add files to categories. Though if you know SQL, you can peek at the init script and work off of that.
- There needs to be a plugin registering a category for it to be accessible. It sounds silly, but there is no functionality to iterate through categories that exist in the database but have not been used by a plugin. Specifically, this affects the included menu plugin. One workaround is to compile the included empty_downloadprefs example plugin with your specific categories.
- TF2 says that the file is "downloading", though it'll keep chugging along and files actually won't be downloaded as appropriate. Something I can't really fix. (Unless someone's figured out how to modify stringtables before transmission, in which case we can just take out the PHP bit entirely.)
- It's written for 1.6, and you have to compile it yourself. Gasp. I have no idea how to transitional syntax.
Source code (ZIP)| Include
Wyświetl pełny artykuł