summaryrefslogtreecommitdiffstats
path: root/src/core/core.cpp
diff options
context:
space:
mode:
authorFearlessTobi <thm.frey@gmail.com>2021-12-25 20:27:52 +0100
committerFearlessTobi <thm.frey@gmail.com>2022-07-25 21:59:28 +0200
commit705f7db84dd85555a6aef1e136cf251725cef293 (patch)
treee110c6482a11d711d18515afce4fc50adcee76e7 /src/core/core.cpp
parentnetwork: Add initial files and enet dependency (diff)
downloadyuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar.gz
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar.bz2
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar.lz
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar.xz
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.tar.zst
yuzu-705f7db84dd85555a6aef1e136cf251725cef293.zip
Diffstat (limited to 'src/core/core.cpp')
-rw-r--r--src/core/core.cpp17
1 files changed, 16 insertions, 1 deletions
diff --git a/src/core/core.cpp b/src/core/core.cpp
index 0ede0d85c..5df32c1e7 100644
--- a/src/core/core.cpp
+++ b/src/core/core.cpp
@@ -43,14 +43,15 @@
#include "core/hle/service/service.h"
#include "core/hle/service/sm/sm.h"
#include "core/hle/service/time/time_manager.h"
+#include "core/internal_network/network.h"
#include "core/loader/loader.h"
#include "core/memory.h"
#include "core/memory/cheat_engine.h"
-#include "core/network/network.h"
#include "core/perf_stats.h"
#include "core/reporter.h"
#include "core/telemetry_session.h"
#include "core/tools/freezer.h"
+#include "network/network.h"
#include "video_core/renderer_base.h"
#include "video_core/video_core.h"
@@ -315,6 +316,15 @@ struct System::Impl {
GetAndResetPerfStats();
perf_stats->BeginSystemFrame();
+ std::string name = "Unknown Game";
+ const Loader::ResultStatus res{app_loader->ReadTitle(name)};
+ if (auto room_member = Network::GetRoomMember().lock()) {
+ Network::GameInfo game_info;
+ game_info.name = name;
+ game_info.id = program_id;
+ room_member->SendGameInfo(game_info);
+ }
+
status = SystemResultStatus::Success;
return status;
}
@@ -362,6 +372,11 @@ struct System::Impl {
memory.Reset();
applet_manager.ClearAll();
+ if (auto room_member = Network::GetRoomMember().lock()) {
+ Network::GameInfo game_info{};
+ room_member->SendGameInfo(game_info);
+ }
+
LOG_DEBUG(Core, "Shutdown OK");
}