BlueFlight 0 Posted June 20, 2004 I would like to create a camera that follows a plane or a tank and would like to change view directions and zoom. Could this be made with the camera.sqs script? Unfortunately i´m a newb in cam scripting so perhaps someone who could help me out? Share this post Link to post Share on other sites
Junker 0 Posted June 21, 2004 try looking for a vehiclecam script, there are loads out there to choose from ;) Share this post Link to post Share on other sites
BlueFlight 0 Posted June 22, 2004 well i searched on ofpec but without success. do you have any links? Share this post Link to post Share on other sites
Blanco 0 Posted June 22, 2004 Quote[/b] ]I would like to create a camera that follows a plane or a tank and would like to change view directions and zoom If it's a static camera it's easy. Learn about the camsettarget command and camera scripting in general. If it's not static i think it's the hardest thing you can do with camera's. Some time ago i wrote Logiccam which is a vehiclecam too With vehiclecam (Snypir's?) you can take camerascenes of a moving vehicle, the camera stays always in the same relative position. The object is always focusted. Logiccam is based on same principle, But Logiccam allows you to hold the camera on a roof of a moving truck , following a plane in the air But you can't zoom or move to another vehicle or unit while logiccam or vehiclecam's running Share this post Link to post Share on other sites
BlueFlight 0 Posted June 22, 2004 yes the point is that the vehicle is moving - so that´s not easy to create It´s a pity that we don´t have such cameras like in other simulation games in ofp Share this post Link to post Share on other sites
theavonlady 2 Posted December 9, 2004 I'm using snyPir's vehiclecam script for a cutscene and someone with a fast PC and high frame rate reports that the outcome is very choppy due to the script's fast looping. When I run the same cutscene on my PC (2ghz, 1GB RAM, 64MB GF 4 Go 64MB video chipset), I see no choppiness. Any suggestions for a better performance method to attach a camera to a vehicle and still have minimal control over the camera's position from vehicle and direction of filiming? Share this post Link to post Share on other sites
void_false 1 Posted December 9, 2004 I'm using Logiccam almost in every cutscene and it works OK for me. And my PC is pretty slow: P3 1000, GeForce4mx and 192 RAM. I must say that Logiccam is the best camera script out there. Big thank you Blanco! Share this post Link to post Share on other sites
theavonlady 2 Posted December 9, 2004 I'm using  Logiccam almost in every cutscene and it works OK for me. And my PC is pretty slow: P3 1000, GeForce4mx and 192 RAM.  On the contrary! The gripes I got was from someone with a fast PC. With our system's slower FPS, the problem is unapparent. Share this post Link to post Share on other sites
theavonlady 2 Posted December 9, 2004 Hah hah! Everything's topsy-turvy! I downloaded the LogicCam script and demo. I took out of the demo's camscript file the lines related to "plane1" and ran them as is in my cutscene mission in place of snYpir's vehiclecam script. Now I was shaking and stuttering all over the place! Go figure! Share this post Link to post Share on other sites
void_false 1 Posted December 9, 2004 Avon you're weird. Share this post Link to post Share on other sites
Blanco 0 Posted December 10, 2004 Quote[/b] ]Now I was shaking and stuttering all over the place! That's weird because the loop in logiccam is as fast as the one in Snypir's vehiclecam. Niks, rien, nichts,nada, zero seconds , it's a constant loop. Indeed, it can create lag when your camscript is running together with other intensive scripts. Also dxdll, ECP or other enhancements can cause the stuttering. I recommend to use in the intro section, not during the mission, only if your PC can't handle it. Also make sure there aren't two camera's running at the same time. The logiccam script needs to be stopped via a bolean, it's in the readme. Quote[/b] ]Any suggestions for a better performance method to attach a camera to a vehicle and still have minimal control over the camera's position from vehicle and direction of filiming No, a vehiclecam requires a fast loop, because you have to update the cameraposition as fast as possible. A slower loop ( ~0.000000000000000001 ) cause even more shaking and stuttering. (I tried it) Maybe the only thing you can do is hold the loop when the vehicle's speed is 0. Removing (or maybe setpossing somewhere far away, dunno it reduces lag) all the stuff thats not visible in the cutscene could help aswell. Share this post Link to post Share on other sites
theavonlady 2 Posted December 10, 2004 CAM test mission. No addons required. Runs as intro. No other cameras running. Camera stopped each time. There's a whole lotta shakin' goin' on! Share this post Link to post Share on other sites
Blanco 0 Posted December 10, 2004 Ok, you are right, the camera shakes but there's nothing I can do about it. You are using the logiccam on a flying plane. As long as the plane flies level there is no shaking. AFAIK long range shots work better, check the top viewcam  at the end, the plane is turning but there's no shaking.  The camera cant follow the artificial horison, that's a common problem with the OFP engine, I guess the same thing will happen with snypir's vehiclecam...  Share this post Link to post Share on other sites
uiox 0 Posted December 14, 2004 Try again your mission: Camtest You need the addon: OFrP_Objets (the addon is for showing the test dialog I have done for create easily cutscenes) Share this post Link to post Share on other sites
theavonlady 2 Posted December 16, 2004 Try again your mission:Camtest You need the addon: OFrP_Objets (the addon is for showing the test dialog I have done for create easily cutscenes) Thank you. Most impressive. Unfortunately, I don't want to make my cutscene dependent on OFRP. But the technical question remains: why is your cutscene so stable and the LogicCam script's so shaky? Is there something in the LogicCam script that can be changed to eliminate camera shaking? Share this post Link to post Share on other sites
uiox 0 Posted December 16, 2004 But the technical question remains: why is your cutscene so stable and the LogicCam script's so shaky? Is there something in the LogicCam script that can be changed to eliminate camera shaking? You can use a dummy target like this, it's the sqf of my move cam, you can adjust your points of view with the addon (or not) for use it call it in a loop with params. <table border="0" align="center" width="95%" cellpadding="0" cellspacing="0"><tr><td>Code Sample </td></tr><tr><td id="CODE">private["_v","_x","_y","_z","_d","_p","_Cam2","_Rot","_HB" ,"_DistTg"]; _Cam2 = _this select 0; _v =_this select 1; _HB = _this select 2; _Rot = _this select 3; _x =_this select 4; _y =_this select 5; _z =_this select 6; _d = getdir _v; _p = getpos _v; _DistTg = 15000; _Cam2 camsettarget _v; _Cam2 camsetrelpos [_x,_y,_z]; _Cam2 camsettarget [(((getpos _v) select 0) + ((sin ((getdir _v) + (_Rot) Â ))* (_DistTg * cos _HB) )), ((getpos _v) select 1)+ (((cos ((getdir _v) + (_Rot) Â ))* (_DistTg * cos _HB) )) , ( ( (getPos _v) Â select 2) + _z)+ Â ( Â (sin _HB) * _DistTg) ]; _Cam2 camCommit 0; All of my code is free without credit, cause I don't want give credit to Pythagore, Thales, Marek, Snypir, (3 pages after), Euler, Bn880, and all forgotten. Share this post Link to post Share on other sites