Method for modyfing node score count of packets sent and received

This commit is contained in:
Jedrzej Stuczynski
2020-01-09 16:26:01 +00:00
parent a37d9aedc4
commit 6e52afef79
@@ -88,6 +88,13 @@ impl NodeScore {
packets_received: 0,
}
}
fn test_packet(&mut self, was_successful: bool) {
self.packets_sent += 1;
if was_successful {
self.packets_received += 1;
}
}
}
impl std::fmt::Display for NodeScore {