From the course: Unity 5: Build a Character Dialogue System

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Panel configuration

Panel configuration - Unity Tutorial

From the course: Unity 5: Build a Character Dialogue System

Start my 1-month free trial

Panel configuration

- [Instructor] Now that we have a panel to work with, we need a configuration scrip to handle our panels when we move forward from dialogue to dialogue. This script is going to change the grain out of the character who is not talking, configuring the data to our panel properties, and animating our dialogue text. Let's get started by going into our scripts folder in Unity, right-clicking, Create, new C# Script. We're going to call this panel config. Go ahead and open that up in Mono Develop. We're going to delete the start and update functions, and we're going to add a using directive so that we can have access to the sprite class. If you'll remember from one of our earlier videos, that's using UnityEngin.UI. The first thing we need is a variable to keep track of if a character is talking. We're going to say public bool characterIsTalking. Next we need four properties that we can access from the editor. That being our avatar image, our text background, our character name, and our…

Contents