Project

General

Profile

Actions

Bug #355

open

Amal XS() & YS() report Nan

Added by Nick Morison over 4 years ago. Updated about 3 years ago.

Status:
Resolved
Priority:
High
Target version:
-
Start date:
04/22/2020
Due date:
% Done:

0%

Estimated time:
4:00 h
Affected version:

Description

The below code prints NaN for both variable (tested the same code on Amos and it prints the screen coords of the mouse pointer as expected):

#manifest:"Amiga"
#fullScreen:true
#splashScreen:false

screen open 0,340,256,16,lowres
curs off:flash off: cls 0
colour 1,$005
ink 2
bar 0,0 to 16,16
get bob 1,0,0 to 32,32
cls 1

bob 1,100,100,1
a$="L: Let R0 = XS(0,XM) ; L R1=YS(0,YM) ; P JL"

amal 1,a$
channel 1 to bob 1
amal on 1

Repeat
cls 1
home
print amreg(1,0), amreg(1,1)
wait vbl
Until mouse click

(It prints the hardware coords fine if you change the amal string to a$="L: Let R0 = XM ; L R1=YM ; P JL" )

Actions

Also available in: Atom PDF