Page 1 of 1

Activating Unity Event at the Start of Response Menu

Posted: Tue Jan 03, 2023 11:39 pm
by shounak00
Before choosing a responsse. I want to perform a unity event . How can I do it?

Re: Activating Unity Event at the Start of Response Menu

Posted: Wed Jan 04, 2023 8:23 am
by Tony Li
Hi,

Here are two options:

1. If you want to run the UnityEvent before every response menu, you can use a script with an OnConversationResponseMenu() method, like:

Code: Select all

public UnityEvent onStartResponseMenu;

void OnConversrationResponseMenu(Response[] responses)
{
    onStartResponseMenu.Invoke();
}

2. If you want to do something only at the start of a specific response menu, use sequencer commands in a response menu sequence. Inspect the node that precedes the response nodes, and tick Add Response Menu Sequence.