Page 1 of 1

First person characer focus while in dialogue

Posted: Fri Jan 28, 2022 12:25 pm
by eeeli
Hello,

I was wondering if there was a built in feature in the Dialogue System for focusing on characters/objects while in dialogue in a first person game. Something along the lines of a slight zoom and limiting camera controls.

No worries at all if there's not, happy to roll my own. I'm only asking because I've found this to be such a feature rich package with so many extras that I figure it was worth asking in case I missed it.

Thanks either way!

Re: First person characer focus while in dialogue

Posted: Fri Jan 28, 2022 1:31 pm
by Tony Li
Hi,

I assume you want to zoom the camera into the NPC?

If so, use the Camera() sequencer command. For example, assuming the first node after <START> is spoken by the NPC, you can set its Sequence to:

Code: Select all

{{default}};
Camera(Closeup, , 1)
More info: Camerawork Tutorial in Cutscene Sequence Tutorials

The Camera() command is very versatile. It can work with various camera angles relative to the subject, or with absolute world positions. You can use the Default Camera Angle prefab to set a different default camera angle for each NPC.

---

To limit camera controls, add a Dialogue System Events component to the player. Configure the OnConversationStart() event to disable the camera control script(s). Configure OnConversationEnd() to re-enable them.

More info: Interaction Tutorial

Re: First person characer focus while in dialogue

Posted: Thu Feb 03, 2022 10:50 am
by eeeli
Hi Tony,

I think these are the exact kind of tools I was looking for!

It's taken a bit, but I'm working towards getting everything configured nicely, thanks :)

Re: First person characer focus while in dialogue

Posted: Thu Feb 03, 2022 10:58 am
by Tony Li
Glad to help!