Functions and returns

Blitz3D Forums/Blitz3D Programming/Functions and returns

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.

Hi! Try this:

Dim array(3)

DoSomeTransform(8,6,5)

Function DoSomeTransform(x1, y1, z1)
	array(1) = x1 + 2
	array(2) = y1 + 4
	array(3) = z1 + 5
End Function


Now 'array' have the modified values. As Rob said, arrays are globals.