When I call the Get Matrix Height, the height jumps around from normally around -1000 to 1000. After your camera is no longer on the matrix and is going backwards, it can get up to about 30000. Some of my code is as follows and I was wondering if anyone could help solve my problem of making it so that the height can make the camera or object a bit above or on the matrix.
make matrix 1, 1000, 1000, 10, 10
randomize matrix 1, 100
set matrix wireframe on 1
update matrix 1
do
yis=get ground height (1, camera position x(), camera position z())
if upkey()=1 then move camera 10 : position camera camera position x(), yis, camera position z()
if downkey()=1 then move camera -10 : position camera camera position x(), yis, camera position z()
if leftkey()=1 then yrotate camera camera angle y()-1
if rightkey()=1 then yrotate camera camera angle y()+1
print yis
print camera position x()
print camera position y()
print camera position z()
loop
sometimes, if I divide the result by 100, the camera shakes as the numbers appear to be randomly moving as opposed to about 3 days ago when the numbers would increment smoothly and slowly. The matrix I am using is randomized.