This is probably another dumb question, but I haven't managed to find a solution in the tutorials or by futzing with the script ...
The first thing I want my little script to do is to create a route object with 6 outputs, which are numbered according to an int sent in the first outlet of js
(the input message is called (offset) )
x = (jsarguments);
z = (jsarguments);
//args 3 & 4 are the patcher location for the [route]. args 1 & 2 are the objects that the route will connect to
list = (1 + offset);
obj = this.patcher.newdefault(x,z,"route",list);
So far, this creates a route object with an argument of the input value plus 1. Based on this I could script separate [route]s for each of the range of input values, but what I want is a single [route 1 2 3 4 5 6] (or whatever). I guess the question is - how do I get an array of values into the newdefault part of the script.