They work out a new x or z value for when you are walking round in 3D.
You give it the current x value, the angle and the distance to move and it gives back the new x value.
Like this:
(from above)
Give it the black stuff and it will give you the red stuff.
It means you can move object forward the direction they are facing.
Like this:
make object cube 1, 1
sync rate 60
sync on
do
if leftkey() = 1 then Angle# = Angle# - 5
if rightkey() = 1 then Angle# = Angle# + 5
if upkey() = 1
xPos# = newxvalue( xPos#, Angle#, 0.25 )
zPos# = newzvalue( zPos#, Angle#, 0.25 )
endif
position object 1, xPos#, 0, zPos#
yrotate object 1, Angle#
position camera 10, 10, -10
point camera 0, 0, 0
sync
loop