I'd like to store numbers to choose from randomly in a text variable. The numbers would be separated by commas, and this would allow me to have as many or as little choices to choose from. Is there a way of passing a text variable to choose()? If not, can multiple values separated by commas in an instance text variable have the numbers randomised and passed on?
I don't understand the need for the text, you would just set choose(a,b,c,d,e,f) right? Or are you saying the values are unknown or change during the game?
Develop games in your browser. Powerful, performant & highly capable.
Okay, thanks to Carnage I managed to do it with
int(tokenat(Object.StringVar, floor(random(tokencount(Object.StringVar, ","))), ","))