Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Newcomers DBPro Corner / Camera Help please

Author
Message
Levanthus
21
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 19th May 2009 23:58
Right, this seems straight forward but i just can't seem to get it right. I'm currently working on a 3rd person style game and i want to move the character with W A S D keys, fair enough, but i'd like to be able to control the camera with the arrow keys.
I can get the up and down fine, but i can't get the camera to rotate around the character object and then restet and follow the player once they move. Does that make sense? I'd like to get the camera to rotate eg: to the left side of the charcter and then snap back behind and follow the character once they start moving again.

I can see from your smile, you're not here for the sunset.
BMacZero
18
Years of Service
User Offline
Joined: 30th Dec 2005
Location: E:/ NA / USA
Posted: 20th May 2009 02:32
I like to use a little trick like this when I need the camera to "orbit" something:





Vathelokai
15
Years of Service
User Offline
Joined: 3rd May 2009
Location:
Posted: 22nd May 2009 07:37 Edited at: 22nd May 2009 08:13
Have you tried the "Set camera to follow" command? The syntax...

SET CAMERA TO FOLLOW X, Y, Z, Angle, Distance, Height, Smooth, Collision

... should end up looking like...

Levanthus
21
Years of Service
User Offline
Joined: 17th Apr 2003
Location: Cumbria, UK
Posted: 22nd May 2009 11:49 Edited at: 22nd May 2009 11:53
I was already using the SET CAMERA TO FOLLOW command and i think that was where my problem was, but having looked at both suggestions i actually managed to combine the two and get the exact result i needed, with BMacZero, the camera didn;t restet behind the player object and the camera would resume rotation from it previsous state around the object, but after combinging it with the SET CAMERA TO FOLLOW command i managed something like this:-


thank you both very much for your help much appreciated

I can see from your smile, you're not here for the sunset.

Login to post a reply

Server time is: 2024-11-24 06:21:40
Your offset time is: 2024-11-24 06:21:40