Raised This Month: $51 Target: $400
 12% 

[L4D2] Defib using Bots (Updated 09-25-2020)


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author
DeathChaos25
Senior Member
Join Date: Jan 2014
Location: Puerto Rico
Plugin ID:
4607
Plugin Version:
1.5
Plugin Category:
Gameplay
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
    88 
    Plugin Description:
    This plugin has a customized AI behavior that allows Survivor bots to defib dead team mates
    Old 04-15-2015 , 15:41   [L4D2] Defib using Bots (Updated 09-25-2020)
    Reply With Quote #1

    About : Ever tired of dying, when a survivor bot has a defib, and the game just goes on without you because bots won't defib you? Well, No more!

    How it works :
    This plugin scans the map for any survivor death models, after it finds one, if certain criterias are met, a bot with a defib will then be forced to walk up to the dead body, then he is forced to aim at the dead body, take out his defib, and use +ATTACK to successfully defib a dead survivor.

    Video Demonstration here

    The criterias for bots to defib survivors are as following :
    1) There is distance limit, we don't want bots going halfway across the map just to defib one person
    2) No survivors must need help (IE Trapped by a SI, incapacitated or hanging from a ledge)
    3) There must be no visible threats to the survivor bots for them to accomplish this
    Spoiler


    Admin Commands (Added in Version 1.3 and 1.4, Root access required) :
    sm_regroup - Orders all survivor bots to regroup and move to where the person who issued this command is located
    sm_resetbots - Resets all bots and interrupts their current action.
    sm_retreat - Orders all survivor bots to retreat from the special infected you are currently aiming at
    sm_attack - Orders all survivor bots to focus and attack the special infected you are currently aiming at

    Note that these 2 commands also have the same limitations put into place as the defib usage on bots


    Code:
    Version 1.0    04-15-2015 (55 views)
    - Initial Release
    
    Version 1.1   04-16-2015 (16 views)
    - Improved the AI a bit
    - Fixed a bug where in certain situations the bots would shoot non stop
    
    Version 1.2   04-17-2015 (42 views)
    - Fixed an oversight where bots would never stop swinging melee weapons
    - Added defib tracking for bots into the plugin!
    
    Version 1.3  04-18-2015 (33 views)
    - Fixed an oversight where in certain odd conditions bots would not heal
    - Added 2 new admin commands to control bots! (Root access required)
    
    Version 1.4  04-19-2015 (99 views)
    - Fixed an Invalid Client Array Issue in a timer
    - Added sm_retreat and sm_attack admin commands
    
    Version 1.5  04-29-2015 (297 views)
    - Small Code Cleanup to make plugin more easily readble
    - Completely new system is being used for defib pickup (left4dowtown2 is needed for it to work!)
    - As a result, if the defib pickup function is desired, left4downtown2 is needed (Plugin will work without downtown, but bots will not pick up defibs)
    
    Version 1.6  06-24-2015 (15543 views)
    - Fixed a small oversight where bots would attempt to pick up a defib another person had already picked up, resulting in them never picking up any other defibs (thanks to yurikon for pointing it out!)
    
    Version 1.7  09-25-2020
    - Small update, completely removed code for bots picking up defibs that relied on Left4downtown, it is encouraged to run gear transfer instead.
    To DO :
    Code:
    - Requests(?)
    Thanks to dcx2 for suggesting "use weapon_defibrillator" !

    It is suggested you run Gear Transfer!

    If there is an instance where the bots go all dumb and defib people while ignoring zombies please let me know, as this shouldn't be the case.

    Attached Files
    File Type: sp Get Plugin or Get Source ([L4D2] Defib using bots.sp - 9772 views - 9.2 KB)
    __________________

    Last edited by DeathChaos25; 09-25-2020 at 02:58.
    DeathChaos25 is offline
     



    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 10:22.


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