Skip to content

Example Blueprint Using Dialogue Values

Daniel Butum edited this page Oct 22, 2020 · 10 revisions

[[TOC]]

ℹ️ NOTE: An example like here is implemented in the Example Project

1. Ensure your Character implements the DlgDialogueParticipant interface

implement_interface_with_annotations

implement_interface_expanded_with_annotations

2. Create a Blueprint Struct

ℹ️ An example struct Dlg_Data_Struct you can copy is also in the Example Project

Copy the Struct from the Plugin Content

  • In the content Browser Press View Options -> Show Plugin Content
  • Navigate to the DlgSystem Content
  • Copy the Example_Struct_DialogueData to your Project Content Folder

Export_ExampleBlueprintStruct

Create New Struct

  • Create new asset from the content browser -> Blueprints -> Structure
  • Add 4 new variables, make Save Game to be checked for all of them.
    • Integers - Map (Dictionary) from Name to Integer
    • Floats - Map (Dictionary) from Name to Float
    • Names - Map (Dictionary) from Name to Name
    • TrueBools - Set of Name

Export_NewBlueprintStruct

3. Implement Participant Interface Functions

ℹ️ An example Blueprint BP_ThirdPersonCharacter you can copy/look at is also in the Example Project

Add a new variable with the name DialogueDataStruct, set the type to DlgDataStruct (or whatever your struct name is)

add_dialogue_struct_to_blueprint

Implement Get... functions

Export_ImplementBlueprint_Participant_GetFunctions

Implement Modify... functions

function_ModifyNameValue function_ModifyIntValue function_ModifyFloatValue function_ModifyBoolValue

Clone this wiki locally