Browse files

port trouble: leader automatically publishes ports after connect

  • Loading branch information...
1 parent 91df639 commit 5354278c36e343841f6ebe24abaaccc0c0494c26 @cappelnord committed Feb 21, 2012
Showing with 3 additions and 4 deletions.
  1. +0 −2 MandelClock.sc
  2. +3 −2 MandelNetwork.sc
View
2 MandelClock.sc
@@ -130,8 +130,6 @@ MandelClock {
followSkipJack.stop;
instance = MandelClock.new(name, message[4], message[5], message[1].asString,[port], false, timeClass:timeClass, server:server);
- instance.net.sendPublishPorts;
-
("... you are now following " ++ message[1].asString ++ "!").postln;
action.value(instance);
View
5 MandelNetwork.sc
@@ -81,6 +81,7 @@ MandelNetwork : MandelModule {
this.addOSCResponder(\leader, "/requestPort", {|header, payload|
this.addPort(payload[0].asInteger);
mc.post(header.name ++ " requested port " ++ payload[0]);
+ this.sendPublishPorts;
});
this.addOSCResponder(\leader, "/publishPorts", {|header, payload|
@@ -104,7 +105,7 @@ MandelNetwork : MandelModule {
sendSystemPorts {
var intKeys = (addrDict.keys.collect{|i| i.asInteger}).asArray;
- this.sendMsgBurst("/systemPorts", \critical, *intKeys);
+ this.sendMsgBurst("/systemPorts", \critical, *intKeys);
}
sendPublishPorts {
@@ -131,7 +132,7 @@ MandelNetwork : MandelModule {
};
addList.do {|item|
- addrDict.add(ass);
+ addrDict.add(item);
};
}

0 comments on commit 5354278

Please sign in to comment.