Player movement and sprites

BlitzMax Forums/BlitzMax Beginners Area/Player movement and sprites

Thanks very much...my test program works very well.

Also, "cursor.bmp" is a white plus-like sign I made in Paint. I noticed SetColor applies to it too, even though it is a loaded sprite. Why is this?

EDIT: Here is the complete code of my sample program in case anyone wants it or thinks they could learn from it (note that the music/sound and the cursor image will need to be supplied yourself.)
'Import the MaxMod module
Import MaxMod.ModPlayer' optional (but I like MODs!)
'Set the audio driver
SetAudioDriver("directsound")' optional

'Load the music
music = LoadSound("<filename.extension>")
'Play the music
PlaySound music

'Load the cursor image (commented for now)
'img_cur = LoadImage("<filename.extension>")

'Set up graphics mode
Graphics 640,480,0
HideMouse' hide the mouse

'Mask image
SetMaskColor 255,0,255

Type t_cursor
	Field x:Float = MouseX()
	Field y:Float = MouseY()
	Field img:TImage = LoadImage ("cursor.bmp")
	End Type

'Define string variable
hw$ = "Hello World!"
blk$ = "this is a flashing block"

'Main loop
While Not KeyDown(KEY_ESCAPE)
Cls
'Initiate random number generator
SeedRnd MilliSecs()
'RGB string
rgb$ = "RGB color "+R+","+G+","+B

R=Rnd(255)' random RED
G=Rnd(255)' random GREEN
B=Rnd(255)' random BLUE

'RndColor()

'Draw flashing, color-shifting rectangle
SetColor R,G,B
DrawRect 20,70,200,100
'Draw text
'SetColor 255,255,255' set color back to white (commented for now)
DrawText hw$,20,20
DrawText rgb$,20,40
'Set color to black for this string
SetColor 0,0,0
DrawText blk$,25,110

'set color back to random
SetColor R,G,B
'create t_cursor instance
cursor:t_cursor = New t_cursor
'draw cursor
DrawImage cursor.img,cursor.x,cursor.y

Flip

Wend
End

'Function definitions (commented for now)
'Function RndColor()
'	R=Rnd(255)' random RED
'	G=Rnd(255)' random GREEN
'	B=Rnd(255)' random BLUE
'End Function