|
|
- #include < amxmodx >
- #include < fakemeta >
- #include < hamsandwich >
- public plugin_init( )
- {
- register_plugin( "Damage Type Display", "1.0", "ESFKAMI" )
- RegisterHam( Ham_TakeDamage, "player", "@TakeDamage", true )
- }
- public @TakeDamage( __int_Victim, __int_Inflictor, __int_Attacker, Float: __float_Damage, __bit_DamageType )
- {
- switch( __bit_DamageType )
- {
- case 0: client_print( __int_Victim, print_center, "Damage Type: DMG_GENERIC" )
- case (1<<0): client_print( __int_Victim, print_center, "Damage Type: DMG_CRUSH" )
- case (1<<1): client_print( __int_Victim, print_center, "Damage Type: DMG_BULLET" )
- case (1<<2): client_print( __int_Victim, print_center, "Damage Type: DMG_SLASH" )
- case (1<<3): client_print( __int_Victim, print_center, "Damage Type: DMG_BURN" )
- case (1<<4): client_print( __int_Victim, print_center, "Damage Type: DMG_FREEZE" )
- case (1<<5): client_print( __int_Victim, print_center, "Damage Type: DMG_FALL" )
- case (1<<6): client_print( __int_Victim, print_center, "Damage Type: DMG_BLAST" )
- case (1<<7): client_print( __int_Victim, print_center, "Damage Type: DMG_CLUB" )
- case (1<<8): client_print( __int_Victim, print_center, "Damage Type: DMG_SHOCK" )
- case (1<<9): client_print( __int_Victim, print_center, "Damage Type: DMG_SONIC" )
- case (1<<10): client_print( __int_Victim, print_center, "Damage Type: DMG_ENERGYBEAM" )
- case (1<<12): client_print( __int_Victim, print_center, "Damage Type: DMG_NEVERGIB" )
- case (1<<13): client_print( __int_Victim, print_center, "Damage Type: DMG_ALWAYSGIB" )
- case (1<<14): client_print( __int_Victim, print_center, "Damage Type: DMG_DROWN" )
- case (1<<15): client_print( __int_Victim, print_center, "Damage Type: DMG_PARALYZE" )
- case (1<<16): client_print( __int_Victim, print_center, "Damage Type: DMG_NERVEGAS" )
- case (1<<17): client_print( __int_Victim, print_center, "Damage Type: DMG_POISON" )
- case (1<<18): client_print( __int_Victim, print_center, "Damage Type: DMG_RADIATION" )
- case (1<<19): client_print( __int_Victim, print_center, "Damage Type: DMG_DROWNRECOVER" )
- case (1<<20): client_print( __int_Victim, print_center, "Damage Type: DMG_ACID" )
- case (1<<21): client_print( __int_Victim, print_center, "Damage Type: DMG_SLOWBURN" )
- case (1<<22): client_print( __int_Victim, print_center, "Damage Type: DMG_SLOWFREEZE" )
- case (1<<23): client_print( __int_Victim, print_center, "Damage Type: DMG_MORTAR" )
- case (~(0x3fff)): client_print( __int_Victim, print_center, "Damage Type: DMG_TIMEBASED" )
-
- }
- }
复制代码 |
|