diff options
author | Loic Blot <loic.blot@unix-experience.fr> | 2015-02-14 23:23:54 +0100 |
---|---|---|
committer | Loic Blot <loic.blot@unix-experience.fr> | 2015-02-14 23:23:54 +0100 |
commit | 346652a80986d13fdf83705c8cf41ccdeee3f2b9 (patch) | |
tree | 7c8638db23fec41f8b3b7af3b10765e5ef880aed /builtin/mainmenu | |
parent | 7880ff74b65040ccb90bc30ba520d4a4215d45a0 (diff) | |
download | minetest-346652a80986d13fdf83705c8cf41ccdeee3f2b9.tar.gz minetest-346652a80986d13fdf83705c8cf41ccdeee3f2b9.tar.bz2 minetest-346652a80986d13fdf83705c8cf41ccdeee3f2b9.zip |
Fix issue #2278, Connection sent before address data loading
Diffstat (limited to 'builtin/mainmenu')
-rw-r--r-- | builtin/mainmenu/tab_multiplayer.lua | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/builtin/mainmenu/tab_multiplayer.lua b/builtin/mainmenu/tab_multiplayer.lua index 734cb5d3e..f4c5b22b0 100644 --- a/builtin/mainmenu/tab_multiplayer.lua +++ b/builtin/mainmenu/tab_multiplayer.lua @@ -198,8 +198,9 @@ local function main_button_handler(tabview, fields, name, tabdata) return true end - if fields["btn_mp_connect"] ~= nil or - fields["key_enter"] ~= nil then + if (fields["btn_mp_connect"] ~= nil or + fields["key_enter"] ~= nil) and fields["te_address"] ~= nil and + fields["te_port"] ~= nil then gamedata.playername = fields["te_name"] gamedata.password = fields["te_pwd"] |