I'd like some comments on integrating a scripting language with an emulator. My plans are so distant I doubt they'll ever happen, but this may be worth implementing to someone else. Alternately, I may mave my priorities bass-ackwards.
My idea is that a scripting language (compiler, interperter, vm, etc) could be integrated with an emulator so that code written in the target language can effect the emulator. The script would be able to look at emulated memory, keep an arbitrary amount of internal state information and decide whether the emulator loads or saves a state, or what buttons get pressed.
Lua is an example of a language that's designed for integration like this, but I'm sure there are others like
Io or
Pawn that'd work.
There are some advantages to this. Adding scripting to an emulator would be a good way to make robots less frustrating and easier to use. It'd minimize the need for recompiling and restarting the emulator and would also allow for less code to control the robot (since n lines of a scripting language can do more than n lines of C/C++), which would mean less time coding and debugging.
Having a scriptable robot would make everything from fuzz testing and prerecorded macros to an AI easier to write. Depending on the implementation, it could also be used to automatically find RAM values or implement simple features like custom frame counters or a camhack.
The disadvantages are that even the best scripting language is usually slower than C/C++. This might be a significant issue or it might be an acceptable trade-off.
I don't know know if this would be helpful or if it's just a solution looking for a problem. I'd appreciate some thoughts either way.