From 0bfda86c29d106df5fa3dd16d925c193b3f726c7 Mon Sep 17 00:00:00 2001 From: Daniel Weipert Date: Mon, 25 Dec 2023 00:21:50 +0100 Subject: UI + HUD alignment --- Network/Network.gd | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'Network/Network.gd') diff --git a/Network/Network.gd b/Network/Network.gd index 0b3e379..ff076a4 100644 --- a/Network/Network.gd +++ b/Network/Network.gd @@ -14,8 +14,7 @@ const PORT = 10567 const MAX_PEERS = 2 -var peer = null -var ip = null +var peer: ENetMultiplayerPeer = null var player = { idx = 0, @@ -59,7 +58,6 @@ func host_game(player_name): self.peer = ENetMultiplayerPeer.new() self.peer.create_server(self.PORT, self.MAX_PEERS) multiplayer.multiplayer_peer = self.peer - #get_tree().set_multiplayer_peer(self.peer) func join_game(ip, player_name): @@ -67,13 +65,11 @@ func join_game(ip, player_name): self.peer = ENetMultiplayerPeer.new() self.peer.create_client(ip, self.PORT) multiplayer.multiplayer_peer = self.peer - #get_tree().set_multiplayer_peer(self.peer) func leave_game(): rpc("_leave_game") multiplayer.multiplayer_peer = null - #get_tree().set_multiplayer_peer(null) @rpc("any_peer") func _leave_game(): -- cgit v1.2.3