Raised This Month: $ Target: $400
 0% 

Solved Get 'Owner' of other third entity


  
 
 
Thread Tools Display Modes
Prev Previous Post   Next Post Next
sursista
Senior Member
Join Date: Jul 2010
Location: Spain
Old 06-28-2021 , 07:12   Re: Get 'Owner' of other third entity
Reply With Quote #6

Quote:
Originally Posted by Celena Luna View Post
PHP Code:
if (userHealth damage <= 
{
    
dmgcount[attacker] += userHealth damage;
    
set_msg_block(gmsg_deathBLOCK_SET);
    
//ExecuteHamB(Ham_Killed, id, attacker, 2);
    
ExecuteHamB(Ham_TakeDamageid 2attackerfloat(damage), DMG_GENERIC); 
    
set_msg_block(gmsg_deathBLOCK_NOT);

isn't the condition of this part is "Do when victim gonna dead"?
Because of that, it only Execute Ham_TakeDamage when people is about to dead when taking that damage

=>



But it is OK to keep it like that though. I looked into the code of ZP Bazooka and found it is actually the part after that that you suppose to change:

(look at the highlight part and compare with your code)
Spoiler


The plugin "does damage" by setting player health though pev so it won't go through TakeDamage forward.

You should replace it with this:
PHP Code:
ExecuteHamB(Ham_TakeDamageid 2attackerfloat(damage), DMG_GENERIC); 
It seems silly but it makes sense, now I understand it, thank you very much for everything, now work!
sursista is offline
Send a message via MSN to sursista Send a message via Skype™ to sursista
 



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 02:39.


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