View Single Post
Marcus101RR
Veteran Member
Join Date: Aug 2009
Location: Tampa, FL
Old 01-07-2012 , 16:12   Re: [L4D & L4D2] Health Cabinet (1.1) [31-Dec-2011]
Reply With Quote #9

Quote:
Originally Posted by Silvers View Post
Update: I am placing this here for now...


Good idea thanks MCFlurry. Also now spawns items when the Cabinet is opened, no longer will the bots grab before


Changed cvar:
"l4d_cabinet_type" - Chance out of 100 to spawn pills/adrenaline, remainder to spawn first aid kits/defibrillators.

Added 2 new cvars:
"l4d_cabinet_type1" - Chance out of 100 to select pills, remainder to select adrenaline.
"l4d_cabinet_type2" - Chance out of 100 to select first aid kits, remainder to select defibrillators.

You can specify what spawns. The type arguments below is exactly what the type cvars do. This is also applied to sm_cabinetsave (which is then saved to the data config for auto-spawning).

PHP Code:
sm_cabinet <type> <type1> <type2>

// Example: 
sm_cabinet 100 100    // Spawns only pills
sm_cabinet 100 1      // Spawns only adrenaline
sm_cabinet 50 1 1     // Spawns either adrenaline or defibrillators
sm_cabinet 50 100 100 // Spawns either pills or first aid kits
sm_cabinet 50 50 100  // Spawns either pills, adrenaline or first aid kits 
Sorry if this is confusing, I don't know a better way to do this or explain.
very confusing to be honest. would be better if you could make it a bit more easier...

sm_cabinetsave <medkits> <pills> <adrenaline> <defib>

0 = Never spawns
1 = Spawns

Considering the last plugin had a variable that controlled the percent...you could also do:

0 = Never/Zero Spawns
1 = 1 of Item Spawns
2 = 2 of Item Spawns
3 = 3 of Item Spawns
4 = 4 of Item Spawns

Example:
sm_cabinetsave <medkits> <pills> <adrenaline> <defib>
sm_cabinetsave 2 0 1 1

This cabinet spawns 2 Medkits, 0 pills, 1 adrenaline, and 1 debif always.
Marcus101RR is offline
Send a message via AIM to Marcus101RR Send a message via Skype™ to Marcus101RR