Raised This Month: $ Target: $400
 0% 

[Help] HP + No Fall Damage Just for T


Post New Thread Reply   
 
Thread Tools Display Modes
Author Message
uNy
Member
Join Date: Dec 2009
Old 05-20-2010 , 16:15   [Help] HP + No Fall Damage Just for T
Reply With Quote #1

Hello .. heres the deal .. i asked someone 2 make me a plugin JUST FOR TERRORIST TEAM that will give T 2k hp and no-fall damage ... well idk what is wrong, but here it gives just no-fall damage, not 2k hp too .. Rememba JUST FOR T's . Here's the code ..


PHP Code:

#include <amxmodx>
#include <fun>
#include <hamsandwich>

#pragma semicolon 1

#define DMG_FALL (1<<5)

new g_cHPg_cNoFallDamage;


public 
plugin_init()
{
      
register_plugin("Additional features for T?""1.0""uNy");
      
      
g_cHP           register_cvar("lol_hp""2000");
      
g_cNoFallDamage register_cvar("lol_no_fall_dmg""1");
      
      
register_event("HLTV""Event_NewRound""a""1=0""2=0");
      
      
RegisterHam(Ham_TakeDamage"player""Fwd_TakeDamage");
}

public 
Event_NewRound()
{
      new 
iPlayers[32], iCount;
      
      
get_players(iPlayersiCount);
      
      for(new 
0iCounti++)
      {
            if(!
is_user_connected(iPlayers[i]) || !is_user_alive(iPlayers[i]))
                  continue;
            
            if(
get_user_team(iPlayers[i]) == 1)
                  
set_user_health(iPlayers[i], get_pcvar_num(g_cHP));
      }
      
      return 
PLUGIN_CONTINUE;
}

public 
Fwd_TakeDamage(iVictimiInflictoriAttackerFloat:flDamageiDamageBits)
{
      if(
get_pcvar_num(g_cNoFallDamage) && (get_user_team(iVictim) == 1) && (iDamageBits DMG_FALL))
            return 
HAM_SUPERCEDE;
      
      return 
HAM_IGNORED;

__________________
AlliedModders is The BEST !
That's what she said.
steam://connect/80.96.216.53:27015
uNy is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 05-20-2010 , 17:17   Re: [Help] HP + No Fall Damage Just for T
Reply With Quote #2

Code:
#include <amxmodx> #include <fun> #include <hamsandwich> #include <cstrike> #include <hlsdk_const> #pragma semicolon 1 new g_cHP, g_cNoFallDamage; public plugin_init() {       register_plugin("Additional features for T?", "1.0", "uNy");             g_cHP           = register_cvar("lol_hp", "2000");       g_cNoFallDamage = register_cvar("lol_no_fall_dmg", "1");             RegisterHam( Ham_Spawn, "player", "HamSpawnPost", 1 );       RegisterHam(Ham_TakeDamage, "player", "Fwd_TakeDamage"); } public HamSpawnPost( id ) {     if( is_user_alive( id ) && cs_get_user_team( id ) == CS_TEAM_T )     {         set_user_health( id, get_pcvar_num( g_cHP ) );     } } public Fwd_TakeDamage(iVictim, iInflictor, iAttacker, Float:flDamage, iDamageBits) {       if(get_pcvar_num(g_cNoFallDamage) && (get_user_team(iVictim) == 1) && (iDamageBits & DMG_FALL))             return HAM_SUPERCEDE;             return HAM_IGNORED; }
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT

Last edited by wrecked_; 05-20-2010 at 17:38.
wrecked_ is offline
uNy
Member
Join Date: Dec 2009
Old 05-20-2010 , 17:26   Re: [Help] HP + No Fall Damage Just for T
Reply With Quote #3

Well , it can't compile this .. it said :

Expected : "," , but found ; .... Can you take another look please ?
__________________
AlliedModders is The BEST !
That's what she said.
steam://connect/80.96.216.53:27015
uNy is offline
Hx7r
Member
Join Date: Mar 2009
Old 05-20-2010 , 17:38   Re: [Help] HP + No Fall Damage Just for T
Reply With Quote #4

Code:
set_user_health( id, get_pcvar_num( g_cHP );

->

Code:
set_user_health( id, get_pcvar_num( g_cHP ));
Hx7r is offline
wrecked_
Veteran Member
Join Date: Jan 2010
Location: New York (GMT-5)
Old 05-20-2010 , 17:39   Re: [Help] HP + No Fall Damage Just for T
Reply With Quote #5

Fixed.
__________________
[ Paid Requests ]
DO NOT PM ME ABOUT BLOCKMAKER
NO PRIVATE SUPPORT
wrecked_ 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 03:50.


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