Hm ... constant velocity could maybe be achieved like
Fetch Some StringID ...
id_paramvalue = pl->FetchStringID ("cel.parameter.value");
"camera_rotate" is bound to "mousex_centered"
pcinput->Bind ("mousex_centered", "camera_rotate");
If the mouse moves away from the center the offset is a float you can get as shown below
(The code comes into the SendMessage Function of your Behaviour Type of course)
else if (msg_id == id_pccommandinput_camera_rotate)
if(params->GetParameter(id_paramvalue)->value.f > 0)
else if(params->GetParameter(id_paramvalue)->value.f < 0)
So the idea is that if the offset of the mouse to the center is positive we rotate into one direction with constant velocity and the other way round.
Hope this helps somehow ... or is at least understandable
to see the code in action you can get the oOC code
cvs -d:pserver:email@example.com:/cvsroot/ocmod checkout ooc
our solution to this problem can be found in src/ooc.cpp and src/behaviour/be_player.cpp