I have this set of code. The important thing is that I’m trying to modify how much damage a model can take. For example if they have the weakness condition, then they should deal half the damage on that attack.
What happens is it deals the Damage Dealt but doesn’t take into account the rest. Right now “20” is a placeholder amount just so I know exactly where the numbers are. But when a character is “weak”, then dungeon_guard1.Strength == 0.5. I’ve confirmed in the debugger that the variable is 0.5 but the output isn’t 20 * 0.5 but just 20.
There is only one dungeon_guard1 in the game. The object does receive damage. The debugger tells me that the objects strength is 0,5 and that it has the condition (using a Boolean ). Everything seems to work except for the fact that it doesn’t seem to actually half the damage
So this is the triggering boolean. And when I check the debugger, dungeon_guard1.Strength is listed as 0.5 before they make the attack.
I’ve also noticed that the Armor feature in the Health behavior doesn’t seem to reduce the damage as well if that is related. I have a similar condition that sets the armor percent damage reduction to 0.5 to, I assume, reduce the incoming damage in half but that ALSO doesn’t seem to factor into it. Not sure if that is another hint.
In the last screenshot, you’re setting the armor effectiveness to 0.5, which is part of the “Apply damage” extension. I’ve never actually used this extension but I would assume that the percent reduction is only applied if the player has more than 0 armor points?
But anyway, that doesn’t matter because in the action where you apply damage, you’ve set the “can be reduced by Armor” option to NO.
None of this has anything to do with the object.Strength variable which is something you created. You haven’t shown us any events that change this variable… you’ve said that it shows 0.5 in the debugger, but there must be something wrong if the value is still ending up as 20.
My brain got ahead of myself. I meant to attach this screen shot for the Weakness. This turns the Strength to 0.5.
It’s very likely that the reduction only applies to armor. That was going to be my next step of troubleshooting that. I just wasn’t sure if it was connected.