'use IDE 1.4
'GOTO lspr
Prnt "What you think? Something this?", 1, 10, 10, 20, 15
Prnt "You have many options in QB64...", 2, 10, 500, 20, -15
'lspr:
LOADSPRITE Sprites(), "penguin.jpg", 55, 100, 10, 0, 477
COPYIMAGEARRAY Sprites(), NSprites()
COPYIMAGEARRAY Sprites(), N2Sprites()
ReColor NSprites
(), _RGB32(209, 70, 91), 20, 20, 20, -50, 80, -90ReColor N2Sprites
(), _RGB32(209, 60, 81), 30, 30, 30, -110, 110, 80 f = f + 1
x = StartX
y = StartY
x = x + Xspace
'colorize character:
ColoredChar
= swapcolor
(chars
(ch
), White
, _RGB32(RND * 255, RND * 255, RND * 255)) _PUTIMAGE (x
, y
)-(x
+ (size
* 16), y
+ (size
* (8 * f
))), ColoredChar
, 0
FUNCTION swapcolor
(handle
, oldcolor~&
, newcolor~&
) a& = a& + 4
complete = complete + 1
h = 0
h = h + 4
Cn~&
= _RGB32(R
+ AddtoR
, G
+ AddtoG
, B
+ AddtoB
)
FOR LoadSprte
= 1 TO frames_total
frames
(LoadSprte
) = _NEWIMAGE(lenght
, height
, 32) _PUTIMAGE (0, 0), handle
, frames
(LoadSprte
), (Xstart_offset
+ (LoadSprte
* lenght
), ystartoffset
)-(Xstart_offset
+ (LoadSprte
* 2 * lenght
), ystartoffset
+ height
)