Information about conversation status
-
- Posts: 25
- Joined: Thu Dec 28, 2017 6:06 am
Information about conversation status
Hi, there! How do I know that a conversation has started and ended? I can't find any event for that (c#). I need to know that for example to disable Player controller, so the Player cannot walk and do any other actions. And when conversation ended, I will enable it. Thank you!
Re: Information about conversation status
Hi,
There are several ways:
1. Add a Set Component Enabled On Dialogue Event component to the player. Set the Trigger dropdown to OnConversation. Assign the player controller to the On Start and On End sections.
2. Or, add a Dialogue System Events component to the player. Configure the OnConversationStart() and OnConversationEnd() UnityEvents in the inspector.
3. Or, add a script to the player that has special script methods named OnConversationStart and OnConversationEnd. These will be automatically called on any scripts on the conversation participants or their child GameObjects.
There are several ways:
1. Add a Set Component Enabled On Dialogue Event component to the player. Set the Trigger dropdown to OnConversation. Assign the player controller to the On Start and On End sections.
2. Or, add a Dialogue System Events component to the player. Configure the OnConversationStart() and OnConversationEnd() UnityEvents in the inspector.
3. Or, add a script to the player that has special script methods named OnConversationStart and OnConversationEnd. These will be automatically called on any scripts on the conversation participants or their child GameObjects.
-
- Posts: 25
- Joined: Thu Dec 28, 2017 6:06 am
Re: Information about conversation status
Thanks, Tony. But I have another some questions. (I already tried to find answers for these questions, but I didn't find any of them.)
1) Dialogue System Events works well when it's attached to the DialogueManager gameobject. But it does not work when it is attached to the Player. What am I missing? The same things are happening with Special Methods like "OnConversationStart".
2) When I setup my Player in Player setup Wizard, and finish and close it, and if again I open Player setup wizard, the field of Player is empty.. Why? How to tell the Dialogue System which gameobject the main Player is?
1) Dialogue System Events works well when it's attached to the DialogueManager gameobject. But it does not work when it is attached to the Player. What am I missing? The same things are happening with Special Methods like "OnConversationStart".
2) When I setup my Player in Player setup Wizard, and finish and close it, and if again I open Player setup wizard, the field of Player is empty.. Why? How to tell the Dialogue System which gameobject the main Player is?
-
- Posts: 25
- Joined: Thu Dec 28, 2017 6:06 am
Re: Information about conversation status
Tony Li wrote: ↑Wed Apr 25, 2018 8:36 am Hi,
There are several ways:
1. Add a Set Component Enabled On Dialogue Event component to the player. Set the Trigger dropdown to OnConversation. Assign the player controller to the On Start and On End sections.
2. Or, add a Dialogue System Events component to the player. Configure the OnConversationStart() and OnConversationEnd() UnityEvents in the inspector.
3. Or, add a script to the player that has special script methods named OnConversationStart and OnConversationEnd. These will be automatically called on any scripts on the conversation participants or their child GameObjects.
And I have an exception: http://prntscr.com/jad36f
And my Dialogue System Events has become like that: http://prntscr.com/jad3xp
Re: Information about conversation status
Hi,
Can you remove and re-add the Dialogue System Events component? This is a bug in the Unity editor. I'm afraid there's nothing the Dialogue System itself can do about it.
Can you remove and re-add the Dialogue System Events component? This is a bug in the Unity editor. I'm afraid there's nothing the Dialogue System itself can do about it.