Net setup interf in function

This commit is contained in:
Djeeberjr 2022-03-01 12:56:15 +01:00
parent 3e275e2b06
commit 639392c6de

View File

@ -34,11 +34,15 @@ class Net {
this.interfaces.push(Loopback.instance);
for (interf in interfaces){
setupInterf(interf);
}
}
private function setupInterf(interf: INetworkInterface) {
interf.onMessage.handle(pack -> handle(pack,interf));
interf.listen(networkID);
interf.listen(BRODCAST_PORT);
}
}
/**
Called when a new package comes in.