Send/return an array.

Blitz3D Forums/Blitz3D Beginners Area/Send/return an array.

Thanks for your reply Dreamora.
I changed my array to * Global hImages[iNumRotation]
and the function as follows, and a lot of changes to the rest of my code.
Function CreateRotatedImages(sImage$,iNumRotation,hImages[iNumRotation])
	
	Local hTemp = LoadImage(sImage$)
		If hTemp = 0 Then RuntimeError "Can't find image - load error!!"
	MaskImage hTemp,255,0,255
	Local iMultiplyer = 360 / iNumRotation
	
	; rotate image to generate all directions
	For iLoop = 0 To iNumRotation - 1
	
        ; first copy the original image into the current frame
    	hImages[iLoop]=CopyImage( hTemp )
        ; rotate the frame the appropriate number of degrees
        RotateImage hImages[iLoop], iLoop * iMultiplyer 
    	 
	Next
	
	FreeImage hTemp : hTemp = 0
	
End Function


Remember if anyone else uses "Blitz arrays", if you call the function above, you must call for it like this " Function CreateRotatedImages("bitmap.bmp", iNumRotation, hImages)