360 degree chase camera

Developer discussion of experimental fixes, changes, and improvements.

Moderators: Nexuiz Moderators, Moderators

Postby mand1nga » Fri Jan 23, 2009 7:36 am

Well .. sidewards movements weren't designed to rotate the camera, this is why when you are looking to a fixed point the camera tends to move "tangentially" instead of moving in circles. I've noticed that if you move the camera right/left and forward at the same time it actually rotates in the "look to player" mode, but not on any radius. Its like it gets closer to the player to a certain distance then it rotates around the player without any problem.
I'm sure that fixing this will be really entertaining :)

Thanks again for testing it!
Last edited by mand1nga on Tue Jan 27, 2009 12:49 am, edited 1 time in total.
mand1nga
Alien trapper
 
Posts: 321
Joined: Mon May 12, 2008 12:19 am

Postby Mr. Bougo » Mon Jan 26, 2009 11:32 am

About free camera control... I made this cfg to alias

Code: Select all
alias _calias "alias +c$1 set camera_direction_$2 ${3}1; alias -c$1 set camera_direction_$2 0"

_calias forward x ""
_calias back    x -
_calias left    y ""
_calias right   y -
_calias up      z ""
_calias down    z -


It feels quite wrong when you use key combinations: when I go forward and left, my actual camera speed is 1.414 times the speed when I go only forward (square root of 2)... It could be possible to tweak the cfg to get "normal" behaviour, but it will be a pain and look quite complicated :p

Can't you just use the user's movement input from +forward etc. ?
Meh.
Mr. Bougo
Keyboard killer
 
Posts: 760
Joined: Mon Sep 10, 2007 3:29 pm

Postby Alien » Mon Jan 26, 2009 12:18 pm

camera_max_speed 1 to disable camera strafe running? ;)
Alien
Forum addon
 
Posts: 1212
Joined: Tue Apr 22, 2008 7:12 am

Postby mand1nga » Tue Jan 27, 2009 12:48 am

Good points Bougus. I'll see what I can do with that strafe effect :P

Also re-using the +forward, +left, etc keys for controlling the camera position sounds to me like a good idea.
mand1nga
Alien trapper
 
Posts: 321
Joined: Mon May 12, 2008 12:19 am

Postby esteel » Wed Jan 28, 2009 10:05 am

IIRC you can (un)registerCommand in csqc to hijack those functions..
esteel
Site admin and forum addon
 
Posts: 3924
Joined: Wed Mar 01, 2006 8:27 am

Postby uluyol901 » Thu Jan 29, 2009 1:29 am

Could you make it zoom out more when the person has the flag in CTF?

This is awesome, thanks for working on this
uluyol901
Member
 
Posts: 16
Joined: Sun Jan 25, 2009 7:39 pm

Postby mand1nga » Sun Feb 01, 2009 5:07 pm

It feels quite wrong when you use key combinations: when I go forward and left, my actual camera speed is 1.414 times the speed when I go only forward (square root of 2)... It could be possible to tweak the cfg to get "normal" behaviour, but it will be a pain and look quite complicated :p

Fixed
3) when I press move left and move right very fast after another (again and again... like strafing left and right with the camera all the time) the movement of my move_left isn't recognized

Fixed
Also re-using the +forward, +left, etc keys for controlling the camera position sounds to me like a good idea.


Now the camera is controlled by the standard movement keys, plus the not very popular +moveup/down commands, and the camera-specific commands +roll_left/right. As probably no one have binds for the +moveup/down cmds, I've set camera_forward_follows 1 as default in order to provide an spectator-like camera. This enables all movements but rotating, without the need of adding extra binds.

The cvar set hasn't changed since last time. Now this is my config:

Code: Select all
bind MOUSE1 +roll_left
bind MOUSE2 +roll_right
bind MOUSE4 +moveup
bind MOUSE5 +movedown


Thanks again for the feedback :)
mand1nga
Alien trapper
 
Posts: 321
Joined: Mon May 12, 2008 12:19 am

Postby mand1nga » Sun Feb 01, 2009 5:08 pm

esteel wrote:IIRC you can (un)registerCommand in csqc to hijack those functions..


Epic timing, I owe you one :)
mand1nga
Alien trapper
 
Posts: 321
Joined: Mon May 12, 2008 12:19 am

Postby mand1nga » Sun Feb 01, 2009 7:03 pm

uluyol901 wrote:Could you make it zoom out more when the person has the flag in CTF?


You can do it just taking some distance from the player or playing with the fov cvar. As this camera is intended for generic purposes I don't think it would be wise to change its behavior according to the game type. Think about what "zoom out" means, you can end with the camera inside a wall in some maps.
mand1nga
Alien trapper
 
Posts: 321
Joined: Mon May 12, 2008 12:19 am

Postby terencehill » Mon Feb 09, 2009 4:47 am

How does it work? I'm using camera_enable 1 but it doesn't
Does it work with every demo?

Btw I was expecting that this stuff can be activated simply pressing a key (left click could be nice) while watching a demo.
terencehill
Alien
 
Posts: 176
Joined: Thu Jul 10, 2008 10:33 pm
Location: Italy

PreviousNext

Return to Nexuiz - Development

Who is online

Users browsing this forum: No registered users and 1 guest

cron