Release Date
2022-12-12 19:32:27 UTC
Changelog
Create cinematic cutscenes in your game using this package which allows you to easily create camera movements and dialogue sequences with actions triggering.

Installation

  1. Under the Community tab
  2. Search for “Cinematic Dialogue System”
  3. Install the package called Cinematic Dialogue System by itsjacky7

How To Use

  1. After installing the package you will find the below templates:
    • dialogueSystem
    • dialogueSystemExample
    • dialogueSystemView
    • dialogueSequence

  2. Attach the dialogueSystemView to the User template



    dialogueSystemView guide
    1920×605 178 KB


  3. Add the dialogueSystem somewhere in your game world
  4. Preview the game, walk up to the NPC.
  5. Press the interact button (E) to activate the dialogue.
  6. Press the jump button (Spacebar) to advance the dialgue.

Adding Dialogue Sequence

  1. Add another dialogue sequence by dragging the dialogueSequence template into the dialogueSystem > dialogueSequences locator.



    dialogueSequence guide
    1920×1080 399 KB


  2. Set the sequenceNumber property of the dialogueSequence to the next sequential number (in this example it is set to 2).
  3. Click the + button next to the dialogue property to add some dialogue text.
  4. Position the cameraStart and cameraEnd entities. The camera will smoothly transition from the cameraStart to the cameraEnd position when the dialogue sequence starts.
  5. Set the NPC emotes/effects/sounds as desired.

Displaying the Player’s Name

To display the player’s name in the dialogue simply type in “{playerName}” in the dialog property where you want the player’s name to be displayed.

Example Template

This package includes a template called dialogueSystemExample which demonstrates its capabilities and how is can be setup.
Warning there appears to be an issue with the NPC property not saving correctly when creating a template. So you will have to reset the NPC property on all the dialogueSequence.
  1. Exapand the dialogueSystemExample > dialogueSequences in the entities hierarchy
  2. Select the dialogueSequence1 entity
  3. Drag the nPC entity onto the npc property of the dialogueSequence1
  4. Repeat this for dialogueSequence2 and dialogueSequence3

Customizing the dialogue UI

To customize the dialogue UI, select the dialogueSystemView under the User template and then scroll down to the dialogueSystemWidget properties.


dialogueSystemWidget guide
1920×1080 331 KB


Content

  • progressIndicator displays a progress indicator in the bottom left corner of the dialogue UI.

Dialogue Font

  • nameSize sets the font size of the name text in units of rem.` Button that the player presses to advance the dialogue.
  • textSize sets the font size of the text in the dialogue in units of rem.

Dialogue Style

  • padding sets the padding of the dialogue in units of rem.
  • borderRadius sets the border radius of the dialogue in units of rem.
  • borderWidth sets the inner border width in units of pixels (px).
  • borderColor sets the color of the inner border.
  • dialogueColor sets the color of the dialogue text.
  • nameColor sets the color of the name text.
  • textSize sets the font size of the text in the dialogue in units of rem.
  • backgroundColor sets the color of the dialogue background.
  • innerBackgroundColor sets the color of the inner dialogue background.

Properties


dialogueSystemView

  • buttonPress
    • The button the player has to press to advance the dialogue.
  • advanceDialogueSound
    • Sound that plays when the dialogue is advanced.
  • endDialogueSound
    • Sound that plays when the dialogue is ended.
  • animateText
    • If enabled, dialgue text will be animated onto the UI one character at a time.\n[Warning] does not work with localization as a conversion to string will lose non-ASCII characters.
  • animateTextSpeed
    • Controls the speed of the text animation, time in seconds (s) to wait between each charater being displayed.
  • animateTextSound
    • Sound to play when each character is displayed.

dialogueSystem

  • lockPlayerInput
    • If enabled, the player’s input will be locked when this dialogue is activated.
  • cameraTransitionTime
    • Time in seconds (s) that the camera will take to transition into the dialogue camera.

dialogueSequence

  • sequenceNumber
    • Determines the order in which the dialogue is played.
    • Sequence number needs to be in sequential order.
    • Sequence number should not be left at 0.
  • usePlayerName
    • Overrides the name property to display the local player’s name.
  • name
    • Name of the NPC or entity that is displayed in the dialogue UI.
  • dialogue
    • Dialogue text that displays in the dialogue UI.
  • cameraStart
    • The player camera will start at this camera’s position/rotation at the start of this dialogue sequence.
  • cameraEnd
    • The player camera will transition to this camera’s position/rotation during this dialogue sequence.
  • cameraTransitionTime
    • Time in seconds (s) that the camera will take to transition from the cameraStart to the cameraEnd position/rotation.
  • lookAtTarget
    • If enabled, the camera will look at the position of the ‘target’ locator entity during this dialogue sequence.
  • target
    • If lookAtTarget property is enabled, the player’s camera will look at the position of this locator during the dialogue sequence.
  • npc
    • NPC entity to update when this dialogue sequence starts.\nNote that NPC actions run on the server and will appear for all players.
  • npcEmote
    • Emote to play on the NPC when the dialogue sequence starts.
  • effect
    • Effect that plays at the location of the target locator when the dialogue sequence starts.
  • effectPositionOffset
    • Position to offset the effect that plays from the target locator.
  • effectRotationOffset
    • Rotaion to offset the effect that plays from the target locator.
  • sound
    • Sound that plays at the location of the target locator when the dialogue sequence starts.
  • soundPositionOffset
    • Position to offset the sound that plays from the target locator.
© 2024 CraytaKit