From ad22922393c7982b885840960222de64ff96ad36 Mon Sep 17 00:00:00 2001 From: Alexander Harkness Date: Sun, 14 Jan 2018 18:44:45 +0000 Subject: Rename cEntity swim states (#3996) * Replace cEntity:m_IsSubmerged with m_IsHeadInWater * Replace cEntity:m_IsSwimming with m_IsInWater * Add API documentation for new symbols * Apply SetSwimState to all entities, not just mobs and players * Pickups now use IsOnFire to check if they are on fire before destruction Fixes #3987 --- src/Entities/ArrowEntity.cpp | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/Entities/ArrowEntity.cpp') diff --git a/src/Entities/ArrowEntity.cpp b/src/Entities/ArrowEntity.cpp index 4d104bd26..2dc329f30 100644 --- a/src/Entities/ArrowEntity.cpp +++ b/src/Entities/ArrowEntity.cpp @@ -123,7 +123,7 @@ void cArrowEntity::OnHitEntity(cEntity & a_EntityHit, Vector3d a_HitPos) double KnockbackAmount = 11 + 10 * PunchLevel; a_EntityHit.TakeDamage(dtRangedAttack, GetCreatorUniqueID(), Damage, KnockbackAmount); - if (IsOnFire() && !a_EntityHit.IsSubmerged() && !a_EntityHit.IsSwimming()) + if (IsOnFire() && !a_EntityHit.IsInWater()) { a_EntityHit.StartBurning(100); } @@ -218,7 +218,3 @@ void cArrowEntity::Tick(std::chrono::milliseconds a_Dt, cChunk & a_Chunk) } } } - - - - -- cgit v1.2.3