New account registration is temporarily disabled.

CAN YOU MAKE ARRAYS IN RM2K3?

Posts

Pages: 1
Does anyone know if there is a way to make arrays in rm2k3 or maybe a clever way to make a variable into an array?
It's not so much arrays plural as it is that the entire set of variables is one big array. If you need an array, you just set aside a chunk (of course it won't be zero-indexed, but that's what you get for using 2k3). One of the options in the variable-change event will let you access the big array using a particular variable as array index.
I want to be able to call an event that changes a specific variable's value based on the array without using x amount of conditional branches or at least an effective method that doesn't require me to spam conditional branches so I can change each possible variable.
you should use the pointers in rm2k3 for that. you can use "variable reference" to access the variable with same ID as the value of the variable you're using as reference, and you can use "Value stored in index" to get the value of the variable with ID equal to the value of the variable you use as reference.
Wow I can't believe I didn't think of that I spent hours trying to find a way to do that instead of looking for an option in the commands. Thanks so much for the help.
If you look for a real arry, with sorting, insertion/removal, etc., you might want to look at Power Patch (in combination with the StdLib-Plugin). You can use the scripting language Lua with your Maker then.
Pages: 1