hooking code generation in the orion plug-in