Hi,
you need to animate the distance float, and use for example "compare float" action and trigger an event when it reaches your max value. On another fsm or on the same state, you simply inject that distanace in your raycasting action.
Can you already animate a float and send an event when it reach a max value.
Also, you can use tween engines to do that, animate the float from start to end, and the action will fire an event when finished.
bye,
Jean