In VMP 3 I haven't found a way to do it. Neither CompilationType, nor the object returned by addByAddress has CompilationOptions or something that looks like a key-lock. How do I do it?
No such feature?
Using the UI I can select a protected function and see a "Lock To Serial Number".
Ok, so this is inactive because it's not implemented yet, and thus also not exposed to the script.