How to keep the event?

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
JeyWoo
Posts: 3
Joined: Thu Jul 20, 2023 1:44 am

How to keep the event?

Post by JeyWoo »

As shown in the screenshot, if I add an event in the dialog system, the event works fine at first.
When I move the scene, the dialog event is not applied like the screenshot. What should I do?
Attachments
문의1.JPG
문의1.JPG (45.11 KiB) Viewed 256 times
문의2.JPG
문의2.JPG (26.23 KiB) Viewed 256 times
User avatar
Tony Li
Posts: 22119
Joined: Thu Jul 18, 2013 1:27 pm

Re: How to keep the event?

Post by Tony Li »

Hi,

This message explains the issue:

sceneEvent.png
sceneEvent.png (26.46 KiB) Viewed 253 times

You have configured an event to happen in a specific scene. If you have opened another scene, you cannot see that event in the editor.

If you don't want to tie an event to a specific scene, please use sequencer commands.
JeyWoo
Posts: 3
Joined: Thu Jul 20, 2023 1:44 am

Re: How to keep the event?

Post by JeyWoo »

Thank you to reply
So I use SendMessage of sequence on Dialogue System
but It dosen't work..
SendMessage(ShakeDialogue, 5, gameObjectName);
User avatar
Tony Li
Posts: 22119
Joined: Thu Jul 18, 2013 1:27 pm

Re: How to keep the event?

Post by Tony Li »

Hi,

The 3 parameters to SendMessage() are:
  • Method name
  • String parameter*.
  • Name of GameObject that has a script with the specified method name.
Your method must accept one string parameter or no parameters. If it accepts no parameters, leave this parameter blank. Examples:

If a GameObject named "Front Door" has this method:

Code: Select all

public void OpenDoor() { .... }

Then use this sequencer command:

[code=sequence]SendMessage(OpenDoor, , Front Door)
If a GameObject named Screen Effects has this method and you want to pass the parameter "shake":

Code: Select all

public void PlayEffect(string effectName) { ... }
Then use this sequencer command:

Code: Select all

SendMessage(PlayEffect, shake, Screen Effects)
Post Reply