Math.anything? in javascript object

Apr 25, 2011 at 7:52am

Math.anything? in javascript object

I know the Math object is built into javascript, but I’d really like to believe that my patch keeps failing because my calls to Math.sin and Math.cos in my js object aren’t working. So I’m wondering do I need to put the math library in my patch folder and a call to it in the js file. Or is there something else wrong with my patch : (

Apr 25, 2011 at 8:09am

in short-

  1. testfunction.js
Apr 25, 2011 at 1:23pm

I didn’t look at your Max patch, but in your JavaScript, you use a “^” operator, which I’m guessing you intend as a “to the power of” operator. See instead Math.pow(x,y).

May 29, 2011 at 1:32am

that fixed it. thanks christopher!


You must be logged in to reply to this topic.