This question is a follow up on @Babel's answer to Interpolating points with QGIS native Temporal Controller.
Having successfully implemented the aforementioned method, as seen here:
I would like to apply this method but following along a certain line contained in a different layer. For example, on the previous gif, between points 8 and 9, or between points 4 and 5, starting from the bottom right hand side, we can see the interpolated point moves diagonally from one point to another. Ideally, it should continue and follow the tracks, making the appropriate turns to the next stops.
How would we tell the point to follow a certain path between two points?