y-lohse / inkjs

A javascript port of inkle's ink scripting language.
http://www.inklestudios.com/ink/
MIT License
503 stars 101 forks source link

loading from json instead on from ink breaks the external function binding #1082

Open DrAlta opened 1 month ago

DrAlta commented 1 month ago

Describe the bug

the value return in a now some type of object, it can't be converted into a Value

Environment

Additional context

I've inherited the code base after the previous programmer left. and ink.js docs don't really documenting it more than saying, "It's a port of ink! you're an expert, right? in the original and in porting C# to js so you can figure it out."

smwhr commented 4 weeks ago

Can you provide a reproducible sample of code showing the problem ?

DrAlta commented 3 weeks ago

Sorry it took so long to get back to you, been crunching at work.

Here's the RPG maker MV plugin. I added the original version of the code I changed in a comment It's just the build and construct method of the InkFactory class

NG_InkManager.zip

InkScene.setupScene("knot")

then does a loop call InkScene.next() until InkScene.isDone() is true

If I understood the code enough to make MRE I could probably fix it myself