[Half-Life AMXX] / grab_plus.sma Repository:
ViewVC logotype

Diff of /grab_plus.sma

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 27, Wed Nov 21 04:12:55 2007 UTC revision 39, Mon Feb 18 12:47:15 2008 UTC
# Line 1  Line 1 
1  /*  /*
2  Grab+ v1.2.3  Grab+ v1.2.4
3  Copyright (C) 2007 Ian (Juan) Cammarata  Copyright (C) 2007 Ian (Juan) Cammarata
4    
5  This program is free software: you can redistribute it and/or modify  This program is free software: you can redistribute it and/or modify
# Line 17  Line 17 
17  --------------------------------------------------------------------------------  --------------------------------------------------------------------------------
18    
19  http://ian.cammarata.us/projects/grab_plus  http://ian.cammarata.us/projects/grab_plus
20  Nov 16 08:08  Nov 21 11:03
21    
22    
23  Description:  Description:
# Line 95  Line 95 
95  French (100%) - Thanks to connorr  French (100%) - Thanks to connorr
96  German (100%) - Thanks to SchlumPF*  German (100%) - Thanks to SchlumPF*
97  Russian (100%) - Thanks to `666  Russian (100%) - Thanks to `666
98  Spanish (100%) - Hope these don't suck.  Spanish (100%) - Thanks to RenXO
99  Swedish (100%) - Thanks to Bend3r  Swedish (100%) - Thanks to Bend3r
100    
101    
102  Change Log:  Change Log:
103  Key (+ added | - removed | c changed | f fixed)  Key (+ added | - removed | c changed | f fixed)
104    
105  v1.2.3 (Nov ??, 2007)  v1.2.4 (Feb 18, 2007)
106    f: Killing player with choke in some mods bugged out really bad.
107    
108    v1.2.3 (Nov 21, 2007)
109  c: A few more small optimizations.  c: A few more small optimizations.
110  f: Fixed bad message disconnect error when players get choked. ( stupid SVC_DAMAGE define )  f: Bloodstream for choke wasn't aligned with player.
111    f: Bad message disconnect error when players were choked. ( stupid SVC_DAMAGE define )
112    
113  v1.2.2 (Nov 16, 2007)  v1.2.2 (Nov 16, 2007)
114  c: A few small code optimizations.  c: A few small code optimizations.
# Line 133  Line 137 
137  #include <amxmisc>  #include <amxmisc>
138  #include <fakemeta>  #include <fakemeta>
139    
140  new const VERSION[ ] = "1.2.3RC"  new const VERSION[ ] = "1.2.4b1"
141  new const TRKCVAR[ ] = "grab_plus_version"  new const TRKCVAR[ ] = "grab_plus_version"
142  #define ADMIN ADMIN_LEVEL_A  #define ADMIN ADMIN_LEVEL_A
143    
# Line 501  Line 505 
505  public do_choke( id )  public do_choke( id )
506  {  {
507          new target = client_data[id][GRABBED]          new target = client_data[id][GRABBED]
508          if( client_data[id][FLAGS] & CDF_NO_CHOKE /*|| id == target*/ || target > MAXPLAYERS) return          if( client_data[id][FLAGS] & CDF_NO_CHOKE || id == target || target > MAXPLAYERS) return
509    
510          new dmg = get_pcvar_num( p_choke_dmg )          new dmg = get_pcvar_num( p_choke_dmg )
511          new Float:vec[3]          new vec[3]
512          get_target_origin_f( target )          FVecIVec( get_target_origin_f( target ), vec )
513    
514          message_begin( MSG_ONE, SVC_SCREENSHAKE, _, target )          message_begin( MSG_ONE, SVC_SCREENSHAKE, _, target )
515          write_short( 999999 ) //amount          write_short( 999999 ) //amount
# Line 527  Line 531 
531          write_byte( 0 ) //damage armor          write_byte( 0 ) //damage armor
532          write_byte( dmg ) //damage health          write_byte( dmg ) //damage health
533          write_long( DMG_CRUSH ) //damage type          write_long( DMG_CRUSH ) //damage type
534          write_coord( floatround( vec[0] ) ) //origin[x]          write_coord( vec[0] ) //origin[x]
535          write_coord( floatround( vec[1] ) ) //origin[y]          write_coord( vec[1] ) //origin[y]
536          write_coord( floatround( vec[2] ) ) //origin[z]          write_coord( vec[2] ) //origin[z]
537          message_end( )          message_end( )
538    
539          message_begin( MSG_BROADCAST, SVC_TEMPENTITY )          message_begin( MSG_BROADCAST, SVC_TEMPENTITY )
540          write_byte( TE_BLOODSTREAM )          write_byte( TE_BLOODSTREAM )
541          write_coord( floatround( vec[0] ) ) //pos.x          write_coord( vec[0] ) //pos.x
542          write_coord( floatround( vec[1] ) ) //pos.y          write_coord( vec[1] ) //pos.y
543          write_coord( floatround( vec[2] ) + 15 ) //pos.z          write_coord( vec[2] + 15 ) //pos.z
544          write_coord( random_num( 0, 255 ) ) //vec.x          write_coord( random_num( 0, 255 ) ) //vec.x
545          write_coord( random_num( 0, 255 ) ) //vec.y          write_coord( random_num( 0, 255 ) ) //vec.y
546          write_coord( random_num( 0, 255 ) ) //vec.z          write_coord( random_num( 0, 255 ) ) //vec.z
# Line 545  Line 549 
549          message_end( )          message_end( )
550    
551          new health = pev( target, pev_health ) - dmg          new health = pev( target, pev_health ) - dmg
         set_pev( target, pev_health, float( health ) )  
552          if( health < 1 ) dllfunc( DLLFunc_ClientKill, target )          if( health < 1 ) dllfunc( DLLFunc_ClientKill, target )
553            else {
554                    set_pev( target, pev_health, float( health ) )
555          emit_sound( target, CHAN_BODY, "player/PL_PAIN2.WAV", VOL_NORM, ATTN_NORM, 0, PITCH_NORM )          emit_sound( target, CHAN_BODY, "player/PL_PAIN2.WAV", VOL_NORM, ATTN_NORM, 0, PITCH_NORM )
556            }
557    
558          client_data[id][FLAGS] ^= CDF_NO_CHOKE          client_data[id][FLAGS] ^= CDF_NO_CHOKE
559          set_task( get_pcvar_float( p_choke_time ), "clear_no_choke", TSK_CHKE + id )          set_task( get_pcvar_float( p_choke_time ), "clear_no_choke", TSK_CHKE + id )

Legend:
Removed from v.27  
changed lines
  Added in v.39

Contact
ViewVC Help
Powered by ViewVC 1.0.4