This tool sounds great! I would like to see it in action. Maybe I can help you to show where the problem is, as I see:
- When you create a new project in Lumberlyard 1.23 it don’t have a precompiled header. So the .pch file for this project is not generated at all and CppHotReload fires abort in CppHotReloadConfig.cpp at 345 line:
if (foundPch.empty()) abort() - that’s why a new project don’t start.
Also the project code is not stored in /dev/Code/PROJECT_NAME/ folder (but it is in /dev/PROJECT_NAME/Gem/Code/). As I see generated object for it are stored in /dev/BinTemp/LUMBERYARD_BIN_CONFIG_DIR/PROJECT_NAME/Gem/Code/ (/Source as project structure etc.) folder.
The StarterGame is an exception. It contains precompiled header, store code in /dev/Code/PROJECT_NAME/Game folder It have .pch file in dev\BinTemp\win_x64_vs2017_debug\Code\StarterGame\Game folder. So it’s look’s like good candidate for test CppHotReload tool. So I added a CppHotReload gem to it. Configure and recompile project. I sucessfully started Editor with the following logs:
(C++ Hot Reload) - sys_game_folder=StarterGame, crc: 4136858
(C++ Hot Reload) - Reading include file…
(C++ Hot Reload) - Applying environment macros…
[Error] (C++ Hot Reload) - Timeout: connect timed out: [2001:41d0:302:2100::2ac2]:80
[Error] (C++ Hot Reload) - Your C++ Hot Reload license cannot be validated, please contact to: email@example.com
[Error] (C++ Hot Reload) - Something went wrong initializing C++ HotReload!
and after load a level I get such exception in CppHotReloadGem.cpp file at 97 line:
if (!CppHotReload::IsWorking()) :
Assertion failed! … Expression: cppHotReload && "C++ Hot Reload not initialized!"
and in some case in line 221:
const AZStd::string& guid = CppHotReload::RegisterPtr(typeName.c_str(), reinterpret_cast<void*>(currComponent));
exception: 0x00007FF8AB9C46F0 (HotReload_x64_md.dll)
I hope this will help to fix it because I really want to see it in action
ps. PROJECT_NAME is not variable/constant, I just use it for any project folder.