mirror of
https://github.com/luanti-org/luanti.git
synced 2025-06-27 16:36:03 +00:00
Clean up server-side translations, remove global variable (#10075)
This commit is contained in:
parent
c8303f790c
commit
9ec75d7765
9 changed files with 50 additions and 65 deletions
|
@ -38,6 +38,7 @@ with this program; if not, write to the Free Software Foundation, Inc.,
|
|||
#include "serverenvironment.h"
|
||||
#include "clientiface.h"
|
||||
#include "chatmessage.h"
|
||||
#include "translation.h"
|
||||
#include <string>
|
||||
#include <list>
|
||||
#include <map>
|
||||
|
@ -343,8 +344,8 @@ public:
|
|||
// Send block to specific player only
|
||||
bool SendBlock(session_t peer_id, const v3s16 &blockpos);
|
||||
|
||||
// Load translations for a language
|
||||
void loadTranslationLanguage(const std::string &lang_code);
|
||||
// Get or load translations for a language
|
||||
Translations *getTranslationLanguage(const std::string &lang_code);
|
||||
|
||||
// Bind address
|
||||
Address m_bind_addr;
|
||||
|
@ -557,6 +558,8 @@ private:
|
|||
// Mods
|
||||
std::unique_ptr<ServerModManager> m_modmgr;
|
||||
|
||||
std::unordered_map<std::string, Translations> server_translations;
|
||||
|
||||
/*
|
||||
Threads
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue