replace

iterate through the script, looking for replaceable marker opcodes. If a marker is found, call the callback with the marker.

Return

A script with all replacements made.