From 466d986e5e7a01679e70a7affd5beaba401ae305 Mon Sep 17 00:00:00 2001 From: Aplaus228 <33102433+Aplaus228@users.noreply.github.com> Date: Thu, 8 Aug 2019 13:51:38 +0300 Subject: Change TakeDamageInfo::FinalDamage from int to float (#4359) Closes #4357 --- src/Entities/Entity.h | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/Entities/Entity.h') diff --git a/src/Entities/Entity.h b/src/Entities/Entity.h index bb6efcbbd..282e8368a 100644 --- a/src/Entities/Entity.h +++ b/src/Entities/Entity.h @@ -57,7 +57,7 @@ struct TakeDamageInfo eDamageType DamageType; // Where does the damage come from? Being hit / on fire / contact with cactus / ... cEntity * Attacker; // The attacking entity; valid only for dtAttack int RawDamage; // What damage would the receiver get without any armor. Usually: attacker mob type + weapons - int FinalDamage; // What actual damage will be received. Usually: m_RawDamage minus armor + float FinalDamage; // What actual damage will be received. Usually: m_RawDamage minus armor Vector3d Knockback; // The amount and direction of knockback received from the damage // TODO: Effects - list of effects that the hit is causing. Unknown representation yet } ; @@ -279,7 +279,7 @@ public: void TakeDamage(eDamageType a_DamageType, UInt32 a_Attacker, int a_RawDamage, double a_KnockbackAmount); /** Makes this entity take the specified damage. The values are packed into a TDI, knockback calculated, then sent through DoTakeDamage() */ - void TakeDamage(eDamageType a_DamageType, cEntity * a_Attacker, int a_RawDamage, int a_FinalDamage, double a_KnockbackAmount); + void TakeDamage(eDamageType a_DamageType, cEntity * a_Attacker, int a_RawDamage, float a_FinalDamage, double a_KnockbackAmount); float GetGravity(void) const { return m_Gravity; } -- cgit v1.2.3