Please help a novice with this peculiarity in JS patch.

In the following script the conditional (a > 100) cause a QC crash. (Q1.
Why?) Also a is equal to inputNumber[1] value at end of execution when it
should
be staying the same each loop as in:
a = inputNumber [0] + 1;
(Q2 Why isn't a always = 1?)

function (__number outputNumber) main (__number inputNumber[2])
{
if (!_testMode)
{
var go = new Boolean;
go = true;
while (go)
{
a = inputNumber [0] + 1;
//   offending line
// if (a > 100) causes a QC crash ?!

if (a = inputNumber [1])  // this works though

// the value in inputNumber [1] ends up on screen ?!
// a is not being incremented, it is being assigned ( 0 + 1 ) each loop??
go = false;
}
var result = new Object();
result.outputNumber = a;
return result;
 }
}


Attached the QC file which also has a JS patch feeding back its output to
its input. Takes quite a long time to get to 500 that way...
(Q3 Why is it taking so long when inside the script it get's to 5000 in a
nanosecond)?

Attachment: iterative.qtz
Description: Binary data

 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      ([email protected])
Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/quartzcomposer-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to