When using the SkeletonAnimation
component, you will receive Spine events which can be set in the Spine Editor as described here:
Events - Spine User Guide
You then subscribe your event method to skeletonAnimation.AnimationState.Event
like this:
skeletonAnimation.AnimationState.Event += HandleEvent;
..
void HandleEvent (TrackEntry trackEntry, Event e) {
..
}
You can have a look at the example scene Spine Examples/Getting Started/2 Controlling Animation
that comes with the spine-unity package on how to write a small script to react to an event with playing an audio sample.
Documentation can be found here on the spine-unity documentation pages:
spine-unity Runtime Documentation: Processing AnimationState Events