Exemplo n.º 1
0
CDialogActorContext::~CDialogActorContext()
{
	StopSound();
	CancelCurrent();
	IEntity* pEntity = gEnv->pEntitySystem->GetEntity(m_entityID);
	const char* debugName = pEntity ? pEntity->GetName() : "<no entity>";
	DiaLOG::Log(DiaLOG::eAlways, "[DIALOG] CDialogActorContext::dtor: %s 0x%p actorID=%d entity=%s entityId=%d",
		m_pSession->GetDebugName(), this, m_actorID, debugName, m_entityID);
}
Exemplo n.º 2
0
void CDialogActorContext::AbortContext(bool bCancel, CDialogSession::EAbortReason reason)
{
	DiaLOG::Log(DiaLOG::eAlways, "[DIALOG] CDialogActorContext:AbortContext: %s actorID=%d ", m_pSession->GetDebugName(), m_actorID);
	m_phase = eDAC_Aborted;
	m_abortReason = reason;
	if (bCancel)
		CancelCurrent();
	// need to set it again, as CancelCurrent might have changed them
	m_phase = eDAC_Aborted;
	m_abortReason = reason;
}
CDialogActorContext::~CDialogActorContext()
{
    if (m_SpeechAuxProxy != INVALID_AUDIO_PROXY_ID)
    {
        IEntity* pActorEntity = m_pSession->GetActorEntity(m_actorID);
        if (pActorEntity)
        {
            IEntityAudioProxy* pActorAudioProxy = m_pSession->GetEntityAudioProxy(pActorEntity);
            if (pActorAudioProxy)
            {
                pActorAudioProxy->RemoveAsListenerFromAuxAudioProxy(m_SpeechAuxProxy, &CDialogActorContext::OnAudioTriggerFinished);
                pActorAudioProxy->RemoveAuxAudioProxy(m_SpeechAuxProxy);
            }
        }
    }

    StopSound();
    CancelCurrent();
    IEntity* pEntity = gEnv->pEntitySystem->GetEntity(m_entityID);
    const char* debugName = pEntity ? pEntity->GetName() : "<no entity>";
    DiaLOG::Log(DiaLOG::eAlways, "[DIALOG] CDialogActorContext::dtor: %s 0x%p actorID=%d entity=%s entityId=%d",
                m_pSession->GetDebugName(), this, m_actorID, debugName, m_entityID);
}
Exemplo n.º 4
0
void CDialogActorContext::EndSession()
{
	CancelCurrent();
	DiaLOG::Log(DiaLOG::eAlways, "[DIALOG] CDialogActorContext::EndSession: %s now=%f 0x%p actorID=%d ",
		m_pSession->GetDebugName(), m_pSession->GetCurTime(), this, m_actorID);
}