bombomby / optick

C++ Profiler For Games
https://optick.dev
MIT License
2.95k stars 296 forks source link

Fix ensure coming from MainFrame module using the editor with -game #152

Closed ymartel06 closed 2 years ago

ymartel06 commented 2 years ago

Hi,

I was wrong when I wrote LevelEditor + MainFrame where unnecessary, but I was right about loading them with the editor and -game don't work. To fix the issue, I've checked what other modules are doing. The best option is to check for the singleton GIsEditor. In editor, it will be valid, in editor with -game or standalone, it will be nullptr.

Note: I've also fixed a missing include in OptickStyle.cpp for FSlateApplication

-Yohann