Jump to content
Sign in to follow this  
Lean Bear

External Camera

Recommended Posts

This has been bugging me for ages.

I was wondering if anyone knew of a way to set an external camera (or any camera that stays in a fixed position) in a mission (ie. not an intro or outro) so you could still control the player' unit - but the camera wouldn't follow him around?

I've tried a number of things (mainly the really obvious ones such as testing out the different cameras and having a fiddle with specific models' external cameras (the 3rd person viewpoint etc.) but there's nothing that I can see that will keep them fixed or anything.

Any ideas?

edit

I've been told my q isn't exactly too clear, so, to sum it up:

When your character moves the camera is focused on the screen and not the player.

Share this post


Link to post
Share on other sites

I don't think there is any real good way to do this. Problem is, when you create a camera via scripting, the player loses control. The only thing I could think of would be to use Kegety's Fwatch to detect the player's keyboard/mouse input, and then move the player's soldier/vehicle/whatever accordingly.

Actually, if you play the Fwatch demo mission, that is exactly what Kegetys has done in his top-down view racing mission. So there you go smile_o.gif.

Share this post


Link to post
Share on other sites

Funnily enough, that's where I originally started before trying to use a config or scripting trick to get it to work.

Apart from the really basic stuff, I found it too complicated to understand, but by now my C knowledge must have improved, so I'll give it another crack, thanks wink_o.gif

Share this post


Link to post
Share on other sites
Apart from the really basic stuff, I found it too complicated to understand, but by now my C knowledge must have improved, so I'll give it another crack, thanks wink_o.gif

Are we talking about the same thing? You don't need any knowledge of C or anything other than OFP scripting to get Fwatch working. Basically all it does is add a bunch of new scripting commands to OFP. Download it here:

http://ofp.gamezone.cz/index.php?showthis=8361

Share this post


Link to post
Share on other sites

Yeah, we are talking about the same, thing - what I meant was: at the time when it came out, I was curious as to how it worked and looked at the source code, but I didn't get it.

The scripting thing I understood once you recommended using fwatch *slaps head (should have thought of it earlier)*. I'm just not familiar with the loadFile command :P But after looking through the scripts in the fwatch race mission (mainly rally.sqs) it seems easy enough to set the camera up - but then do I have to put in what all the key presses do?

Share this post


Link to post
Share on other sites
but then do I have to put in what all the key presses do?

Yes, and you can't detect if the user has changed his control settings from the default layout. So this isn't really practical if you want to let the player do everything he normally would be able to do (like controlling an infantry unit, for example). It only really works well enough for limited controls, like driving a car in the demo mission.

Share this post


Link to post
Share on other sites

OK, well - that's fair enough. I guess I could always include a warning to make sure that people use the default set-up.

I guess the next challenge I'd be facing is working out all the mathmatical calculations to determine what each key press would do...

Share this post


Link to post
Share on other sites

Please sign in to comment

You will be able to leave a comment after signing in



Sign In Now
Sign in to follow this  

×