protected override void Act() { DebugUtilities.Assert(actorName != null, "You tried to find a null speak actor in line:" + name); speakingActor = actingInScene.GetSceneActor(actorName); if (!speakingActor.IsInScene()) { speakingActor.ActorSceneEnter(); } var currentTalkingToActorName = TalkingToActorName; if (actorClip != null) { Debug.Log("Speaking line:" + name + " clip:" + actorClip.name + " speaker:" + actorName + " talkingTo:" + talkingToActorName); lastSpeakerName = actorName; lastTalkingToActorName = TalkingToActorName; actingInScene.GetGameObject().GetComponent <AudioSource>().clip = actorClip; actingInScene.GetGameObject().GetComponent <AudioSource>().Play(); StartFacialAnimation(speakingActor); IAvatar avatar = actingInScene.GetMainAvatar(); avatar.OnSubtitleStart(subtitle); } if (customAnimation != null) { PlayCustomAnimation(speakingActor, customAnimation); } if (actorName != "Tyra") { lastConversationWithNpc = actorName; } else if (talkingToActorName != "Tyra") { lastConversationWithNpc = currentTalkingToActorName; } }