MCPcopy Create free account
hub / github.com/Norbyte/bg3se / HandleSetBreakpoints

Method HandleSetBreakpoints

BG3Extender/Osiris/Debugger/DebugMessages.cpp:357–391  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

355 }
356
357 void DebugMessageHandler::HandleSetBreakpoints(uint32_t seq, DbgSetBreakpoints const & req)
358 {
359 DEBUG(" --> DbgSetBreakpoints()");
360
361 ResultCode rc;
362 if (!debugger_) {
363 WARN("SetBreakpoint: Not attached to story debugger!");
364 rc = ResultCode::NoDebuggee;
365 }
366 else
367 {
368 rc = ResultCode::Success;
369
370 debugger_->Breakpoints().BeginUpdatingNodeBreakpoints();
371 for (auto const & bp : req.breakpoint()) {
372 DEBUG("AddBreakpoint(node %d, goal %d, action %d, flags %d)",
373 bp.node_id(), bp.goal_id(), bp.action_index(), bp.breakpoint_mask());
374 rc = debugger_->Breakpoints().AddBreakpoint(
375 bp.node_id(),
376 bp.goal_id(),
377 bp.is_init_action(),
378 bp.action_index(),
379 (BreakpointType)bp.breakpoint_mask()
380 );
381
382 if (rc != ResultCode::Success) {
383 break;
384 }
385 }
386
387 debugger_->FinishUpdatingNodeBreakpoints();
388 }
389
390 SendResult(seq, rc);
391 }
392
393 void DebugMessageHandler::HandleGetDatabaseContents(uint32_t seq, DbgGetDatabaseContents const & req)
394 {

Callers

nothing calls this directly

Calls 3

AddBreakpointMethod · 0.45

Tested by

no test coverage detected