Hello everyone, this is the code that I want it to work.
console.log((runtime.objects.dialog_array[0][LoopIndex]))
After you have the array instance,
Use the method:
getAt(x, y = 0, z = 0)
Retrieve an element from the array at the given X, Y and Z co-ordinates. For one or two dimensional access, the later parameters can be omitted as they default to 0.
Example for Array object:
let myArray = runtime.objects.Array.getFirstInstance() myArray.setSize(10,1,1) myArray.setAt("dog",4) console.log(myArray.getAt(4)) console.log(myArray.getAt(2)) console.log(myArray.width) output: dog 0 10
construct.net/en/make-games/manuals/construct-3/scripting/scripting-reference/plugin-interfaces/array
thank you, it work!
I have another question. How to get and set last created text object? I tried for a long time but it doesn't work
Develop games in your browser. Powerful, performant & highly capable.
Thank you so much!