////////////////////////////////////////////////////////////// //impulse network part ( var nodes, me; me = "john"; OSCPort.closeAll; nodes = OSCNode.tree([ [\hello, {arg node, mess; mess.postln; } ], [\click, { arg node, dur=0; z.source = dur; p.gate }] ]); OSCInPort.new(55555, nodes); n = [\julian, \john, \ianmike, \pavellloyd, \free]; x = ["192.168.0.120", "192.168.0.116","192.168.0.93","192.168.0.122","192.168.0.123"]; x = x.collect({ arg ip; OSCOutPort.new(55555, ip); }); f = { arg who, message, a, b, c; x.at(n.indexOf(who)).send(message, a, b, c); }; g = {arg who, string; f.value(who, "/hello", me ++ ": " ++ string); }; b = {arg string; x.do({ arg port; port.send("/hello", me ++ ": " ++ Char.tab ++ string) }); }; ) ( Synth.play({ var out; p = Plug.ar(0,0); z = Plug.kr(1); out = Klank.ar(`[[600, 471, 353, 723], [0, 1, 0], [2.0, 2.0, 2.5]], p, 1, 0, z); out.abs }); ) p.gate; Task({ 12.do({ f.value(\pavellloyd, "/click", 0.7); 0.1.wait; }); }); Task({ 15.do({ f.value(\julian, "/click", 0.05); 0.6.wait; }); }); Task({ 15.do({ f.value(\ianmike, "/click", 0.08); 0.4.wait; }); }); Task({ 5.do({ f.value(\free, "/click", 0.4); 0.1.wait; }); }); p.gate(1.0, 0.1) g.value(\julian, "thats it"); g.value(\ianmike, "bugaboo"); g.value(\pavellloyd, "bugaboo man"); g.value(\free, "/hello", "you there"); b.value("clickable planet"); b.value("I am sitting 1000 miles away???"); b.value("milos is watching"); f.value(\julian, "/click", 3.0); f.value(\free, "/click", 0.01); f.value(\ianmike, "/click", 0.01); f.value(\pavellloyd, "/click", 0.01); ------------------------------/* authors so far: */ |