Передача ресурсов клиенту

This commit is contained in:
2025-08-27 00:26:11 +06:00
parent 57d6e816fc
commit cfbbfa286a
14 changed files with 313 additions and 190 deletions

View File

@@ -2215,7 +2215,8 @@ void Vulkan::gui_MainMenu() {
std::unique_ptr<Net::AsyncSocket> sock = std::move(ConnectionProgress.Socket);
Game.RSession = std::make_unique<VulkanRenderSession>();
*this << Game.RSession;
Game.Session = std::make_unique<ServerSession>(IOC, std::move(sock), Game.RSession.get());
Game.Session = ServerSession::Create(IOC, std::move(sock));
Game.Session->setRenderSession(Game.RSession.get());
Game.RSession->setServerSession(Game.Session.get());
Game.ImGuiInterfaces.push_back(&Vulkan::gui_ConnectedToServer);
}

View File

@@ -250,7 +250,7 @@ public:
DestroyLock UseLock;
std::thread MainThread;
std::shared_ptr<VulkanRenderSession> RSession;
std::unique_ptr<ServerSession> Session;
ServerSession::Ptr Session;
std::list<void (Vulkan::*)()> ImGuiInterfaces;
std::unique_ptr<ServerObj> Server;