# Damage reduction system depending on the player's weapon problem

**URL:** <https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375>\
**Category:** Verse\
**Tags:** unreal-editor-for-fortnite, fortnite-creative, question, fortnite\
**Created:** [September 27, 2024, 8:53pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375 "2024-09-27T20:53:19Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![Strelloke](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Strelloke](https://forums.unrealengine.com/u/Strelloke)\
**Post date:** [September 27, 2024, 8:53pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/1 "2024-09-27T20:53:19Z")

</div>

I’m trying to make a damage reduction system depending on the player’s weapon, ran into the problem that I can’t change the default damage. I came up with the idea of restoring health to the person who took damage. Is it possible to somehow call the function before calling the elimination of the player as it can be done in UE, because otherwise if the standard damage is greater than the health of the enemy player, he dies and from the restoration of health makes no sense

---

<div class="post-metadata">

**Author:** ![Mineblo](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mineblo/32/1203575_2.png) [@Mineblo](https://forums.unrealengine.com/u/Mineblo)\
**Post date:** [September 29, 2024, 12:38am UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/2 "2024-09-29T00:38:26Z")

</div>

What you could try to do is have a damage amplifier device that is set to amplify the damage of the player negatively based on the weapon they’re holding (Using conditional button).

Eg You can use the damage powerup device set it to be 0.50 and then when you give this to a player the will effectively do 50% less damage

---

<div class="post-metadata">

**Author:** ![im\_a\_lama](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/im_a_lama/32/995063_2.png) [@im\_a\_lama](https://forums.unrealengine.com/u/im_a_lama)\
**Post date:** [September 30, 2024, 1:12pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/3 "2024-09-30T13:12:02Z")

</div>

The `fort_character.OnDamaged` event is indeed called a few frames before `OnEliminated`, that way you can even prevent lethal damage

---

<div class="post-metadata">

**Author:** ![Mineblo](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/mineblo/32/1203575_2.png) [@Mineblo](https://forums.unrealengine.com/u/Mineblo)\
**Post date:** [September 30, 2024, 6:43pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/4 "2024-09-30T18:43:21Z")

</div>

wait what no way, thats actually a really cool information to know that should be mentioned somewhere

---

<div class="post-metadata">

**Author:** ![im\_a\_lama](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/im_a_lama/32/995063_2.png) [@im\_a\_lama](https://forums.unrealengine.com/u/im_a_lama)\
**Post date:** [September 30, 2024, 6:46pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/5 "2024-09-30T18:46:04Z")

</div>

UEFN is all about finding the tricks 😃

---

<div class="post-metadata">

**Author:** ![Strelloke](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Strelloke](https://forums.unrealengine.com/u/Strelloke)\
**Post date:** [October 1, 2024, 1:13pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/6 "2024-10-01T13:13:40Z")

</div>

As far as I can tell from the logs, this is not the case. If a player has less than or equal to 0 hit points, the Eliminate function is called first in the game (inside Fortnite via C++ i think). If you look at what is called first through the Print function using Subcribe on the OnDamaged() event, it appears that OnDamage is called first. It may be true what you say, but I can’t get into those couple frames. Probably because I’m throwing my custom events and already processing them, so that’s why I can’t get into them

---

<div class="post-metadata">

**Author:** ![im\_a\_lama](https://d1ap1mz92jnks1.cloudfront.net/user_avatar/forums.unrealengine.com/im_a_lama/32/995063_2.png) [@im\_a\_lama](https://forums.unrealengine.com/u/im_a_lama)\
**Post date:** [October 1, 2024, 1:21pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/7 "2024-10-01T13:21:14Z")

</div>

Just heal someone inside the OnDamage event and you’ll see

---

<div class="post-metadata">

**Author:** ![Strelloke](https://d3kjluh73b9h9o.cloudfront.net/original/4X/2/8/5/28502927f1d97ba1051b3b47ccfe17233bf41ef0.png) [@Strelloke](https://forums.unrealengine.com/u/Strelloke)\
**Post date:** [October 1, 2024, 1:35pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/8 "2024-10-01T13:35:42Z")

</div>

Thanks for the info, I’ll think about how to implement this in my game 😁

---

<div class="post-metadata">

**Author:** ![system](https://d3kjluh73b9h9o.cloudfront.net/original/4X/7/1/3/713c9d3f58553f0de89543d76a8a3a2779dc9fa4.png) [@system](https://forums.unrealengine.com/u/system)\
**Post date:** [October 31, 2024, 1:35pm UTC](https://forums.unrealengine.com/t/damage-reduction-system-depending-on-the-players-weapon-problem/2041375/9 "2024-10-31T13:35:52Z")

</div>

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.
