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

[REQ] - No Fall Damage [Immune admin]


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
B l e n d
BANNED
Join Date: Oct 2012
Location: Somewhere on the planet
Old 11-17-2012 , 13:05   [REQ] - No Fall Damage [Immune admin]
Reply With Quote #1

Hello, I want a "No Fall Damage" plugin for those admin who have the flag "a".
NO HARDCODE
B l e n d is offline
Send a message via Skype™ to B l e n d
Torge
Veteran Member
Join Date: Oct 2011
Old 11-17-2012 , 13:16   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #2

Credits to Devil259:

PHP Code:
#include < amxmodx >
#include < hamsandwich >
#include < fakemeta >

new bool:gHasNoFall33 ];

public 
client_disconnectid )
{
    
remove_taskid );
}

public 
plugin_init( )
{
    
RegisterHamHam_TakeDamage"player""hamTakeDamage" );
    
RegisterHamHam_Spawn"player""hamSpawnPost"true );
    
RegisterHamHam_Killed"player""hamKilledPost"true );
}

public 
hamTakeDamagevictiminflictorattackerFloat:damagedamagebits )
{
    if( 
gHasNoFallvictim ] && damagebits == DMG_FALL && get_user_flags(victim) & ADMIN_IMMUNITY )
        return 
HAM_SUPERCEDE;
        
    return 
HAM_IGNORED;
}

public 
hamSpawnPostid )
{
    if( 
is_user_aliveid ) )
    {
        
remove_taskid );
        
gHasNoFallid ] = true;
        
set_task5.0"ClearNoFall"id );
    }
}

public 
hamKilledPostid )
{
    
gHasNoFallid ] = false;
}

public 
ClearNoFallid )
{
    if( 
is_user_aliveid ) )
    {
        
gHasNoFallid ] = false;
    }

Torge is offline
B l e n d
BANNED
Join Date: Oct 2012
Location: Somewhere on the planet
Old 11-17-2012 , 13:26   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #3

Okay thank you!
Any chance to add "VIP" to all admins with flag "a" too? Nested in to that plugin.
B l e n d is offline
Send a message via Skype™ to B l e n d
Torge
Veteran Member
Join Date: Oct 2011
Old 11-17-2012 , 16:30   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #4

What do you exactly mean ?
Torge is offline
pokemonmaster
princess milk
Join Date: Nov 2010
Location: Somewhere in this world
Old 11-17-2012 , 16:44   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #5

Quote:
Originally Posted by Torge View Post
Credits to Devil259:
Spoiler
That's not what he asked for ...
This is what he asked for ...
PHP Code:
#include < amxmodx >
#include < hamsandwich >
#include < hlsdk_const >

public plugin_init( )
    
RegisterHamHam_TakeDamage"player""hamTakeDamage" );

public 
hamTakeDamagevictiminflictorattackerFloat:damagedamagebits )
{
    if( 
damagebits == DMG_FALL && get_user_flags(victim) & ADMIN_IMMUNITY )
        return 
HAM_SUPERCEDE;
    
    return 
HAM_IGNORED;

__________________
اَشْهَدُ اَنْ لَّآ اِلٰهَ اِلَّا اللہُ وَحْدَه لَا شَرِيْكَ لَه وَ اَشْهَدُ اَنَّ مُحَمَّدًا عَبْدُه وَرَسُوْلُه
No longer active in AMXX. Sorry.
pokemonmaster is offline
B l e n d
BANNED
Join Date: Oct 2012
Location: Somewhere on the planet
Old 11-17-2012 , 17:05   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #6

Quote:
Originally Posted by pokemonmaster View Post
That's not what he asked for ...
This is what he asked for ...

//"Code here"
Thank you master :=)

Any chance you know how to nest a "vipFunction" in to this code? with VIP text there you can se DEAD also.
And so I easly can add my own new functions to this, like vipHealth etc.

Last edited by B l e n d; 11-17-2012 at 17:05.
B l e n d is offline
Send a message via Skype™ to B l e n d
Torge
Veteran Member
Join Date: Oct 2011
Old 11-17-2012 , 17:06   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #7

Quote:
Originally Posted by pokemonmaster View Post
That's not what he asked for ...
This is what he asked for ...
PHP Code:
#include < amxmodx >
#include < hamsandwich >
#include < hlsdk_const >

public plugin_init( )
    
RegisterHamHam_TakeDamage"player""hamTakeDamage" );

public 
hamTakeDamagevictiminflictorattackerFloat:damagedamagebits )
{
    if( 
damagebits == DMG_FALL && get_user_flags(victim) & ADMIN_IMMUNITY )
        return 
HAM_SUPERCEDE;
    
    return 
HAM_IGNORED;

Where's the difference? oO
Torge is offline
B l e n d
BANNED
Join Date: Oct 2012
Location: Somewhere on the planet
Old 11-17-2012 , 17:08   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #8

Quote:
Originally Posted by Torge View Post
Where's the difference? oO
This code is much more stable than yours + Your code only works the first playround.

Also wait for what master got to say...

Last edited by B l e n d; 11-17-2012 at 17:09.
B l e n d is offline
Send a message via Skype™ to B l e n d
Torge
Veteran Member
Join Date: Oct 2011
Old 11-17-2012 , 17:25   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #9

Funny, all what he did was removing the other stuff, lol..

Edit: Would be nice if you'd tell me this to remove it but anyway, I'm done here.

Last edited by Torge; 11-17-2012 at 17:26.
Torge is offline
B l e n d
BANNED
Join Date: Oct 2012
Location: Somewhere on the planet
Old 11-17-2012 , 17:35   Re: [REQ] - No Fall Damage [Immune admin]
Reply With Quote #10

Quote:
Originally Posted by Torge View Post
Funny, all what he did was removing the other stuff, lol..

Edit: Would be nice if you'd tell me this to remove it but anyway, I'm done here.
See #include < hlsdk_const >
B l e n d is offline
Send a message via Skype™ to B l e n d
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 10:54.


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