What line gives the error?
BUTTON(0,1) might give an error if you are not connected to another system.
Also, instead of
@NMOV
...
GOTO @NMOV
do:
WHILE 1
...
WEND
I think you need to use MPSTART to use terminal selection, even if you're terminal 0 (the host). Since you don't seem to be actually using multiplayer you should get rid of one of the parameters on BUTTON so that it only has 1 or none.
Also, you can assign BUTTON to a variable to avoid having too many BUTTON calls.