Page 1 of 2

Facing wrong direction

Posted: Sat Mar 05, 2022 5:43 pm
by hrohibil
Hello Toni

As seen below I a, still facing two issues-

1:
My invector character in all dialogues are facing the wrong way..

2:
Can that text UI (arrow pointing on below image) be lowered down?


Re: Facing wrong direction

Posted: Sat Mar 05, 2022 8:55 pm
by Tony Li
hrohibil wrote: Sat Mar 05, 2022 5:43 pm1: My invector character in all dialogues are facing the wrong way..
I have no idea. Which is the player? The character in the red and black checker shirt? Or the one wearing the baseball cap and hoodie?
hrohibil wrote: Sat Mar 05, 2022 5:43 pm2: Can that text UI (arrow pointing on below image) be lowered down?
Yes. Adjust your Unity UI layout. It's nothing specific to the Dialogue System. If you've based your UI on the Circle Standard Dialogue UI, you can probably just inspect the NPC Subtitle Panel's Horizontal Layout Group and change Child Alignment to Lower Center.

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 4:19 am
by hrohibil
Yes sorry for clarifying that.
The player is the one with the cap and glasses.
The one closest to the camera.

But even the AI is not facing him.
They don’t face each other’s??



Cheers
Hamid

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 8:41 am
by Tony Li
Hi Hamid,

Does your player GameObject have a DialogueSystemInvectorBridge?

Is its "Face Conversant" checkbox ticked?

Is the correct NPC assigned to the Dialogue System Trigger's Conversation Conversant?

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 10:14 am
by hrohibil
Ahh

This line fixed a lot..

"Is the correct NPC assigned to the Dialogue System Trigger's Conversation Conversant?"

I had copy pasted the trigger to other NPCs.. So now the player is facing the NPC, but NPC still not facing the player?

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 11:47 am
by Tony Li
In the NPC's first node, try setting the Sequence to:

Code: Select all

LookAt(listener, speaker); {{default}}

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 12:00 pm
by hrohibil
I already have sequence camera setup so I have a good position of both.

Would the below code not override that?

I “just” need the NPC to face the player during a conversation

Cheers

Hamid

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 12:01 pm
by Tony Li
The LookAt() command rotates the subject ('speaker' in this case).

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 12:21 pm
by hrohibil
Ok.

In the first node I already have this code in the Sequence:

SwitchCamera(GunshopCamera)

How can i combine that with LookAt(listener, speaker); {{default}}

EDIT:
What when the conversation is over, will the object return to previous orientation??

Re: Facing wrong direction

Posted: Sun Mar 06, 2022 2:35 pm
by Tony Li
Hi,

Add it to your Sequence:

Code: Select all

SwitchCamera(GunshopCamera);
LookAt(listener, speaker); 
{{default}}
I recommend watching the Cutscene Tutorial Videos.