Raised This Month: $51 Target: $400
 12% 

[L4D2] SourceMod SDKHooks TakeDamage bug


Post New Thread Reply   
 
Thread Tools Display Modes
psychonic

BAFFLED
Join Date: May 2008
Old 11-10-2016 , 17:52   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #11

Quote:
Originally Posted by WildCard65 View Post
Um, according to the implementation of OnTakeDamageAlivePost, your unable to change params in post hooks(ref: https://github.com/alliedmodders/sou...sion.cpp#L1149)
Hrmph, you're right.

There's no technical reason why changing them shouldn't be allowed in OnTakeDamagePost or OnTakeDamageAlivePost since all of the damage info is by ref. That's a bit of an API failure. We should fix that.
psychonic is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 11-10-2016 , 18:07   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #12

Quote:
Originally Posted by psychonic View Post
That's a bit of an API failure. We should fix that.
Must of been some oversight since Feb 7 2013/earlier (ref: https://github.com/alliedmodders/sou...57bcc00a40840c)
__________________

Last edited by WildCard65; 11-10-2016 at 18:07.
WildCard65 is offline
psychonic

BAFFLED
Join Date: May 2008
Old 11-10-2016 , 18:16   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #13

It's not particularly useful for OnTakeDamagePost, and the hook on OnTakeDmage_Alive didn't exist then, but yes.
psychonic is offline
WildCard65
Veteran Member
Join Date: Aug 2013
Location: Canada
Old 11-10-2016 , 18:49   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #14

Quote:
Originally Posted by psychonic View Post
It's not particularly useful for OnTakeDamagePost, and the hook on OnTakeDmage_Alive didn't exist then, but yes.
if I recall, you just made the original "OnTakeDamage"/"OnTakeDamagePost" hook into Handling methods and just routed OnTakeDamage/OnTakeDamageAlive/OnTakeDamagePost/OnTakeDamageAlivePost to aforementioned methods.
__________________
WildCard65 is offline
psychonic

BAFFLED
Join Date: May 2008
Old 11-10-2016 , 19:37   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #15

Yes, I'm aware of the changes that I authored... because I authored them.
psychonic is offline
Accelerator
Senior Member
Join Date: Dec 2010
Location: Russia
Old 11-10-2016 , 22:44   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #16

So, TakeDamage will be fixed in newer versions?
Accelerator is offline
psychonic

BAFFLED
Join Date: May 2008
Old 11-11-2016 , 06:49   Re: [L4D2] SourceMod SDKHooks TakeDamage bug
Reply With Quote #17

There's nothing broken. It just does not have the ability to change the damage amount in a OnTakeDamageAlivePost hook.
psychonic is offline
Reply



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 23:33.


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