fungus

Open full view…

Executing dialog once.

sonicwisp
Mon, 25 Jun 2018 18:49:28 GMT

Hello. I'm making a game similar to Ace Attorney series. But I need to execute the dialog once when the player enters on the scene. And when he leaves the scene and then comes back again, the dialog doesn't repeat. How do I do that?

grimork
Wed, 27 Jun 2018 10:30:50 GMT

Hi. It must be easy. Just create an bool variable. SetVariable when your dialog is done. And at the start of dialog add "If" condition to check your variable.

sonicwisp
Wed, 04 Jul 2018 03:52:14 GMT

I'm not familiar with coding in Fungus. Do I have to create a new script or use the Fungus's ones? Thanks for the help!!!

grimork
Wed, 04 Jul 2018 06:18:04 GMT

You don't need to code, this is standard fungus actions to set and check variable. Watch this video tutorial: https://youtu.be/uRh7INbed2I

sonicwisp
Sun, 08 Jul 2018 20:07:51 GMT

I think it works in a single scene. But my multiple scenes are preventing it from working as I want it. Thanks for the help, anyway :D

grimork
Sun, 08 Jul 2018 20:46:04 GMT

Hmm, you can create an DontDestroyOnLoad(this.gameObject) common game object, which will be available in all scenes. Attach an script to it with public bool variable and access it form Fungus from GetVariable and SetVariable actions. Yeah, you need minimum coding skills to do it.