Added upload and download statistics

This commit is contained in:
2024-01-26 19:00:59 +01:00
parent 8370afd9a1
commit 252d55b30f
10 changed files with 54 additions and 6 deletions

View File

@ -2,6 +2,7 @@ class_name NetworkNode
extends Node
var handlers: Array[Node] = []
var download := 0
func _init():
handlers.resize(256)
@ -21,3 +22,4 @@ func handle_packet(packet: PackedByteArray, peer: PacketPeer):
return
handler.handle_packet(packet.slice(1), peer)
download += packet.size()