Lua Conditions

Announcements, support questions, and discussion for the Dialogue System.
Post Reply
Dev_sam
Posts: 1
Joined: Mon Apr 05, 2021 12:57 pm

Lua Conditions

Post by Dev_sam »

Hey guys,

I'm trying to link variables from my own script with Lua function, but somehting went wrong and my conditions seems ignored. I followed the tutorial video. I created a function that return a bool, then I registered it as a Lua function. I created a new scriptable Custom Lua Function Info and set my new function. Then I set the new conditions in a dialog entry.

I added some sceenshot in attachment, can anyone helps me?

Thanks
Attachments
Capture4.PNG
Capture4.PNG (42.33 KiB) Viewed 64 times
Capture3.PNG
Capture3.PNG (116.89 KiB) Viewed 64 times
Capture1.PNG
Capture1.PNG (19.57 KiB) Viewed 64 times
Capture.PNG
Capture.PNG (52.78 KiB) Viewed 64 times
User avatar
Tony Li
Posts: 22049
Joined: Thu Jul 18, 2013 1:27 pm

Re: Lua Conditions

Post by Tony Li »

Hi,

Are there any errors or warnings in the Console window?

Temporarily set the Dialogue Manager's Other Settings > Debug Level to Info. When your code gets to Lua.RegisterFunction, look for a log in the Console that reports that the function is registered.

What GameObject is the script on? Is the scene name correct?
Post Reply