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

[L4D1 & L4D2] Incapped Pills Pop


Post New Thread Reply   
 
Thread Tools Display Modes
Author
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Plugin ID:
7609
Plugin Version:
4.2
Plugin Category:
Gameplay
Plugin Game:
Left 4 Dead
Plugin Dependencies:
Servers with this Plugin:
12 
Plugin Description:
You can press the button while incapped / pwned to pop your pills / adrenaline / medkit and revive yourself
Old 04-22-2021 , 18:40   [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #1

Description:
Allows you to self-help (stand up) while:
  • incapacitated
  • hanging the ledge
  • captured by special infected
by pop the pills / adrenaline / medkit using one of the selected buttons: (JUMP), (CROUCH) or (USE).
Settings (ConVars):
Located at /cfg/sourcemod/l4d_incappedpillspop2.cfg
PHP Code:
// Enable this plugin? (1 - Yes, 0 - No)
l4d_incappedpillspop_enable "1"

// How long before an Incapped Survivor can use pills/adrenaline
l4d_incappedpillspop_delaytime "0.2"

// Forbid self-help when somebody reviving you (1 - Yes / 0 - No)
l4d_incappedpillspop_forbid_when_reviving "1"

// Disable heartbeat sound in game at all (1 - Disable / 0 - Do nothing)
l4d_disable_heartbeat "0"

// Show message to all about player selfhelp action (1 - Yes / 0 - No)
l4d_incappedpillspop_show_msg_all "1"

// Position of the selfhelp action message (0 - Don't show, 1 - Chat, 2 - Hint, 4 - Center screen (can be combined)
l4d_incappedpillspop_msg_pos "1"

// Position of advertise selfhelp keys message (0 - Don't show, 1 - Chat, 2 - Hint, 4 - Center screen (can be combined)
l4d_incappedpillspop_msgadvert_pos "1"

// Show warning messages, e.g. when you have no pills? (0 - No, 1 - Yes)
l4d_incappedpillspop_msg_warn "1"

// What button to press for self-help? 2 - Jump, 4 - Duck, 32 - Use. You can combine.
l4d_incappedpillspop_button "32"

// Allow to pop with these items from incap (0 - Don't allow, 1 - Medkit, 2 - Pills, 4 - Adrenaline (can be combined)
l4d_incappedpillspop_help_items "7"

// Allow to pop with these items from hangind the ledge (0 - Don't allow, 1 - Medkit, 2 - Pills, 4 - Adrenaline (can be combined)
l4d_incappedpillspop_help_ledge_items "7"

// Allow to release from infected with these items (0 - Don't allow, 1 - Medkit, 2 - Pills, 4 - Adrenaline (can be combined)
l4d_incappedpillspop_release_items "7" 
Requirements:
- SourceMod 1.10+
- DHook Detours Extension or SourceMod 1.11.0.6820+
- [L4D & L4D2] Heartbeat (Revive Fix - Post Revive Options) by Silvers
Translations
- English
- Russian
- Portuguese (thanks to @King_OXO)
- Chinese (thanks to @HarryPotter)
Compatibility
- L4D1
- L4D2
Credits:
- AtomicStryker - for the original idea and his plugin which was a basis for the very first fork.
- Pan XiaoHai - for some vector code snippets.
- Peace-Maker - for his DHook with detours support.
- Voevoda - for donation.
Related plugins:
- [L4D1] Health Exploit Fix by Dragokas
- [L4D1 & L4D2] Ledge Release by Dragokas
- [L4D, L4D2] No Death Check Until Dead by chinagreenelvis
ChangeLog
Spoiler


Donate
Donates are very appreciated and welcomed for further inspiration, make me happy, and make next updates came out more often:
- Patreon (Paypal)
- BitCoin
- Ю.Money
P.S.:
- Project and updates discontinued. Don't ask.
Attached Files
File Type: zip incappedpillspop_v4.X.zip (30.6 KB, 791 views)
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]

Last edited by Dragokas; 01-30-2024 at 02:42.
Dragokas is offline
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Old 04-22-2021 , 18:46   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #2

Latest changes:

Quote:
2.0 (23-Apr-2021)
- Improved music stop fix.
- Fixed bug: *_spawned classes: weapon_pain_pills_spawn and weapon_adrenaline_spawn are not checked on the floor.
- Improved bug-fix: other player could become frozen if you force pop pills while he tries to revive you.
- Prevented opportunity to use pills when been attacked by charger or jockey.
- Added missing ConVars for tracking the changes.
- Simplified & beautified the code, removed useless timers, Less useless hooks.
- Added ConVar "l4d_incappedpillspop_enable" - Enable this plugin? (1 - Yes, 0 - No).
- Added ConVar "l4d_incappedpillspop_button" - What button to press for self-help? 2 - Jump, 4 - Duck, 32 - Use. You can combine.
- Added ConVar "l4d_incappedpillspop_allow_adrenaline" - (L4D2 only) Allow pop adrenaline? (1 - Yes / 0 - No).
- Splitted messages:
* hint, when you incapacitated and when you hanging the ledge.
* hint, suggesting you to press the specific button to reflect the settings defined by ConVar.
* info, depending on whether somebody used his own pills or found them on the floor.
- New requirements:
* SourceMod 1.10+
* DHooks Detours v.2.2.0.15+
To make this update works properly, be sure to update the following plugins to the latest version (if you use them):
* Health Exploit Fix (for L4D1): https://forums.alliedmods.net/showthread.php?t=314573
* Ledge Release: https://forums.alliedmods.net/showthread.php?t=316508
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]

Last edited by Dragokas; 04-22-2021 at 18:48.
Dragokas is offline
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Old 04-25-2021 , 14:14   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #3

Updated.

Quote:
2.1 (25-Apr-2021)
- Fixed "l4d_incappedpillspop_enable" ConVar is not worked.
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]
Dragokas is offline
Voevoda
Senior Member
Join Date: Aug 2016
Old 05-10-2021 , 12:24   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #4

Hello, you can add a first aid kit
Voevoda is offline
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Old 05-11-2021 , 10:51   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #5

Maybe, but not for free. It requires a lot of changes.
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]
Dragokas is offline
Sev
Veteran Member
Join Date: May 2010
Old 05-11-2021 , 11:38   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #6

Would be useful for bots.
Sev is offline
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Old 05-29-2021 , 13:54   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #7

Updated.

Quote:
2.2 (11-May-2021)
- Added ability to use medkit (thanks to @Voevoda for donation).
- Added new ConVar "l4d_incappedpillspop_allow_medkit" - Allow stand-up with first aid kit? (1 - Yes / 0 - No)
- Added new ConVar "l4d_incappedpillspop_allow_pills" - Allow pop pills? (1 - Yes / 0 - No)
- Translation file is updated.
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]
Dragokas is offline
little_froy
Senior Member
Join Date: May 2021
Old 05-29-2021 , 14:08   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #8

more reasonable and more pure than my Incapacitated Automatic Regeneration and self Revive.
i try to enhance survivals a lot, but still always lose in versus
little_froy is offline
jking
AlliedModders Donor
Join Date: Jan 2012
Old 05-29-2021 , 14:29   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #9

Dragokas, this works fantastic but I noticed this error below (reproducible) though doesn't affect functionality:

Code:
L 05/29/2021 - 12:25:55: SourceMod error session started
L 05/29/2021 - 12:25:55: Info (map "c5m1_waterfront") (file "C:\L4D2\left4dead2\addons\sourcemod\logs\errors_20210529.log")
L 05/29/2021 - 12:25:55: [SM] Exception reported: Language phrase "NoPillsAdrenaline" not found (arg 4)
L 05/29/2021 - 12:25:55: [SM] Blaming: l4d_incappedpillspop.smx
L 05/29/2021 - 12:25:55: [SM] Call stack trace:
L 05/29/2021 - 12:25:55: [SM]   [0] VFormat
L 05/29/2021 - 12:25:55: [SM]   [1] Line 731, l4d_incappedpillspop.sp::CPrintToChat
L 05/29/2021 - 12:25:55: [SM]   [2] Line 609, l4d_incappedpillspop.sp::Timer_AdvertisePills

Last edited by jking; 05-29-2021 at 15:44.
jking is offline
Dragokas
Veteran Member
Join Date: Nov 2017
Location: Ukraine on fire
Old 05-29-2021 , 16:16   Re: [L4D1 & L4D2] Incapped Pills Pop
Reply With Quote #10

Thanks. I didn't test the latest update. I'll fix that tomorrow.
__________________
Expert of CMD/VBS/VB6. Malware analyst. L4D fun (Bloody Witch & FreeZone)
[My plugins] [My tools] [GitHub] [Articles] [HiJackThis+] [Donate]
Dragokas 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 05:47.


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