Message to "set" a ghostbox or change an object on the fly

Every now and then this comes across my mind. Is it possible to change an object with a message. For example i have a [cycle~] and i actually want it to be a [phasor~] I know this can all be done with [this.patcher] and js but it would be nice to change it with a simple message.

Thanks,
FRid

-- Pasted Max Patch, click to expand. --

Copy all of the following text. Then, in Max, select New From Clipboard.

(after i made the example) Ok, it’s not that much of a hassle but it’ll save some objects plus when you change layout you wouldn’t have to update the positions ofcourse this can also be js’d but that is too much trouble (at least for me now)

Thanks for your suggestion but that was not really what i meant because you would still need to have a patch for each object object (plus additional ins/outs) and so forth which is too much of a hassle :)

how do you intend to use this? If you use this in performance you will get clicks as the DSP chain will be interrupted when inserting new audio objects… poly~ is definitely a good way of approaching this for live purposes. I am afraid there is no way around patching, yet ;)

Ehhmmm, you definetely got a point there but it’s something that occurs every time i’m in lazy-mode and fooling around with a new patch and it doesn’t really have a clear goal. That’s when i’d like to have a way to change stuff fast(er). Nevermind, i think i’ll just create some abstractions for this since the applications are limited but all in all it didn’t seem that illogical to already exist in a hidden message somehow/where.