From 598bd4332deddd5f4c506689cbd136f495835ea7 Mon Sep 17 00:00:00 2001 From: ubq323 Date: Sun, 18 Jun 2023 03:34:03 +0100 Subject: actually send the username --- client/game.lua | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'client/game.lua') diff --git a/client/game.lua b/client/game.lua index 31e02b8..c5cdffb 100644 --- a/client/game.lua +++ b/client/game.lua @@ -343,6 +343,7 @@ end local connected = false local sent_hshake = false +local username = nil function SCENE.update(dt) if connected then return update(dt) @@ -367,11 +368,14 @@ function SCENE.draw() end end -function SCENE.load(username) +function SCENE.load(_username) love.keyboard.setKeyRepeat(true) -- require"profile".start(10,io.open("./trace","w")) host = enet.host_create() peer = host:connect(SERVER_HOSTNAME..":8473",2) + username = _username + print("got username",_username) + end function SCENE.quit() -- cgit v1.2.3