Closed jetrotal closed 1 year ago
Ghabry commented that this would make the code faster.
For context: When the event is in Game_Interpreter
this will avoid fetching the command a second time via
auto& frame = GetFrame();
const auto& com = frame.commands[frame.current_command];
You can likely not measure the speedup but this code can be executed 10000s of times per second so every nanosecond counts :D.
Minor Change. It's a variation of ExecuteCommand(); that accepts
com
as a parameter.Ghabry commented that this would make the code faster. But, this also open possibilities to create a scripting language, since we can create
com
parameters from strings.This implementation could also be used to attach code from dynRPG patches to new
com
stuff. Having both @comments andcom
commands share the same code.