AlliedModders (
-   Plugins (
-   -   [L4D & L4D2] Auto Infected Spawner (

Tordecybombo 10-06-2009 23:02

[L4D & L4D2] Auto Infected Spawner
2 Attachment(s)
This is my first plugin. :)

I wanted some way to keep pummeling survivors with special infected while making some special infected spawn more often than others (since I loved killing lots of boomers, I wanted boomers to spawn much more often than smokers and hunters). I decided to make this plugin when other plugins and built-in cvars didn't spawn infected exactly how I wanted.


Manages its own system of automatic infected spawning. Change a specific special infected's chance of spawn by changing its weight. The higher the weight, the higher the chance it spawns, vice versa.

- The probability of a special infected spawning is (its weight)/(sum of all weights).
- The plugin for now can spawn upto 14 special infected (excluding witch) at once.
- Tank can have an exception of having -1 weight, which isn't factored into the weight sum. Instead, the director manages the spawning of the tanks (i.e. lottery system at each checkpoint).
- Witches aren't considered in these weights since they're the only non-playable special infected. Witches have their own spawning system. A setting of -1 on the witch limit cvar is director handled.
- Randomized spawn time mode: random spawn time between min and max spawn time
- Incremental spawn time mode: spawn time slows down as there are more special infected on the map at once; speeds up when there are less special infected
- Decremental spawn time mode: spawn time speeds up as there are more special infected; slows down when there are less special infected
- Constant witch spawn time mode: one witch spawns at the end of a witch spawn time interval
- Variable witch spawn time mode: one witch spawns anytime within a witch spawn time interval

If you don't want the settings to reset every map change, edit the cvars in the automatically generated l4d_autoSI.cfg at the cfg/sourcemod directory.

l4d_ais_version - Auto Infected Spawner Version
l4d_ais_enabled - "1" - Disable/Enable functionality of the plugin
l4d_ais_disable_in_versus - "1" - Automatically disable plugin in versus mode
l4d_ais_fast_response - "0" - Disable/Enable faster special infected response
l4d_ais_fast_spawn - "0" - Disable/Enable faster special infected spawn (Enable when SI spawn rate is high)
l4d_ais_safe_spawn - "0" - Disable/Enable special infected spawning while survivors are in safe room
l4d_ais_boomer_weight - "100" - The weight for a boomer spawning
l4d_ais_hunter_weight - "100" - The weight for a hunter spawning
l4d_ais_smoker_weight - "100" - The weight for a smoker spawning
l4d_ais_tank_weight - "-1" - The weight for a tank spawning [-1 = Director spawns tanks]
t - "-1" - The max amount of witches present at once (independant of l4d_ais_limit) [-1 = Director spawns witches]
l4d_ais_witch_period - "300.0" - The time (seconds) interval in which exactly one witch will spawn
l4d_ais_witch_period_mode - "1" - The witch spawn rate consistency [0 = CONSTANT | 1 = VARIABLE]
l4d_ais_limit - "3" - The max amount of special infected at once
l4d_ais_spawn_size - "1" - The amount of special infected spawned at each spawn interval
l4d_ais_time_mode - "1" - The spawn time mode [0 = RANDOMIZED | 1 = INCREMENTAL | 2 = DECREMENTAL]
l4d_ais_time_min - "0.0" - The minimum auto spawn time (seconds) for infected
l4d_ais_time_max - "60.0" - The maximum auto spawn time (seconds) for infected

l4d_ais_reset - Reset by slaying all special infected and restarting the timer
l4d_ais_start - Manually start the spawn timer
l4d_ais_time - Set a constant spawn time (seconds) by setting l4d_ais_time_min and l4d_ais_time_max to the same value
l4d_ais_preset - Set spawn weights to given presets <default|none|boomer|smoker|hunter|tank>

- It might conflict with other spawn plugins, such as infectedbots. I put a cvar that automatically disables the plugin in versus.
- Possible conflict with Kigen's anticheat since this plugin uses the z_spawn cheat

djromero for laying the foundation of the infected bots plugin.
mi123645 for letting me use some code from his infectedbots plugin.
FuzzOne and TacKLER for porting this plugin to L4D2.
Munch for updating plugin for L4D2

1.0.0 - Initial release (l4d_autoIS)

L4D1 version: l4d_autoIS
L4D2 version: l4d2_autoIS

uriel18 10-07-2009 10:02

Re: [L4D] Auto Infected Spawner
Thx dude, i will try.

Stormhold 10-18-2009 09:49

Re: [L4D] Auto Infected Spawner
Sounds interesting... Wonder if it will fit with l4100. I'll try this mod and coment, but maybe not today.

LTR.2 10-18-2009 12:21

Re: [L4D] Auto Infected Spawner
this could fix that glicth that makes a entire team have 4 hunters.

however, too bad it doesn't work with mi123456's plugin =S

any plans to fix that in the future?

mi123645 10-18-2009 22:03

Re: [L4D] Auto Infected Spawner
Very impressive work, Tordecybombo. The use of weights to determine the chance of an infected spawning is very interesting. Once again, kudos.

dave_with_beer_bottle 10-20-2009 07:29

Re: [L4D] Auto Infected Spawner
hi Tordecybombo,
i was just wonder if you could help me little with this,because i can't get it ,don't even know if its possible
how can i set 3 boomers,2 smokers and 4 hunters come at us at same time,lets say like every 15 sec
+ 2 tanks and 3 witches whenever tank or witch is spawned
thanks in advanced

Tordecybombo 10-20-2009 08:59

Re: [L4D] Auto Infected Spawner
not possible yet but it should work after I add limit functionality for each specific special infected

leonil7 10-29-2009 18:20

Re: [L4D] Auto Infected Spawner
great plugin. thanks!

Grass 10-30-2009 13:01

Re: [L4D] Auto Infected Spawner
works great in co-op but messes up infected spawn in versus can this be fixed? People get stuck in spawn mode and can't spawn. My server did it after i put this plug in on it and after that i took it off and works great. hope it can be fixed great plug in.

leonil7 11-01-2009 19:14

Re: [L4D] Auto Infected Spawner
works with multitank plugin at COOP games but messes at the rescue maps. tanks will not spawn at finale.
and most of all, server crashes many times.

its probably due to the conflict between tank and special spawns.

All times are GMT -4. The time now is 05:45.

Powered by vBulletin®
Copyright ©2000 - 2019, vBulletin Solutions, Inc.