So maybe I'm going about this all wrong, but right now I'm trying to accomplish a conversation trigger that starts when an enemy is killed.
Currently, the main Actor is already placed into the scene when it starts up.
A trigger zone starts the initial conversation, which then activates an object that the player has to pickup. Once the player picks up the object, it triggers another conversation which then sends a message to the enemy spawner to instantiate the enemy prefab. The way I'm trying to get it to work is to have a trigger OnDestroy set on the enemy that triggers the next conversation.
So far I haven't been able to get it to trigger. I can't assign the main actor to the "Conversation Actor" because he's already in the scene and not a prefab that's being created.
I'm still pretty new to both unity and the dialogue system, so I don't know if it's not triggering because of the missing conversation actor, or just something else I'm doing wrong.
In fact, I don't even know if this is the best way to go about doing this or if there is a better way to "track" the enemy dying ( besides putting the on destroy trigger on him)
Any help here would be very much appreciated.
Assigning actor in scene to enemy prefab?Or something else?
-
- Posts: 2
- Joined: Sun Jul 21, 2019 1:14 am
Re: Assigning actor in scene to enemy prefab?Or something else?
Hi,
Add a Dialogue Actor component to your player prefab. Select the dialogue database's player actor from the dropdown.
If Dialogue System Trigger's Conversation Actor field is unassigned, it will look for a GameObject that has a Dialogue Actor component whose dropdown matches the conversation.
Add a Dialogue Actor component to your player prefab. Select the dialogue database's player actor from the dropdown.
If Dialogue System Trigger's Conversation Actor field is unassigned, it will look for a GameObject that has a Dialogue Actor component whose dropdown matches the conversation.
-
- Posts: 2
- Joined: Sun Jul 21, 2019 1:14 am
Re: Assigning actor in scene to enemy prefab?Or something else?
Awesome, thank you so much.