SetMaskColor and GrabImage

BlitzMax Forums/BlitzMax Beginners Area/SetMaskColor and GrabImage

The forum is locked. These are the original blitzbasic.com forums, kept so they can still be read. No new topics, replies or edits can be made here. To join in, head over to the Blitz3D+ forums.

Ok - I have got it working. In case anyone is interested:
Function TilesLoad()
	Local Palette:TImage
	Local TileW%
	Local k%
	
	SetMaskColor 192,192,255
	Palette=LoadImage("Palette.tmp")
	If Palette<>Null Then
		TileW%=TileSize%-1
		SetBlend ALPHABLEND
		For k%=0 To MaxTiles%-1
			Tiles[k%+1]=LoadImage(PixmapWindow(LockImage(Palette),k%*TileW%,0,TileW%,TileW%))
		Next
		Palette=Null
		GCCollect
	EndIf
EndFunction