Forums > Java

passing list attributes to a java extern


ufk
December 17, 2012 | 8:18 am

hello
I’m trying to paste a list attribute to a java extern. which means
that i have a java class that extends a MaxObject that in it i have
a private byte[] variable that is named ‘pos’:

example:

class test extends MaxObject {

private byte pos[];

public test {
pos = new byte[]{0,0};
declareAttribute("pos");
}

}

——–

when I call that mxj object from max i call it with mxj test @pos 2,1 but it seems that only the number 2 is passed to it, not 2 and 1.
so when i try to work with the pos array it has a length of 1 instead of 2 after it was modified. any ideas why ?



ufk
December 17, 2012 | 10:23 am

ok oops…
i needed space instead of "," :)


Viewing 2 posts - 1 through 2 (of 2 total)