Process speed correctly in local scripts, fixes #649

Script wasn't being recorded properly, so the speed was never
calculated.