mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-10-11 05:26:24 +02:00
Debugger: Add version event for future proofing.
Game isn't precisely right, but it's close enough.
This commit is contained in:
1 parent
05c560b52d
commit
b756d92139
3 files changed
+21
No files matched your search
@@ -22,6 +22,7 @@
|
||||
|
||||
void *WebSocketGameInit(DebuggerEventHandlerMap &map) {
|
||||
map["game.status"] = &WebSocketGameStatus;
|
||||
map["version"] = &WebSocketVersion;
|
||||
|
||||
return nullptr;
|
||||
}
|
||||
@@ -49,3 +50,18 @@ void WebSocketGameStatus(DebuggerRequest &req) {
|
||||
}
|
||||
json.writeBool("paused", GetUIState() == UISTATE_PAUSEMENU);
|
||||
}
|
||||
|
||||
// Notify debugger version info (version)
|
||||
//
|
||||
// Parameters:
|
||||
// - name: string indicating name of app or tool.
|
||||
// - version: string version.
|
||||
//
|
||||
// Response (same event name):
|
||||
// - name: string, "PPSSPP" unless some special build.
|
||||
// - version: string, typically starts with "v" and may have git build info.
|
||||
void WebSocketVersion(DebuggerRequest &req) {
|
||||
JsonWriter &json = req.Respond();
|
||||
json.writeString("name", "PPSSPP");
|
||||
json.writeString("version", PPSSPP_GIT_VERSION);
|
||||
}
|
||||
Reference in new issue
Block a user