well, I know you guys like scripts

For me it's easier to do it with 'C', see my updated Make_obj project (source & exe) here:
.
f57_b.jpg
As always: use this on your own risk!
Tested with
f57_b.sm and
f01_1a.sm only. So could fail with other sm files!