1
0
mirror of https://github.com/luanti-org/luanti.git synced 2025-10-13 08:35:20 +02:00

Server pushing media at runtime (#9961)

This commit is contained in:
sfan5
2020-06-13 19:03:26 +02:00
committed by GitHub
parent 982a030f33
commit 2424dfe007
16 changed files with 263 additions and 85 deletions

View File

@@ -236,6 +236,8 @@ public:
void deleteParticleSpawner(const std::string &playername, u32 id);
bool dynamicAddMedia(const std::string &filepath);
ServerInventoryManager *getInventoryMgr() const { return m_inventory_mgr.get(); }
void sendDetachedInventory(Inventory *inventory, const std::string &name, session_t peer_id);
@@ -435,6 +437,8 @@ private:
// Sends blocks to clients (locks env and con on its own)
void SendBlocks(float dtime);
bool addMediaFile(const std::string &filename, const std::string &filepath,
std::string *filedata = nullptr, std::string *digest = nullptr);
void fillMediaCache();
void sendMediaAnnouncement(session_t peer_id, const std::string &lang_code);
void sendRequestedMedia(session_t peer_id,