-
Notifications
You must be signed in to change notification settings - Fork 2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
No damage effects on hp_max change #11846
Conversation
Will the damage effect also happen if |
A increase of |
Could you rebase this on master and test on your end? It's no longer possible to compile this on the latest IrrlichtMT, and after performing a local rebase I saw incorrect results from a quick test (no effect on fall damage, effect present on max hp changes). To me, that implies either this doesn't function as advertised, or (more likely) something relevant has changed in the interim that needs addressing. |
1996fa7
to
e914e0a
Compare
Tested again, still seeing incorrect results. First of all, just changing max hp still seems to trigger a damage flash. Additionally, fall damage no longer causes a flash. To help you out a bit, I did some digging for the latter. Fall damage in singleplayer is triggering I should not that I'm testing in singleplayer, so if you've been using a separate server to test this may be the source of your bugs. |
Thanks, you were correct with your digging. Fixed. |
1e7ee94
to
c5638df
Compare
Thanks for the quick turnaround. I'm too tired for a full test tonight, but I can at least confirm that in singleplayer fall damage is displaying the proper effect again, and max hp changes are not. So far so good. I'll try to give this a more thorough test and review by the end of the week. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested the following in an actual game context, using Mineclone 2 and an unreleased game prototype:
- node damage_per_second: Effect
- PVP damage: Effect
- non-PVP combat damage (ie. getting punched by a mob): Effect
- Drowning damage: Effect
- Fall damage: Effect
- Max HP reduction from a status effect wearing out: No Effect
I tested all of these in singleplayer, locally-hosted multiplayer as host, and locally-hosted multiplayer as a client and got consistent results in each test. I also tested locally-hosted multiplayer with an unpatched host and with an unpatched client. In both cases the bug persisted (as expected), but no errors occurred due to the packet changes.
I'm satisfied with this result, and while I think you could improve the name of effect
the code is still readable as-is so I'll leave that to your discretion and approve now.
@@ -87,6 +87,7 @@ struct ClientEvent | |||
struct | |||
{ | |||
u16 amount; | |||
bool effect; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I think this could stand to be more explicit. Something like show_effect
would make the purpose clearer at a glance imo.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Might call this something like silent
, quiet
, hidden
or the like if inverted, but show_effect
may be slightly misleading as setting this to false
will also suppress the audio effect.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd be fine with those options as well.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Not tested but lgtm
#10569 rebased and fixed. Closes #7876 - should this also alter the punch command being sent, to suppress the punch effect?
Test using the following code (EPILEPSY WARNING):