Updated NodeThread.java and LocalSimulator.java to fix possible deadlock...

... situation

- Updated NodeThread.java and LocalSimulator.java to fix possible deadlock situation that can arise due to the order nodes are processed.
- New code filters out all UDPNodes that are set up to receive packets, and runs them only after all of the other nodes have finished running.