Camera Zoom in Turret View
-
Here is a fresh video.
Near the end I zoom in on some npcs. Notice that they reach the extent of their life at 2.5k from me and disappear, heh. But also notice the cool effects of being able to clearly hear their speech and even engine sounds.
The only ‘bug’ I can report is that the program ‘remembers’ the zoom factor. If you have zoomed to 20k and then leave zoom and fly around a bit, when you go back to turret view you are still zoomed at 20k and disoriented until you unzoom back to your ship to catch your bearings.
Is there any way to have it reset to the ship when you leave turret view? Maybe not possible, but still an excellent addition adoxa! -
Here’s another update. When you enter Turret View, it will remember the current values; on exit, they are restored. The speed is halved every -10k, which helps a little.
002028, 200000f = max zoom distance
00202C, 10000f = zoom movement holding Shift
002030, 1000f = zoom movement holding Ctrl
002034, 100f = zoom movement holding Alt
002038, 10f = zoom movement holding Shift+Ctrl
00203C, 1.1f = zoom factor
002040, 0.5d = negative distance speed adjustment PART 1
002050, 0.5f = negative distance speed adjustment PART 2 -
Well, here is the turret zoom code of Freeworlds if you’d like to integrate it (this is called on rendering any frame):
bool bReloadTurretView; float fTurretViewMulti = 1.0; float fTurretViewTargetMulti = 1.0; float fTurretCameraOffset[3] = {0, 0, 0}; void TurretZoom(CAM_DATA* camera_setup, float fInterval) { // special turret cam zoom if(bReloadTurretView) { // load turret offset data fTurretCameraOffset[0] = camera_setup->fCameraOffset[0]; fTurretCameraOffset[1] = camera_setup->fCameraOffset[1]; fTurretCameraOffset[2] = camera_setup->fCameraOffset[2]; // reset multiplier fTurretViewMulti = 1.0; fTurretViewTargetMulti = 1.0; bReloadTurretView = false; } float fMultiDiff = fTurretViewTargetMulti - fTurretViewMulti; fTurretViewMulti += fMultiDiff * fInterval* (float)2.5; camera_setup->fCameraOffset[0] = fTurretCameraOffset[0]*fTurretViewMulti; camera_setup->fCameraOffset[1] = fTurretCameraOffset[1]*fTurretViewMulti; camera_setup->fCameraOffset[2] = fTurretCameraOffset[2]*fTurretViewMulti; }
And in the input hook:
case USER_WHEEL: { // up or down? int* iMWheelFlag; iMWheelFlag = (int*)0x061684C; if(*iMWheelFlag < 0) // up { fTurretViewTargetMulti *= (float)1.1;
and so on
-
The server hosting my site finally got some free space, so here’s the latest version, incorporating the render update (where I use the camera’s accel_speed, rather than 2.5) and processing options (at least, it processes options for me, there’s a chance it might not work for anyone else).
-
Adoxa , the options from arguments do not work on windows 7 64 bit.
On windows xp works normal .
I have```
TurretZoom.dll max=6500000 large=1.2All other features like zooming in and out works nomal . Edit : my mistake , i didn`t had latest version.
-
Good work adoxa for this one
It will be in the next UnderVerse release. I limited the range to 20 k so it couldn’t be used as an exploit at our ‘Beat the Bomb’ event. What it will be used for is all of our fighter events so people on the sidelines can see more of the fighters than just specs moving around.
-
Good deal there, Dwn, as always. Will it work while taking a video then?