RetroBASIC
Retrogamecoding(.org) => EGSL => Topic started by: Cosmo on February 07, 2014, 11:11:20 PM
-
Hi Markus,
If getkey is not pressed, what is the return value ?
It isn't zero!
e.g
local press=0
repeat
k=getkey()
if k==32 and press==0 then
color(255,255,255)
drawtext (10,10,"HELLO")
press=1
end
sync()
if k==0 then press=0; end
until k==27
closewindow()
-
Maybe a random value? Don't know for sure, that can differ from OS to OS. You can get the value yourself with:
repeat
cls()
drawtext (0,0,getkey())
etc ...
-
Thanks Markus.