Hi Lee
I'm not sure why, but when you turn your camera using the Turn Camera commands, the Y angles do not span from 0-360. The following code demonstrates this.
The second camera on the right returns an angle in degrees, the one on the left does not. I did not use wrapvalue on purpose to demonstrate what is being done.
Both cameras rotate fine, but this causes a problem if you want to use the returned angles.
`%Project Title%
`Camera Angle does not return angle in degrees after Turn Camera
`======================
Set Camera Range 0, 0.1, 1000
Set Camera View 0, 0, 0, Screen Width() * 0.5, Screen Height()
Make Camera 1
Set Camera Range 1, 0.1, 1000
Set Camera View 1, Screen Width() * 0.5, 0, Screen Width(), Screen Height()
Make Matrix 1, 100, 100, 10, 10
Make Object Cube 1, 5 : Position Object 1, 50, 2.5, 50
Position Camera 0, 0, 1, -50
Rotate Camera 0, 0, 0, 0
Position Camera 1, 0, 1, -50
Rotate Camera 1, 0, 0, 0
Do
` Get mouse rotate setup
mx = MouseMoveX()
` Turn camera zero
Text 0, 0, "Turned Camera 0 Y Angle: " + Str$( Camera Angle Y(0), 4 )
Turn Camera Right 0, mx
` Y rotate camera one (No wrapvalue used on purpose)
Text Screen Width() * 0.5, 0, "Rotated Camera 1 Y Angle: " + Str$( Camera Angle Y(1), 4 )
YRotate Camera 1, Camera Angle Y(1) + mx
` Move cameras
Move Camera 0, Upkey()-DownKey()
Move Camera 1, Upkey()-DownKey()
Loop