From 37138fb584e6689707086539dd71f1fe4ec58b9f Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 11 May 2020 14:23:12 -0400 Subject: [PATCH] CMorphBall: Convert TCastToPtr to TCastToConstPtr Same behavior, but makes the read-only intent explicit. --- Runtime/World/CMorphBall.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Runtime/World/CMorphBall.cpp b/Runtime/World/CMorphBall.cpp index fec490e04..10fdbfee1 100644 --- a/Runtime/World/CMorphBall.cpp +++ b/Runtime/World/CMorphBall.cpp @@ -2190,7 +2190,7 @@ float CMorphBall::ComputeMaxSpeed() const { constexpr CDamageInfo kBallDamage = {CWeaponMode(EWeaponType::BoostBall), 50000.f, 0.f, 0.f}; void CMorphBall::Touch(CActor& actor, CStateManager& mgr) { - if (const TCastToPtr act = actor) { + if (const TCastToConstPtr act = actor) { if (x1de4_24_inBoost && (act->GetVelocity() - x0_player.GetVelocity()).magnitude() > g_tweakBall->GetBoostBallMinRelativeSpeedForDamage()) { mgr.ApplyDamage(x0_player.GetUniqueId(), actor.GetUniqueId(), x0_player.GetUniqueId(), kBallDamage,