Trying to fade a graphic in on a roScreen.
trans=00
inc =5
while true
msg=wait(50, m.port)
trans=trans+inc
ba=createobject("roByteArray")
ba.push(255)
ba.push(255)
ba.push(255)
ba.push(int(trans))
hexcolor="&h" + ba.tohexstring()
? hexcolor
screen.drawobject( 410, 240, saverbitmap, hexcolor) 'LOGO
screen.swapbuffers()
End while
the byte array is incrementing properly
&hFFFFFF0D
&hFFFFFF12
&hFFFFFF17
&hFFFFFF1C
&hFFFFFF21
etc.
I am getting a type mismatch on the hexcolor variable above on the screen.drawobject line.
hexcolor &h8010 bsc:roString (2.1 was String), refcnt=1
I suspect it is some sort of issue between strings and integers but don't know how to deal with this with a hex value.
if i paste in a value from what the bytearray is outputting it shows the graphic fine.
would appreciate any help thanks.
Kinetics Screensavers