In many ways, this task looks similar to the experiment performed with the Supertool.
Only, in addition to checking for a Patrilinal surname match, you would want to check for for the existence of a Family Nick Name. Then post that to the child’s Family Nick Name. (The SuperTool example posts data to the child’s primary name’s Origin.)
Test this on the EXAMPLE.GRAMPS not your live data. And once the script works on the example, make a backup before running a script on your main Tree.