Raised This Month: $ Target: $400
 0% 

block special attack2 [solved]


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
potatis_invalido
BANNED
Join Date: Jul 2007
Location: 0 (world)
Old 10-01-2007 , 05:11   Re: block special attack
Reply With Quote #7

Quote:
Originally Posted by kp_uparrow View Post
the little text and animation shows up
Code:
 
public plugin_init()
{
 register_forward(FM_UpdateClientData, "forward_updateclientdata", 1);
}
 
public forward_updateclientdata(id, sendweapons, cd_handle)
{
 if(!is_user_alive(id))
  return FMRES_IGNORED;
 new const weapon = get_user_weapon(id);
 
 if(weapon == CSW_AUG || weapon == CSW_GLOCK18 || weapon == CSW_M4A1 || weapon == CSW_USP || weapon == CSW_FAMAS || weapon == CSW_SG552) // || weapon == CSW_KNIFE
 {
  new const button = pev(id, pev_button);
  if(button & IN_ATTACK2 && !(button & IN_ATTACK))
   set_cd(cd_handle, CD_flNextAttack, halflife_time() + 0.01);
  return FMRES_HANDLED;
 }
 return FMRES_IGNORED;
}

Last edited by potatis_invalido; 10-01-2007 at 05:21.
potatis_invalido is offline
 


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 07:59.


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