mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-09-04 19:55:27 +02:00
Cleanup a lot of the bootup state management.
This commit is contained in:
@@ -107,12 +107,15 @@ void WebSocketCPUResume(DebuggerRequest &req) {
|
||||
// - ticks: number of CPU cycles into emulation.
|
||||
void WebSocketCPUStatus(DebuggerRequest &req) {
|
||||
JsonWriter &json = req.Respond();
|
||||
json.writeBool("stepping", PSP_IsInited() && Core_IsStepping() && coreState != CORE_POWERDOWN);
|
||||
|
||||
const bool pspInited = PSP_GetBootState() == BootState::Complete;
|
||||
|
||||
json.writeBool("stepping", pspInited && Core_IsStepping() && coreState != CORE_POWERDOWN);
|
||||
json.writeBool("paused", GetUIState() != UISTATE_INGAME);
|
||||
// Avoid NULL deference.
|
||||
json.writeUint("pc", PSP_IsInited() ? currentMIPS->pc : 0);
|
||||
json.writeUint("pc", pspInited ? currentMIPS->pc : 0);
|
||||
// A double ought to be good enough for a 156 day debug session.
|
||||
json.writeFloat("ticks", PSP_IsInited() ? CoreTiming::GetTicks() : 0);
|
||||
json.writeFloat("ticks", pspInited ? CoreTiming::GetTicks() : 0);
|
||||
}
|
||||
|
||||
// Retrieve all regs and their values (cpu.getAllRegs)
|
||||
|
||||
Reference in New Issue
Block a user