<p dir="ltr">What about having an if statement that detects clone object and if so, compensates for $2 discrepancy and assigns $1 to it instead and increments from there? This way the discrepancy is internalized as opposed to something user needs to deal with.</p>
<p dir="ltr">-- <br>
Ivica Ico Bukvic, D.M.A.<br>
Associate Professor<br>
Computer Music<br>
ICAT Senior Fellow<br>
Director -- DISIS, L2Ork<br>
Virginia Tech<br>
School of Performing Arts – 0141<br>
Blacksburg, VA 24061<br>
(540) 231-6139<br>
<a href="mailto:ico@vt.edu">ico@vt.edu</a><br>
<a href="http://www.performingarts.vt.edu">www.performingarts.vt.edu</a><br>
<a href="http://disis.icat.vt.edu">disis.icat.vt.edu</a><br>
<a href="http://l2ork.icat.vt.edu">l2ork.icat.vt.edu</a><br>
<a href="http://ico.bukvic.net">ico.bukvic.net</a></p>
<div class="gmail_quote">On May 11, 2016 11:50, "Miller Puckette" <<a href="mailto:msp@ucsd.edu">msp@ucsd.edu</a>> wrote:<br type="attribution"><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">I gave this some thought but couldn't come up with anything more natural than<br>
the "$1" idea.  It allows for changing the other arguments more easily than<br>
it would have been if the instance number were passed last.  Also, somehow<br>
it felt more natural to have the instance number first.<br>
<br>
If there's interest in the idea, I could add arrguments to change the<br>
behavior (such as putting $1 last instead of first)...  Offhand I doubt that<br>
would get used much though.<br>
<br>
cheers<br>
Miller<br>
<br>
<br>
<br>
On Wed, May 11, 2016 at 05:26:21PM +0200, Christof Ressi wrote:<br>
> There's also a pitfall: additional creation arguments for the cloned abstraction will start with $2.<br>
> For example, in [clone 16 my-abstraction 1 5 9] '1' will be parsed as $2, '5' as $3, '9' as $4 etc.<br>
> No problem, if the abstraction was written for being used with [clone], but bad when cloning existing abstractions.<br>
><br>
> I'm wondering if there could be a way to get the abstraction ID without messing up existing abstractions... Maybe have a dedicated object?<br>
><br>
> For now, I think it's important to mention the parsing of additional creation arguments in the help file.<br>
><br>
> Christof<br>
><br>
> > Gesendet: Mittwoch, 11. Mai 2016 um 16:25 Uhr<br>
> > Von: "IOhannes m zmoelnig" <<a href="mailto:zmoelnig@iem.at">zmoelnig@iem.at</a>><br>
> > An: <a href="mailto:pd-list@lists.iem.at">pd-list@lists.iem.at</a><br>
> > Betreff: Re: [PD] [clone]'s instance number<br>
> ><br>
> > On 2016-05-11 16:18, Liam Goodacre wrote:<br>
> > > Would it be possible to access [clone]'s unique instance number from within the patch, a bit like a creation argument? This could be used to achieve differentiation between the abstractions, ie. if the abstraction contains "tabread4~ $-1.array" and the $-1 is replaced with the instance number, then each instance could read a different file. Of course there are other ways of doing this, but it would be neat to do it with clone, and I'm wondering if there's a way.<br>
> ><br>
> ><br>
> > isn't this what $1 is already doing in clone's instances?<br>
> ><br>
> ><br>
> > fgasdmr<br>
> > IOhannes<br>
> ><br>
> > _______________________________________________<br>
> > <a href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br>
> > UNSUBSCRIBE and account-management -> <a href="https://lists.puredata.info/listinfo/pd-list" rel="noreferrer" target="_blank">https://lists.puredata.info/listinfo/pd-list</a><br>
> ><br>
><br>
> _______________________________________________<br>
> <a href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br>
> UNSUBSCRIBE and account-management -> <a href="https://lists.puredata.info/listinfo/pd-list" rel="noreferrer" target="_blank">https://lists.puredata.info/listinfo/pd-list</a><br>
<br>
_______________________________________________<br>
<a href="mailto:Pd-list@lists.iem.at">Pd-list@lists.iem.at</a> mailing list<br>
UNSUBSCRIBE and account-management -> <a href="https://lists.puredata.info/listinfo/pd-list" rel="noreferrer" target="_blank">https://lists.puredata.info/listinfo/pd-list</a><br>
</blockquote></div>