void ACineActor::PrintPlayingAudioName()
{
ALevelSequenceActor* SequenceActor = GetOwningLevelSequenceActor();
ULevelSequencePlayer* SequencePlayer = SequenceActor->SequencePlayer;
if (SequencePlayer == nullptr || !SequencePlayer->IsPlaying())
{
UE_LOG(CineLog, Error, TEXT(“SequencePlayer is null.”));
return;
}
TSharedRef<FMovieSceneSequenceInstance> movieSceneInstance = ((IMovieScenePlayer*)SequencePlayer)->GetRootMovieSceneSequenceInstance();
TSharedPtr<FMovieSceneSequenceInstance> movieSceneInstancePtr = movieSceneInstance;
UE_LOG(CineLog, Error, TEXT("asdf: %s"), *(movieSceneInstance->GetSequence()->GetName()));
/************************ Here's the problem! *************************/
// It seems that compiler hasnot compiled the following lines...
void* pv = &movieSceneInstancePtr;
unsigned char * pc = (unsigned char *)pv;
FMovieSceneSequenceInstance* MovieSceneSequenceInstance_tmpPtr = (reinterpret_cast<FMovieSceneSequenceInstance*>(pc));
TMap<FGuid, FMovieSceneObjectBindingInstanceMock>* ObjectBindingInstances = (TMap<FGuid, FMovieSceneObjectBindingInstanceMock>*) (MovieSceneSequenceInstance_tmpPtr + 78);
UE_LOG(CineLog, Error, TEXT("alart: %d"), ObjectBindingInstances->GetAllocatedSize())
}
When I debugged the game, I found the debugging yellow arrow just jumped over these lines, and then the engine crashed. Why?