Assuming this code works as described, all you need to do is assign the angle according to mouse_force (and a modifier). Pretty much ignore my previous post, I got confused and started babbling, that was my fault.

Your Code [editted]:
Code:
function Camera_Action()
{
	var mouseR_onhold = 0;  //Not needed
        var centerx = 0; // centre of circle (x)
        var centery = 0;  // centre of circle (y)
        var centerz = 0;  //Change these to point to your player
        var radius = 400; // radius of circle
        var thetaX = 0; // degrees done around the circle
        var thetaZ = 0;
	
        my = player = camera;        //Important, he is using a my pointer, since for 
                                     //whatever reason your not making the camera 
                                     //an action, you need to get the my pointer point to the camera somehow
        camera.genius = camera;      //This you could probably get rid of, depends on what you want
	while(1)
	{
		camera.pan = my.pan;
		camera.tilt = clamp(camera.tilt,-70,70); //Change tilt to what you want or get rid of this
		if(mouse_right) // right Mousebutton pressed?
		{
			mouseR_onhold = 1;  //Not needed
			mouse_map = NULL;   //It would be nice if you checked if mouse_map wasn't NULL before-hand
			
			thetaX+=mouse_force.x * 5;  //I'd make a variable for 5 and tweak it to what 
                                                    //you want the sensitivity to be, same with next one
			thetaZ+=mouse_force.y * 5;
			camera.x = centerx + (radius * sinv(thetaX));
			camera.y = centery + (radius * cosv(thetaX));
			camera.z = centerz + (radius * cosv(thetaZ)); //might be sinv() or tanv(), tweak till you like the result
		
			vec_set(temp,centrex); 
			vec_sub(temp,my.x);
			vec_to_angle(my.pan,temp); // now MY looks at YOU
			vec_set(camera.x,my.x);
		}

		//Your previous function was round-about, I'd do this
		if(mouse_map == NULL)
		{
			mouse_map = arrow;
		}

		wait(1);
	}
	
}


Last edited by Trooper119; 08/18/08 18:58.

A clever person solves a problem.
A wise person avoids it.
--Einstein

Currently Codeing: Free Lite-C