Raised This Month: $ Target: $400
 0% 

How to delete weapon with i killed?


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
Author Message
Screeaam..
Senior Member
Join Date: Jun 2010
Location: Poland
Old 10-25-2011 , 15:51   How to delete weapon with i killed?
Reply With Quote #1

Hello!

Here I have this code:

Code:
stock UTIL_Damage(attacker, victim, Float:fDamage, damagebits, ent = 0, const szWeapon[] = ""){
        static info_target = 0;
        if(!info_target)
                info_target = engfunc(EngFunc_AllocString, "info_target");
        
        if(pev_valid(ent))
                ExecuteHamB(Ham_TakeDamage, victim, ent, attacker, fDamage, damagebits);
        else{
                ent = engfunc(EngFunc_CreateNamedEntity, info_target);
                set_pev(ent, pev_classname, szWeapon);
                ExecuteHamB(Ham_TakeDamage, victim, ent, attacker, fDamage, damagebits);
                set_pev(ent, pev_flags, FL_KILLME);
        }
}
Code:
UTIL_Damage(attacker, victim, 40.0, (1<<1), attacker, "");
So yes, it displays the DMG, as well as attacking the victim sees it. But how to do that in the upper right corner of display skull, not a weapon with which they killed but that I must see the DMG of skill.

Cause i'm using this for skills in my mod.

If i make ent = 0 i don't see DMG, but see skull, but if i make ent = attacker i see DMG, but see too weapon witch i killed.
Screeaam.. is offline
 



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 14:16.


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