You cannot use "Gosub Items:"....
You have to leave out the colon (
when using goto or gosub...
AND the sub shoul be outside the while-endwhile loop. Else it would be executed once every loop and twice every time you press key nr 28.
This is your code in fixed version: (have not testet)
while ypos=580
if downkey()=1
REM What is the meaning of Increasing something with 0
inc ypos,0
inc y,0
EndIf
ypos=y+492
if upkey()=1
dec ypos,22
dec y,22
EndIf
If keystate(28)=1 then gosub items
endwhile
items:
Load image "magicitem.bmp",56
Sprite 56,0,480,56
Set sprite 56,1,0
Stretch sprite 56,129,99.7
sprite 56,0,480,56
Set sprite 56,1,0
show sprite 56
if keystate(48)=1
hide sprite 56
delete sprite 56
endif
return