Maniac´s debugging features: GetCommandInterpreterState (GetGameInfo), maniac_event_info & more debugging extensions #3349
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
First two commits of this PR were already included with my recent PR :Debug_AssertWay. Basically summed up with refactoring work on existing functionality I implemented in the Interpreter Debug Window that has already been merged for a while; and setting the base with a new Debug namespace inside a new file "game_interpreter_debug.cpp"...
Next up (Commit #3): "Game_Interpreter_Inspector"
Also some refactoring work. This is to clear out some of the "friend classes" I've defined previously. The idea is to only allow access to internal interpreter states via this interface & make it clear that any use of these functions is considered unsafe. (I use this for my new experimental work on trying to translate/patch content of running interpreters. Instead of just declaring "Translation" as just another friend class of Game_Event/Game_CommonEvent/Game_Interpreter/etc. this approach is used..
Then we get to the new stuff:
I've implemented Maniac's "Get Interpreter State" sub-command for "GetGameInfo". This required me to fully implement the "maniac_event_info" field & refactor the way commands are pushed to the interpreter, so that an "ExecutionType" (Action, AutoStart, Parallel, etc..) + the type of event are always known & can be included inside the saved execution state.
I then went the extra route & did some more refactoring, so that all the outside calls to "Interpreter.Push" can be verified at compile time via static_assert´s. So if anyone tries to do something weird, it won't compile.
The rest of the commits concern the Debug Scene`s Interpreter Window again, so the full functionality is restored after the refactoring & so that most of the new available state information is used there.