mirror of
https://github.com/luanti-org/luanti.git
synced 2025-09-30 19:22:14 +00:00
Merge branch 'luanti-org:master' into skybox
This commit is contained in:
commit
770ead7624
111 changed files with 1815 additions and 1848 deletions
|
@ -65,6 +65,8 @@
|
|||
#include "gettext.h"
|
||||
#include "util/tracy_wrapper.h"
|
||||
|
||||
#include <csignal>
|
||||
|
||||
class ClientNotFoundException : public BaseException
|
||||
{
|
||||
public:
|
||||
|
@ -586,14 +588,16 @@ void Server::start()
|
|||
R"(| | |_| | (_| | | | | |_| |)",
|
||||
R"(|_|\__,_|\__,_|_| |_|\__|_|)",
|
||||
};
|
||||
|
||||
if (!m_admin_chat) {
|
||||
// we're not printing to rawstream to avoid it showing up in the logs.
|
||||
// however it would then mess up the ncurses terminal (m_admin_chat),
|
||||
// so we skip it in that case.
|
||||
for (auto line : art)
|
||||
std::cerr << line << std::endl;
|
||||
for (size_t i = 0; i < ARRLEN(art); ++i)
|
||||
std::cerr << art[i] << (i == ARRLEN(art) - 1 ? "" : "\n");
|
||||
// add a "tail" with the engine version
|
||||
std::cerr << " ___ " << g_version_hash << std::endl;
|
||||
}
|
||||
|
||||
actionstream << "World at [" << m_path_world << "]" << std::endl;
|
||||
actionstream << "Server for gameid=\"" << m_gamespec.id
|
||||
<< "\" listening on ";
|
||||
|
@ -1591,11 +1595,10 @@ void Server::SendShowFormspecMessage(session_t peer_id, const std::string &forms
|
|||
(it->second == formname || formname.empty())) {
|
||||
m_formspec_state_data.erase(peer_id);
|
||||
}
|
||||
pkt.putLongString("");
|
||||
} else {
|
||||
m_formspec_state_data[peer_id] = formname;
|
||||
pkt.putLongString(formspec);
|
||||
}
|
||||
pkt.putLongString(formspec);
|
||||
pkt << formname;
|
||||
|
||||
Send(&pkt);
|
||||
|
@ -3394,6 +3397,9 @@ bool Server::showFormspec(const char *playername, const std::string &formspec,
|
|||
if (!player)
|
||||
return false;
|
||||
|
||||
// To allow re-sending the same inventory formspec.
|
||||
player->inventory_formspec_overridden = formname.empty() && !formspec.empty();
|
||||
|
||||
SendShowFormspecMessage(player->getPeerId(), formspec, formname);
|
||||
return true;
|
||||
}
|
||||
|
@ -4113,7 +4119,7 @@ std::unique_ptr<PlayerSAO> Server::emergePlayer(const char *name, session_t peer
|
|||
return playersao;
|
||||
}
|
||||
|
||||
void dedicated_server_loop(Server &server, bool &kill)
|
||||
void dedicated_server_loop(Server &server, volatile std::sig_atomic_t &kill)
|
||||
{
|
||||
verbosestream<<"dedicated_server_loop()"<<std::endl;
|
||||
|
||||
|
@ -4282,7 +4288,7 @@ ModStorageDatabase *Server::openModStorageDatabase(const std::string &world_path
|
|||
warningstream << "/!\\ You are using the old mod storage files backend. "
|
||||
<< "This backend is deprecated and may be removed in a future release /!\\"
|
||||
<< std::endl << "Switching to SQLite3 is advised, "
|
||||
<< "please read https://wiki.luanti.org/Database_backends." << std::endl;
|
||||
<< "please read https://docs.luanti.org/for-server-hosts/database-backends." << std::endl;
|
||||
|
||||
return openModStorageDatabase(backend, world_path, world_mt);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue