"In 3D there is never enough Time to do Things right,
but there's always enough Time to make them *look* right." "psssst! i steal signatures... don't tell anyone! "
Interestingly enough the docs for 4.02 state that SizeOf() only works on structures and not on base types. However, you are right it works fine on base types:
Codefire,
'Long' and 'Quad' are structures. Defining 'myVariable.Long' is not the same as 'myVariable.l'. What you can't do is 'SizeOf(.l)' and the like (although you can get the SizeOf() the variables themselves if the base type is not included, i.e. 'Debug SizeOf(myVariable)' ).
;Base type:
myVariable.l = 42
;Structure:
myVariable2.Long
myVariable2\l = 42
Debug SizeOf(myVariable)
Debug SizeOf(myVariable2)
Debug myVariable
Debug myVariable2 ;Not the long value, but a pointer to a structure.
Debug myVariable2\l ;The actual long value contained in the structure's only element.
"Ahead one third... ahead two thirds... Full ahead flank
And out from the belly of the whale came a prophet, Amen"
Clutch wrote:Codefire,
'Long' and 'Quad' are structures. Defining 'myVariable.Long' is not the same as 'myVariable.l'. What you can't do is 'SizeOf(.l)' and the like (although you can get the SizeOf() the variables themselves if the base type is not included, i.e. 'Debug SizeOf(myVariable)' ).
...snip...
Wow, I didn't know that! Long and Quad structures!
Very useful to be able to find the size of a variable too...nice.