Help me understand base.camera

Do all base.camera commands need to be inside a task?

In the tutorials I attempted to replace

#Task to move the camera
def SpinCameraTask(task):
  angledegrees = task.time * 6.0
  angleradians = angledegrees * (math.pi / 180.0)
  base.camera.setPos(20*math.sin(angleradians),-20.0*math.cos(angleradians),3)
  base.camera.setHpr(angledegrees, 0, 0)
  return Task.cont

taskMgr.add(SpinCameraTask, "SpinCameraTask")

With

base.camera.setPos(0,0,3)
base.camera.setHpr(0, 0, 0)

and it was no different then

base.camera.setPos(1000,1000,1000)
base.camera.setHpr(0, 0, 0)

They were both the default camera position in the ground.

I have tried a few different code snippits I found on the web with

base.camera.setPos(10,-50,10)

and tried changing the numbers and it never changes the camera position.

Please help me understand this.
Sammual

There is already a task that automatically resets the camera position every frame according to the mouse controls. While it is running, you can’t change the camera position yourself and expect it to stick.

Just call:

base.disableMouse()

David

OK, if I have this right;

base.camera.setPos(0,0,0)

Sets the camera’s position to (X,Y,Z) to (0,0,0) where the X Axis is the bottom of the monitor, the Z Axis is the vertical side of the monitor and the Y Axis is going straight into the monitor?

base.camera.setHpr(0, -45, 0)

Angles the camera down (Along the Y Axis) by 45 degrees?

Sammual

Roughly, yes. I assume that’s what you’re seeing.

David