KX_ObjectActuator Has no attribute "xxx"

Hello everyone,
I’m on blender 2.61 and have installed python 3.2 . I am trying to make a camera move script to work, but I am failing miserably.
I copied the script example from the python API and I had to modify it a bit to make it work in the current version (that database is a bit outdated isn’t it?). this is my script


import bge

import Rasterizer

# Example Uses an L{SCA_MouseSensor}, and two L{KX_ObjectActuator}s to implement MouseLook::
# To use a mouse movement sensor "Mouse" and a
# motion actuator to mouse look:

# scale sets the speed of motion
scale = 1.0, 0.5

co = bge.logic.getCurrentController()
obj = co.owner
mouse = co.sensors["Mouse"]
lmotion = co.actuators["LMove"]
wmotion = co.actuators["WMove"]

# Transform the mouse coordinates to see how far the mouse has moved.
def mousePos():
   x = (bge.render.getWindowWidth() / 2 - mouse.position[0]) * scale[0]
   y = (bge.render.getWindowHeight() / 2 - mouse.position[1]) * scale[1]
   return (x, y)

pos = mousePos()
print(pos)

lmotion.offset_location =[pos[0], 0.0, 0.0]
wmotion.offset_location=[0.0, -pos[1], 0.0]

# Activate both actuators
co.activate(lmotion)
co.activate(wmotion)

# Centre the mouse
bge.render.setMousePosition(int(bge.render.getWindowWidth() / 2), int(bge.render.getWindowHeight() / 2))

everything works exept for

lmotion.offset_location =[pos[0], 0.0, 0.0]
wmotion.offset_location=[0.0, -pos[1], 0.0]

I get the error “KX_ObjectActuator has no attribute offset_location”. But KX_ObjectActuator has an offset_location attribute acording to the api help and the blender tooltips.
Same thing happens with the linear_velocity attribute as well, and I’m guessing the rest of the attributes will not work either.
Any workarounds?

First check if lmotion is a KX_ObjectActuator.

Then check the API of the KX_ObjectActuator.

Do not confuse it with the ObjectActuator which belongs to package bpy.

I have a mouse (movement) sensor going into the python script controller which goes to two Motion Actuators. A “motion actuator” search in the api reference does not return anything.

wrong msg.
ok I think you were right. now it gets all the values.
I’d like to adjust the torque of the camera, instead of give absolute rotation or displacement values. However my camera wont rotate when I just use the torque values. When in the physics tab I put the camera as a dynamic object then it does turn, but falls down due to gravity.
How can I give mass to the camera and exclude it from gravity?