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

[CS:GO] No Fall Damage (Updated: 02/16/2018)


Post New Thread Reply   
 
Thread Tools Display Modes
Author
NeoxX
AlliedModders Donor
Join Date: Jan 2014
Location: Germany
Plugin ID:
4710
Plugin Version:
1.0.1
Plugin Category:
Gameplay
Plugin Game:
Counter-Strike: GO
Plugin Dependencies:
    Servers with this Plugin:
     
    Plugin Description:
    No Falling Damage & No Fall Damage Sound
    Old 07-06-2015 , 08:53   [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #1

    Information:
    • Original No Fall Damage plugin from alexip121093
    • I found this code and have added this (Original Post)
    • You get no falling damage + You can don't hear a fall damage sound.

    Testet in [CS:GO] with
    Sourcemod 1.8 - build 6040 Linux
    Metamod:Source 1.10 - 961 Linux

    Requirements:
    SDKHooks
    SDKTools
    Compiler 1.8

    Changelog:
    Spoiler


    Installation:
    • Upload the addons file in your (csgo) folder.

    Have Fun
    Attached Files
    File Type: zip No-Fall-Damage.zip (5.7 KB, 6001 views)
    __________________

    Last edited by NeoxX; 02-16-2018 at 05:59. Reason: Updated: Syntax Removed: CS:S Support (I found no way to block the sound)
    NeoxX is offline
    Abusador
    Member
    Join Date: Sep 2015
    Old 06-22-2016 , 10:11   Re: [CS:S/CS:GO] No Fall Damage (07/06/2015)
    Reply With Quote #2

    Please, make no fall damage for only Terrorist, i need for my deathrun server.

    Thankz
    Abusador is offline
    xines
    Veteran Member
    Join Date: Aug 2013
    Location: Denmark
    Old 06-22-2016 , 11:42   Re: [CS:S/CS:GO] No Fall Damage (07/06/2015)
    Reply With Quote #3

    Quote:
    Originally Posted by Abusador View Post
    Please, make no fall damage for only Terrorist, i need for my deathrun server.

    Thankz
    Contact me, i'll do it for you
    __________________
    xines is offline
    Franc1sco
    Veteran Member
    Join Date: Oct 2010
    Location: Spain (Madrid)
    Old 06-22-2016 , 12:00   Re: [CS:S/CS:GO] No Fall Damage (07/06/2015)
    Reply With Quote #4

    Quote:
    Originally Posted by Abusador View Post
    Please, make no fall damage for only Terrorist, i need for my deathrun server.

    Thankz
    Easy to do, done
    Attached Files
    File Type: sp Get Plugin or Get Source (nofalldamage.sp - 1093 views - 1.1 KB)
    __________________
    Veteran Coder -> Activity channel
    Coding on CS2 and taking paid and free jobs.

    Contact: Steam, Telegram or discord ( franug ).

    You like my work? +Rep in my steam profile comments or donate.


    Last edited by Franc1sco; 06-22-2016 at 12:06. Reason: updated
    Franc1sco is offline
    Send a message via MSN to Franc1sco
    xines
    Veteran Member
    Join Date: Aug 2013
    Location: Denmark
    Old 06-22-2016 , 15:59   Re: [CS:S/CS:GO] No Fall Damage (07/06/2015)
    Reply With Quote #5

    Quote:
    Originally Posted by Franc1sco View Post
    Easy to do, done
    Yeah easy but ughh old syntax.

    Heres a transitional syntax updated version with some small changes:
    Attached Files
    File Type: sp Get Plugin or Get Source (nofalldamage.sp - 1612 views - 1.1 KB)
    __________________
    xines is offline
    eyal282
    Veteran Member
    Join Date: Aug 2011
    Old 10-30-2018 , 06:30   Re: [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #6

    Code:
    #pragma semicolon 1
    
    #include <sourcemod>
    #include <sdkhooks>
    #include <sdktools>
    #pragma newdecls required
    
    #define DMG_FALL   (1 << 5)
    
    public Plugin myinfo =  
    {
    	name = "[CS:GO] No Fall Damage",
    	author = "alexip121093 & Neoxx",
    	description = "No Falling Damage & No Fall Damage Sound",
    	version = "1.0.1",
    	url = "https://forums.alliedmods.net/showthread.php?p=2316188"
    }
    
    public void OnPluginStart() 
    {
    	AddNormalSoundHook(SoundHook);
    	
    	for(int i=1;i <= MaxClients;i++)
    	{
    		if(!IsClientInGame(i))
    			continue;
    			
    		SDKHook(i, SDKHook_OnTakeDamage, OnTakeDamage);
    	}
    }
    
    public void OnClientPutInServer(int client) 
    {
    	SDKHook(client, SDKHook_OnTakeDamage, OnTakeDamage);
    }
    
    public Action SoundHook(int clients[64], int &numClients, char sound[PLATFORM_MAX_PATH], int &entity, int &channel, float &volume, int &level, int &pitch, int &flags) 
    {
    	if(StrContains(sound, "player/damage", false) >= 0)
    		return Plugin_Handled;
    	
    	return Plugin_Continue;
    }
    
    public Action OnTakeDamage(int client, int &attacker, int &inflictor, float &damage, int &damagetype) 
    {
    	if (damagetype & DMG_FALL)
    	{
    		damage = 0.0;
    		return Plugin_Changed;
    	}
    	return Plugin_Continue;
    }
    I think setting damage to 0 removes a bug that makes the fun facts of the round say "%N took 500 damage from the earth"
    __________________
    I am available to make plugins for pay.

    Discord: Eyal282#1334
    eyal282 is offline
    aykocity
    Member
    Join Date: Sep 2017
    Old 04-03-2019 , 23:25   Re: [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #7

    can you use only a flag ?
    aykocity is offline
    paulo_crash
    AlliedModders Donor
    Join Date: May 2016
    Location: Brazil
    Old 06-08-2020 , 13:27   Re: [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #8

    Quote:
    Originally Posted by aykocity View Post
    can you use only a flag ?
    Someone? Could leave this option only for players with privileges?
    paulo_crash is offline
    SSheriFF
    AlliedModders Donor
    Join Date: May 2020
    Location: Israel
    Old 06-08-2020 , 15:59   Re: [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #9

    Quote:
    Originally Posted by paulo_crash View Post
    Someone? Could leave this option only for players with privileges?
    Change this:
    PHP Code:
    public Action OnTakeDamage(int clientint &attackerint &inflictorfloat &damageint &damagetype
    {
        if (
    damagetype DMG_FALL)
            return 
    Plugin_Handled;
        
        return 
    Plugin_Continue;

    To this:
    PHP Code:
    public Action OnTakeDamage(int clientint &attackerint &inflictorfloat &damageint &damagetype
    {
        if (
    damagetype DMG_FALL &&CheckCommandAccess(client,"",ADMFLAG_RESERVATION))//edit "ADMFLAG_RESERVATION" to your desired flag.
            
    return Plugin_Handled;
        
        return 
    Plugin_Continue;

    __________________
    Taking small private requests (Free) and big private requests (Paid).
    Contact me via Discord: WilDick#1524

    My Plugins:

    Last edited by SSheriFF; 06-08-2020 at 15:59.
    SSheriFF is offline
    paulo_crash
    AlliedModders Donor
    Join Date: May 2016
    Location: Brazil
    Old 06-08-2020 , 20:25   Re: [CS:GO] No Fall Damage (Updated: 02/16/2018)
    Reply With Quote #10

    Quote:
    Originally Posted by SSheriFF View Post
    Change this:
    PHP Code:
    public Action OnTakeDamage(int clientint &attackerint &inflictorfloat &damageint &damagetype
    {
        if (
    damagetype DMG_FALL)
            return 
    Plugin_Handled;
        
        return 
    Plugin_Continue;

    To this:
    PHP Code:
    public Action OnTakeDamage(int clientint &attackerint &inflictorfloat &damageint &damagetype
    {
        if (
    damagetype DMG_FALL &&CheckCommandAccess(client,"",ADMFLAG_RESERVATION))//edit "ADMFLAG_RESERVATION" to your desired flag.
            
    return Plugin_Handled;
        
        return 
    Plugin_Continue;

    Thanks for sharing, I'll be testing. Any problems return contact.
    paulo_crash is offline
    Reply



    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 08:35.


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