From 0b6f97ed73be491908b754ecfb2c231abc61d613 Mon Sep 17 00:00:00 2001 From: elijah-thomas774 Date: Sun, 24 May 2026 14:29:43 -0400 Subject: dAcEKs_c State ChaseAttack, Fighting, AttackReady, Attack, Damage, Stun, WindBlow and PathMove --- src/toBeSorted/d_path.cpp | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) (limited to 'src/toBeSorted/d_path.cpp') diff --git a/src/toBeSorted/d_path.cpp b/src/toBeSorted/d_path.cpp index 43b2b896..6a539796 100644 --- a/src/toBeSorted/d_path.cpp +++ b/src/toBeSorted/d_path.cpp @@ -589,6 +589,22 @@ s32 ActorOnRail_Ext::getNextPointIndex() const { return getNextPointIndex(mSegmentIndex); } +s32 ActorOnRail_Ext::getNextPointIndex2() const { + if (mSpeed >= 0.0f) { + return mSegmentIndex; + } + + if (mSegmentIndex + 1 < mPath.getNumPoints()) { + return mSegmentIndex + 1; + } + + if (mPath.isWrapping()) { + return 0; + } + + return mPath.getLastPointIdx(); +} + s32 ActorOnRail_Ext::getClosestXZPoint(const mVec3_c &pos) const { f32 max = EGG::Math::maxNumber(); s32 best = 0; -- cgit v1.2.3