Hello,
I'm building a plugin for my game and I was wondering (I haven't found an answer in the docs 😢).
When I want to use an array in the @arg section of the script, to add multiple variables to that argument (more like, being able to add or delete some in the plugin command) I have to declare it's type as @type variable[].
In the module, it works great, I can now add or remove variables to said argument.
But the problem I encounter now is, I can't seem to retrieve data from that argument.
The logical thing to do (to me) is to call for
However, the console is showing me a value of 0. 😢
I gave a random value to all 3 called variables, but the console still shows a 0.
I tried with and without index, but it gives me the same result.
Can someone please help me out on this one?
It would be so great to be able to call different array of variables on seperate plugin commands with the same script.
Thanks for your help. 👋
I'm building a plugin for my game and I was wondering (I haven't found an answer in the docs 😢).
When I want to use an array in the @arg section of the script, to add multiple variables to that argument (more like, being able to add or delete some in the plugin command) I have to declare it's type as @type variable[].
In the module, it works great, I can now add or remove variables to said argument.
The logical thing to do (to me) is to call for
JavaScript:
$gameVariables.value(args.fieldArray[0])
I gave a random value to all 3 called variables, but the console still shows a 0.
I tried with and without index, but it gives me the same result.
Can someone please help me out on this one?
It would be so great to be able to call different array of variables on seperate plugin commands with the same script.
Thanks for your help. 👋