diff options
-rw-r--r-- | src/guiMainMenu.cpp | 4 | ||||
-rw-r--r-- | src/server.cpp | 3 |
2 files changed, 6 insertions, 1 deletions
diff --git a/src/guiMainMenu.cpp b/src/guiMainMenu.cpp index 2d5bd151a..fde71e4bc 100644 --- a/src/guiMainMenu.cpp +++ b/src/guiMainMenu.cpp @@ -196,6 +196,8 @@ void GUIMainMenu::regenerateGui(v2u32 screensize) gui::IGUIEditBox *e = Environment->addEditBox(L"", rect, true, this, 264); e->setPasswordBox(true); + if(text_name != L"" && text_address != L"") + Environment->setFocus(e); } changeCtype(""); @@ -212,7 +214,7 @@ void GUIMainMenu::regenerateGui(v2u32 screensize) rect += topleft_client + v2s32(160, 100); gui::IGUIElement *e = Environment->addEditBox(text_address.c_str(), rect, true, this, GUI_ID_ADDRESS_INPUT); - if(text_name != L"") + if(text_name != L"" && text_address == L"") Environment->setFocus(e); } { diff --git a/src/server.cpp b/src/server.cpp index daa1e5d86..14d8942cb 100644 --- a/src/server.cpp +++ b/src/server.cpp @@ -3198,6 +3198,9 @@ void Server::ProcessData(u8 *data, u32 datasize, u16 peer_id) mlist->addItem(item1); } } + // Disallow moving items if not allowed to build + else if((getPlayerPrivs(player) & PRIV_BUILD) == 0) + return; } if(disable_action == false) |