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

[L4D/L4D2] Infected Ability Touch Hook | 1.3 : July 28, 2021 |


Post New Thread Reply   
 
Thread Tools Display Modes
Author
cravenge
Veteran Member
Join Date: Nov 2015
Location: Chocolate Factory
Plugin ID:
7585
Plugin Version:
1.3
Plugin Category:
Technical/Development
Plugin Game:
Left 4 Dead
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    Provides a forward to intercept actions regarding infected abilities.
    Old 04-02-2021 , 10:26   [L4D/L4D2] Infected Ability Touch Hook | 1.3 : July 28, 2021 |
    Reply With Quote #1

    Description:
    Hooks infected abilities and allows plugin developers to do whatever they want such as preventing other SIs interrupt Chargers carrying their victims, stopping Hunters from stealing another SI's victim when vomited, etc. However, said developers are still tasked to validate the ability's owner and the entity that it touches.

    ConVars:
    • infected_ability_touch_hook_version
      → Version of the plugin


    Forwards:

    PHP Code:
    forward Action OnAbilityTouch(const char[] abilityint abilityOwnerint &entity); 

    Installation:
    💡 *.smx goes into the plugins folder
    💡 *.sp goes into the scripting folder (only if you want to make changes to your liking)
    💡 *.inc goes into the include folder (inside scripting)
    💡 *.txt goes into the gamedata folder (optional since the plugin automatically makes one if missing)

    Requirements:
    ◉ SourceMod >= 1.10
    DHooks (Experimental Dynamic Detour support)
    Attached Files
    File Type: txt infected_ability_touch_hook.txt (492 Bytes, 183 views)
    File Type: sp Get Plugin or Get Source (infected_ability_touch_hook.sp - 178 views - 4.6 KB)
    File Type: smx infected_ability_touch_hook.smx (5.7 KB, 153 views)
    File Type: inc infected_ability_touch_hook.inc (831 Bytes, 143 views)

    Last edited by cravenge; 07-28-2021 at 04:36. Reason: More info
    cravenge is offline
    Dr. LightMare
    Junior Member
    Join Date: Oct 2017
    Old 04-05-2021 , 00:11   Re: [L4D2] Infected Ability Touch Hook | 1.01 : April 2, 2021 |
    Reply With Quote #2

    I'm pretty sure "ability_selfdestruct" is for the Leaker, when playing as him you can explode yourself with the primary attack. Anyways, great work!
    Dr. LightMare is offline
    Psyk0tik
    Veteran Member
    Join Date: May 2012
    Location: Homeless
    Old 04-05-2021 , 00:27   Re: [L4D2] Infected Ability Touch Hook | 1.01 : April 2, 2021 |
    Reply With Quote #3

    If you ever need help with L4D1 gamedata info, just let me know.
    PHP Code:
    "Games"
    {
        
    "#default"
        
    {
            
    "Functions"
            
    {
                
    "OnTouch"
                
    {
                    
    "offset"        "OnTouch"
                    "hooktype"        "entity"
                    "return"        "void"
                    "this"            "entity"
                    "arguments"
                    
    {
                        
    "a1"
                        
    {
                            
    "type"    "cbaseentity"
                        
    }
                    }
                }
            }
        }
        
    "left4dead"
        
    {
            
    "Offsets"
            
    {
                
    /* CBaseAbility::OnTouch(CBaseEntity*) */
                
    "OnTouch"
                
    {
                    
    "windows"    "200"
                    "linux"        "201"
                
    }
            }
        }
        
    "left4dead2"
        
    {
            
    "Offsets"
            
    {
                
    /* CBaseAbility::OnTouch(CBaseEntity*) */
                
    "OnTouch"
                
    {
                    
    "windows"    "215"
                    "linux"        "216"
                
    }
            }
        }

    Attached Files
    File Type: txt infected_ability_touch_hook.txt (584 Bytes, 103 views)
    __________________
    Psyk0tik is offline
    cravenge
    Veteran Member
    Join Date: Nov 2015
    Location: Chocolate Factory
    Old 04-05-2021 , 03:57   Re: [L4D2] Infected Ability Touch Hook | 1.1 : April 5, 2021 |
    Reply With Quote #4

    Updated!

    - Added support for L4D1. (Thanks Crasher!)
    Quote:
    Originally Posted by Crasher_3637 View Post
    If you ever need help with L4D1 gamedata info, just let me know.
    Alright.

    Last edited by cravenge; 04-05-2021 at 03:58.
    cravenge is offline
    Lux
    Veteran Member
    Join Date: Jan 2015
    Location: Cat
    Old 04-05-2021 , 20:49   Re: [L4D/L4D2] Infected Ability Touch Hook | 1.1 : April 5, 2021 |
    Reply With Quote #5

    This is great nice work.

    Also need to add it requires dhooks in op.
    __________________
    Connect
    My Plugins: KlickME
    [My GitHub]

    Commission me for L4D
    Lux is offline
    cravenge
    Veteran Member
    Join Date: Nov 2015
    Location: Chocolate Factory
    Old 04-30-2021 , 06:10   Re: [L4D/L4D2] Infected Ability Touch Hook | 1.1 : April 5, 2021 |
    Reply With Quote #6

    Updated!

    - Rewritten forward description to be clearer.
    - Made it so developers can change the entity being touched by an infected ability. Only tested with other entities that are in very close proximity to the original one.
    cravenge is offline
    cravenge
    Veteran Member
    Join Date: Nov 2015
    Location: Chocolate Factory
    Old 07-28-2021 , 04:39   Re: [L4D/L4D2] Infected Ability Touch Hook | 1.3 : July 28, 2021 |
    Reply With Quote #7

    Updated!

    - Limited the ability hooking to the tongue and the leap from now on.
    - Rewritten the include file to reflect the changes.
    - Other SIs require different hooks than the current one in order to achieve full control of their abilities. Please request if you want them to be added.
    cravenge 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 09:37.


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