Page 1 of 1

Arcweave Import and lua scripts

Posted: Tue Dec 06, 2022 5:47 am
by brave_chris
Hi Tony,

Our game uses lots of custom lua scripts. Is there a way of adding them to nodes when importing from arcweave? I trued [SCRIPT: <lua_function>] but doesn't work. [SEQUENCE: <sequencer_command>] works but I don't want to have to create sequencer commands for every lua script we have.

Also regarding the Sequence keyword. When we have it on an arcweave node that uses the | pipe symbol to split into separate dialogue nodes, it puts the sequence command on every node.

Image

Re: Arcweave Import and lua scripts

Posted: Tue Dec 06, 2022 8:19 am
by Tony Li
Hi,

Wherever you can use Arcscript in Arcweave (e.g., conditional branches), you can use your Lua functions. Arcweave may warn you that it's not valid Arcscript, but it will import fine as Lua into the dialogue database in Unity. The importer also translates most Arcscript into Lua, too, so you can write your variable checks, etc., in Arcscript if you prefer. You can also use all Arcscript functions except reset() and resetAll(). (Make sure to add an ArcweaveLua component to your Dialogue Manager to support the Arcscript functions.)

Re: Arcweave Import and lua scripts

Posted: Tue Dec 06, 2022 9:59 am
by brave_chris
That works really well. Thank you so much!

Re: Arcweave Import and lua scripts

Posted: Tue Dec 06, 2022 10:57 am
by Tony Li
Happy to help!