binji / binjgb

Gameboy emulator implemented in C, that also runs in the browser
https://binji.github.io/binjgb/
MIT License
534 stars 61 forks source link

[Improvement] Capability to logging by pressing key #12

Closed sergey-koryshev closed 6 years ago

sergey-koryshev commented 6 years ago

Hi Ben,

Could you make some change in your emulator to you can enable/disable logging by pressing a key? I mean then I run emulator with '-t' flag it starts to write in trace log, but I need to get trace log in specific time in the game. It would be nice to enable or disable logging to file by pressing a key.

binji commented 6 years ago

Sure! Landed here: https://github.com/binji/binjgb/commit/02d8e582f70d2d9fbde9d6dc4086724d82e140a9

You can use the t key to toggle tracing, and there's also a checkbox in the disassembly window. Tracing doesn't work properly when rewinding, though, so I disabled it by default.

sergey-koryshev commented 6 years ago

Thank you for fast responding! It's working nice!