IOhannes stuck [once] into the purepd library. I started that library as a DEVELOPMENT library to explore ideas of how to implement things in Pd. IOhannes replaced my code with [once] without asking me. That's bad CVS etiquette. But [once] was an improvement on what was there. I want to improve it further but you guys are blocking me. So here's what I say: purepd will remain a DEVELOPMENT library. If you want a static, unchanging [once], please include it elsewhere, like zexy. If you want a place to freely explore implementing things in Pd, please include it in the purepd library. Then as interfaces and ideas get solidified, they can be moved elsewhere.
.hc
On Sep 13, 2006, at 7:16 PM, Frank Barknecht wrote:
Hallo, Hans-Christoph Steiner hat gesagt: // Hans-Christoph Steiner wrote:
[once] controls flow. It should take a float argument like [spigot] and [gate] so you can choose the default state. No argument implies an argument of 0. Therefore it makes sense that [once] would be default closed.
But then it wouldn't be [once] anymore, as I already remarked.
If you want it to be default open, you can easily do [once 1].
Changing the behaviour of [once] would force anyone who was using [once] to change their patches.
I guess we all agree that adding an argument to [once] can be considered, however IOhannes and I both don't want this if it changes the default behaviour.
As a compromise why not let [once] stay the way it is and as it's used, but instead introduce a new object with a new name. I thought a bit about this, and *if* we want an argument to [once], then this argument should be used for a little bit more than just selecting open or close. The most natural use for an argument I could come up with was to select, after how many incoming messages the object should close. Of course then the name [once] wouldn't be useful anymore as we would also have a reaction to messages coming in "more than once".
So my idea for this object is like this:
[the_object_previously_known_as_once] would close after 0 messages, that is, default is closed just like you wished.
[the_object_previously_known_as_once 1] would be like the old [once]
[the_object_previously_known_as_once 10] would close after 10 in-messages, that is after it has counted down like: 9, 8, 7, 6, 5, 4, 3, 2, 1, liftoff!
That's also the name I finally chose for the new [the_object_previously_known_as_once]:
[countdown]
It's attached.
Ciao
Frank Barknecht _ ______footils.org_ __goto10.org__ <countdown.pd> <countdown-help.pd> _______________________________________________ PD-dev mailing list PD-dev@iem.at http://lists.puredata.info/listinfo/pd-dev
------------------------------------------------------------------------
Computer science is no more related to the computer than astronomy is related to the telescope. -Edsger Dykstra