Intro to Dialogue Tree 4: Customization Guide (Outdated - See Description)

Video Statistics and Information

Video
Captions Word Cloud
Reddit Comments
Captions
hi my name is Zach and in this tutorial we're going to take a closer look at some of the various ways you can extend dialog tree to customize the look and feel of dialogue in your project if you don't already know dialog tree is a free plugin available on the unreal Marketplace that offers an easy to use system for creating and editing in game dialogue I'm going to assume that you've already looked over the quick start guide as well as the tutorials on the dialogue editor and queries and events those cover much more of the basic operation of the plug-in this one is going to serve as a survey of the various extension points the plugin includes to allow you to tailor it to your needs before we get down into the weeds I want to take a moment to review a few of the major objects we'll be talking about let's start with the dialog controller this is an actor that serves as a kind of bridge between your dialogues and The Game World the dialogue controller manages the display of dialogue and how speeches and options are presented it also serves as a general interface for dialog interactivity including the starting and stopping of conversations for for example when a speaker component attempts to start dialogue what it's actually doing is redirecting that request to the dialog controller a huge amount of customization is possible here up to in including creating your own custom dialog controller in Blueprint that said for most users the included BP basic dialog controller will work well with minimal tweaks if you're using the default dialog controller it makes use of a display widget functionally this is just a umg widget that implements the bi simple dialog display interface while the default dialog controller controls the behavior of dialogue in your project it outsources the actual display to its current display widget this is done to promote flexibility as the same basic dialogue Behavior can be displayed to the screen in many different ways why are display widgets in offshoot of the default controller and not a required part of the plugin as a whole basically because I could imagine a scenario where you might want to create a custom controller that Bridges its display across multiple widgets or even bypasses the need for display widgets altogether separating things out in this way gives you the option to use the provided display Widgets or not as you see fit speaker components are the bridge between your characters and the dialogue the default option carries standard information that a dialogue might expect to have but you can extend your speaker components to include extra data or functionality however you need an example of this extension is the provided crpg speaker component which includes portrait data for the speaker two display widgets are provided with the plugin the default WB basic dialog display will be the go-to option for most users when used with the default dialog controller this widget creates what I would think of as standard dialogue think of games like Skyrim The Witcher and the outer worlds in practice this means presenting a single NPC speech and a list of options for the player to respond the other provided display widget is W crpg dialogue display as the name implies this adds crpg Stables like portraits and a speech log to get the most use out of it crpg speaker components should be used in place of normal speaker components this will allow you to supply the portraits for your characters on a per speaker level the display widget you use can be set from the dialogue controllers details panel to tweak an existing display widget you just need a basic knowledge of umg the provided widgets can be found in the plugins content folder under display widgets and then the basic and crpg folders respectively opening the widgets up in umg you to tweak their visuals to your liking similarly you can create your own display widgets from scratch just create a new user widget and set it to implement the bi simple dialog display interface as with all interfaces that will provide you with several functions to implement to hook your custom widget into the default dialogue controller these include set controller which takes a dialog controller this allows your widget to cach a reference to its dialog controller display options takes an array of speech details structs and allows you to determine how Player speech options will display to the screen display speech takes a single speech details struct and a Target speaker component it allows you to determine how NPC speeches will display to the screen on open allows you to specify Behavior to play on opening the widget and on close allows you to specify Behavior to play on closing the widget even if you decide to stick with the default dialog controller it's inevitable that you'll want to tweak it to better fit your needs so let's take a little tour around the controller and how it can be modified up at the top of the event graph we have the initialize event which gets called from begin play the initialized function belongs to the default controller specifically not to the base dialog controller class if you write your own controller you may or may not want to include something similar essentially all it does is add a widget of its widget type to the screen below that we get into the first of our core dialog controller events with open display as the name suggests this opens the display widget and performs Associated tasks like changing the input mode next up we have Clos display which is essentially just the inverse of open display it closes the display widget and performs any Associated tasks next display options controls how player spe options get displayed to the screen in the case of the default dialog controller we pass the buck along to the display widget the same goes for a display speech which is responsible for displaying an individual speech and finally we have handle missing speaker this is an optional event to implement it gets called on starting the dialogue when the dialog tree asset was not provided with one of its expected speaker components handle missing speaker gives you a first opportunity to address the situation with the possible exceptions of initialize and handle missing speaker a custom dialog controller ought to implement each of these events your game won't crash or anything if it doesn't your dialogues just won't play that said even if you stick with the default dialog controller there is a fair amount you can do to customize its functionality let's say for example that you want to set up a special dialogue camera that flips back and forth between the various speakers you could add functionality switching your camera on and off to the open and close display events and under the display speech event you could add a function or event call that sets the camera's orientation based on who's speaking similarly if you want to hook in a lip sync function you could tack it on as part of your custom display speech implementation the point here is that every user-facing phase of dialogue has some function that you can Implement yourself or otherwise modify to include whatever functionality you need if none of this works the way you want you're able to scrap the default controller entirely and create your own in Blueprint the goal of this design was to create a somewhat modular approach with default options to take the user most of the way to a complete setup with minimal effort but with the flexibility for full customization if it's needed the speaker component is a kind of special case when it comes to customization given that we never really want to modify how it does its core job often however we do want to add extra functionality to help our characters better interact with dialogue we covered this somewhat in the queries and events tutorial where we made a custom speaker component with a counter to track how many times the speaker had asked a question another good example is the included crpg speaker component which includes a texture property to use as a portrait ultimately this is very open-ended so there's only so much advice I can offer here just know that custom speaker components are a good place to stash extra data or to add functionality that will interact with dialogue via queries or events in this tutorial we reviewed the major objects that can be extended to customize dialog in your project these include the dialog controller the display widget and the speaker components we also discussed how display widgets can be modified or replaced to customize the look of dialogue and how the dialog controller can be modified or replac to customize the behavior of dialogue on a more fundamental level finally we discussed how the speaker component can be extended to include additional data and functionality this concludes the series of introductory tutorials I had planned to get people up to speed with dialog tree As A Brief Review the quick start covers how to get the plugin set up and actually playing dialogue in just a few minutes the editor guide takes a detailed look at the dialogue editor its nodes and their properties the queries and events tutorial focuses in on how you can create custom queries and events to have your dialogues interact with the rest of the game world and finally this tutorial explored some of the ways you can customize the plugin to fit your needs you should now have a strong foundation for how to use dialog Tree in your own projects I may add more tutorials in future as new features are added and as the need arises feel free to reach out if you have any questions or requests for a specific feature or a tutorial on a specific topic the best way to reach me is probably via my Discord Channel if this video was helpful to you please give it a like And subscribe so you get notified when videos showcasing new features come out if you're enjoying the plugin I would be Beyond grateful if you could take a few seconds out of your day to leave me a review on the unreal Marketplace finally if you'd like to support further development on the project you can do so on patreon.com links to all of that as well as the plugins documentation site will be posted in the description in the meantime thanks for watching best of luck and happy developing
Info
Channel: UnraedGames
Views: 568
Rating: undefined out of 5
Keywords: Unreal Engine 5, UE5, Dialogue Tree, Unreal Engine, Game Development, Dialogue System, Plugin, Tutorial
Id: 5T6BxHAUaB4
Channel Id: undefined
Length: 9min 34sec (574 seconds)
Published: Sat Feb 10 2024
Related Videos
Note
Please note that this website is currently a work in progress! Lots of interesting data and statistics to come.