#N canvas 500 87 558 562 10;
#X obj 2 302 cnv 3 550 3 empty empty inlets 8 12 0 13 -228856 -1 0
;
#X obj 2 399 cnv 3 550 3 empty empty outlets 8 12 0 13 -228856 -1 0
;
#X obj 2 453 cnv 3 550 3 empty empty arguments 8 12 0 13 -228856 -1
0;
#X obj 78 311 cnv 17 3 17 empty empty 0 5 9 0 16 -228856 -162280 0
;
#X obj 78 408 cnv 17 3 17 empty empty 0 5 9 0 16 -228856 -162280 0
;
#X obj 78 333 cnv 17 3 60 empty empty 1 5 9 0 16 -228856 -162280 0
;
#X obj 2 542 cnv 1 550 1 empty empty empty 0 0 0 4 -262144 -262144
0;
#X obj 2 521 cnv 15 552 21 empty empty empty 20 12 0 14 -233017 -33289
0;
#X obj 303 268 print unchanged;
#X text 134 312 anything;
#X text 134 363 anything;
#X text 134 408 anything;
#X obj 78 429 cnv 17 3 17 empty empty 1 5 9 0 16 -228856 -162280 0
;
#X text 134 429 anything;
#X obj 2 5 cnv 15 553 42 empty empty empty 20 12 0 14 -233017 -66577
0;
#N canvas 0 22 450 278 (subpatch) 0;
#X coords 0 1 100 -1 554 42 1 0 0;
#X restore 2 4 graph;
#X obj 305 5 cnv 15 250 40 empty empty empty 12 13 0 18 -128992 -233080
0;
#N canvas 382 141 749 319 (subpatch) 0;
#X coords 0 -1 1 1 252 42 2 100 100;
#X restore 304 4 pd;
#X text 98 333 set <anything>;
#X text 92 462 1) float/symbol;
#X text 92 479 2) float/symbol;
#X text 192 428 - the input message if no substitution occurred;
#X msg 312 198 set 5 10;
#X msg 287 150 this that;
#X obj 138 237 cyclone/substitute that this;
#X obj 138 267 print substituted;
#X text 92 497 3) float/symbol;
#X text 52 91 [substitute] exchanges an element (the first argument)
in an input message to another one (second argument).;
#X text 190 312 - any message to have elements substituted or not;
#X text 192 408 - the substituted message if a substitution occurred
;
#X text 192 462 - the match element that should be replaced (default
0);
#X text 192 479 - the replacement for the match (default 0);
#N canvas 761 94 470 284 first_only 0;
#X text 80 19 [substitute] will replace all recurring elements in a
message \, but if you have a 3rd argument \, it operates in "first
only" mode \, where only the first element is replaced., f 53;
#X obj 248 134 cyclone/substitute foo bar 1;
#X obj 64 134 cyclone/substitute foo bar;
#X obj 64 192 cyclone/prepend set;
#X obj 248 191 cyclone/prepend set;
#X msg 248 227 bang;
#X msg 64 227 bang;
#X msg 248 90 foo 1 foo 2 foo 3;
#X obj 258 162 loadbang;
#X connect 1 0 4 0;
#X connect 2 0 3 0;
#X connect 3 0 6 0;
#X connect 4 0 5 0;
#X connect 7 0 1 0;
#X connect 7 0 2 0;
#X connect 8 0 4 0;
#X connect 8 0 3 0;
#X restore 452 256 pd first_only \; mode;
#X msg 138 168 1 2 3 4 5;
#X msg 115 145 5 5 5 4 4 4;
#X msg 303 174 4 5;
#X obj 17 58 cyclone/comment 0 14 DejaVu\ Sans\ Mono empty 0 0 0 0
0 255 255 255 0 0 Substitute elements in messages;
#X obj 16 5 cyclone/comment 0 33 DejaVu\ Sans\ Mono empty 0 0 0 0 0
255 255 255 0 0 substitute;
#X obj 322 29 cyclone/comment 0 13 DejaVu\ Sans\ Mono empty 0 224 228
220 0 255 255 255 0 0 Objects cloned from Max/MSP;
#X obj 363 5 cyclone/comment 0 24 DejaVu\ Sans\ Mono empty 0 224 228
220 0 255 255 255 0 0 cyclone;
#X text 192 497 - any float or symbol sets susbtitute to "first only"
mode;
#X text 190 333 -;
#X text 202 333 set followed by 2 items sets the 1st element to be
substituted by the 2nd (other elements are ignored);
#X text 190 363 -;
#X text 202 364 sets the 1st element to be substituted by the 2nd \,
other elements are ignored (basically the same as "set");
#X msg 158 197 this and that;
#X connect 22 0 24 1;
#X connect 23 0 24 1;
#X connect 24 0 25 0;
#X connect 24 1 8 0;
#X connect 33 0 24 0;
#X connect 34 0 24 0;
#X connect 35 0 24 1;
#X connect 45 0 24 0;
