void UInterpTrackAkAudioEvent::PreviewUpdateTrack(float NewPosition, UInterpTrackInst* TrInst) { UInterpGroupInst* GrInst = CastChecked<UInterpGroupInst>( TrInst->GetOuter() ); AMatineeActor* MatineeActor = CastChecked<AMatineeActor>( GrInst->GetOuter() ); UInterpTrackInstAkAudioEvent* AkEventInst = CastChecked<UInterpTrackInstAkAudioEvent>( TrInst ); UInterpGroup* Group = CastChecked<UInterpGroup>( GetOuter() ); UInterpData* IData = CastChecked<UInterpData>( Group->GetOuter() ); // Dont play sounds unless we are preview playback (ie not scrubbing). bool bJump = !(MatineeActor->bIsPlaying); UpdateTrack(NewPosition, TrInst, bJump); }
void UMatineeTrackEventHelper::PostCreateKeyframe( UInterpTrack *Track, int32 KeyIndex ) const { UInterpTrackEvent *EventTrack = CastChecked<UInterpTrackEvent>(Track); FEventTrackKey& NewEventKey = EventTrack->EventTrack[ KeyIndex ]; NewEventKey.EventName = KeyframeAddDataName; // Update AllEventNames array now we have given it a name UInterpGroup* Group = CastChecked<UInterpGroup>( EventTrack->GetOuter() ); UInterpData* IData = CastChecked<UInterpData>( Group->GetOuter() ); IData->UpdateEventNames(); KeyframeAddDataName = NAME_None; }