I had tried a few methods in my last post. One line is not necessary. So
this:
on keyDown var
if the stillPressed of me = "true" then exit to top
put var after me
set the stillPressed of me to "true"
end keyDown
on keyup
set the stillPressed of me to "false"
end keyup