Doh!

I missed that one too...
I still generally find it more useful to manually name the outputs though- 
makes it easier to tell what they're for.

a|x
http://machinesdontcare.wordpress.com



----- Original Message ----
From: Christopher Wright <[EMAIL PROTECTED]>
To: "lists @ tobyz" <[EMAIL PROTECTED]>
Cc: Quartz Composer Dev List <quartzcomposer-dev@lists.apple.com>
Sent: Monday, 4 August, 2008 1:15:50 AM
Subject: Re: Javascript: Numbered Outputs

> But switching that round won't execute in any form I've thought of  
> so far, but the GUI adapts as you'd expect.
> function (__number outputNumber[2]) main (__number inputNumber)
> {
>     var result = new Object();
>     result.outputNumber[0] = inputNumber;
>     result.outputNumber[1] = inputNumber;
>     return result;
> }
> Am I missing something blindingly obvious, or attempting the  
> "unpossible"?



function (__number outputNumber[2]) main(__number inputNumber)
{
    var result = new Object();
    result.outputNumber = new Array(2);
    result.outputNumber[0] = inputNumber;
    result.outputNumber[1] = inputNumber;
    return result;
}

Don't forget to allocate arrays before you assign values to them :)

--
[ christopher wright ]
[EMAIL PROTECTED]
http://kineme.net/


      __________________________________________________________
Not happy with your email address?.
Get the one you really want - millions of new email addresses available now at 
Yahoo! http://uk.docs.yahoo.com/ymail/new.html
 _______________________________________________
Do not post admin requests to the list. They will be ignored.
Quartzcomposer-dev mailing list      (Quartzcomposer-dev@lists.apple.com)
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