[L4D2] Model Precacher
by satannuts
About:
[L4D2] Model Precacher gives server admins the ability to precache select models on map start. This plugin is meant for servers that have any plugins installed that use z_spawn. You can control which group of models you want cached via convars: witch, survivors, weapons, and/or infected.
I wrote this shortly after the Passing update was released to help prevent some crashes I was having with my server.
I just noticed someone had recently released a similar plugin -
So I thought I'd share mine also - as I think it is a little nicer.
Usage:
Install plugin and load it once. A l4d2_model_precacher.cfg will be automatically created in your left4dead2\cfg\sourcemod folder. In the cfg file, you can change which group you would like to precache.
Cvars:
l4d2_precache_bill - (default 1) - Toggle precaching of Bill's model to prevent crashes caused by sb_add
l4d2_precache_survivors - (default 1) - Toggle precaching of survivor models to prevent crashes after the passing update
l4d2_precache_m60 - (default 1) - Toggle precaching of the m60 model to prevent crashes caused by z_spawn
l4d2_precache_cssweapons - (default 1) - Toggle precaching of css weapon models to prevent crashes caused by z_spawn
l4d2_precache_melee - (default 1) - Toggle precaching of melee weapon models to prevent crashes caused by z_spawn
l4d2_precache_misc - (default 1) - Toggle precaching of miscellaneous models to prevent crashes caused by z_spawn
l4d2_precache_tank - (default 1) - Toggle precaching of tank model to prevent crashes caused by z_spawn
l4d2_precache_witch - (default 1) - Toggle precaching of witch models to prevent crashes caused by z_spawn
l4d2_precache_infected - (default 1) - Toggle precaching of infected models to prevent crashes caused by z_spawn
Changelog:
- 1.666.1
- Corrected small typo - fixes compile error.
- 1.666
- Made a separate convar for Bill. ;)
- Added a few more models and convars for them..
Install
This plugin supports only L4D2.
You Can Either:
1-Place l4d2_model_precacher.smx in sourcemod/plugins.
2- Or compile l4d2_model_precacher.sp with your version of SM. And place the newly compiled l4d2_model_precacher.smx in sourcemod/plugins.
3- Or you can edit the .sp file to add more models if you prefer, which can then be compiled and used to your liking.
ENJOY!!