Jump to content

Quetion about views definitions in server.lua vs aircraft specific views file


Recommended Posts

Hi all, (first of all, Question*)

 

As some of you may know, the server.lua file can be placed in Saved Games\DCS\Config\View\

to be able to preserve settings when DCS updates.

 

However, not all aircraft use it, but instead use their own variant of views.lua in DCS World\Mods\aircraft\module

 

One example of this is the M-2000.

 

Now, I use the somewhat unorthodox method of zoom view in the game, by mapping it to my left toebrake. This enables a relaxed way of zooming without me having to let go of the throttle to adjust the slider on the throttle that many use.

 

For this to work, I have to configure the toebrake axis as a slider.

Now, in server.lua I've set the CameraViewAngleLimits = {20.0000,90.0000} which results in "not pressed toebrake" = fully zoomed out, which means fov 90.

 

But as the M-2000 and others uses their own views file it won't work for them.

 

Editing the specific views file in the install dir for those aircraft works, but will not work in MP as it won't pass integrity check.

 

How do I get around this? Suggestions?


Edited by chrisofsweden

GPU: PALIT NVIDIA RTX 3080 10GB | CPU: Intel Core i7-9700K 4,9GHz | RAM: 64GB DDR4 3000MHz
VR: HP Reverb G2 | HOTAS: TM Warthog Throttle and Stick
OS: Windows 10 22H2

Link to comment
Share on other sites

Basically the server.lua is a user customization which as far as I can tell by default is not created with clean installation. All planes start with view settings as done in the internal, DCS files, most in "DCS World\Mods\aircraft\module".

If you place the server.lua in the user folder the game, provided that it contains a valid configuration for the aircraft the game will read it from there, overriding setup from the DCS folders. In other words, unless you've done something wrong it should work. Usually if it doesn't, especially for multiple aircrafts it can be a syntax error.

The advantage of server.lua is:

+ green for IC, you're not modifying original, in-game files

+ it's gives an easy way to apply the same config values for all planes (personally I hate to have a different min/max zoom or head movement between planes)

+ doesn't get overwritten by updates

Negatives

- doesn't get overwritten by updates :). That was an possitive but the downside is that if there is an update/fix for an module it'll not work. You have to check manually from time to time. On the other hand the view configurations are mostly not changed from the release date.

F/A-18, F-16, F-14, M-2000C, A-10C, AV-8B, AJS-37 Viggen, F-5E-3, F-86F, MiG-21bis, MiG-15bis, L-39 Albatros, C-101 Aviojet, P-51D, Spitfire LF Mk. IX, Bf 109 4-K, UH-1H, Mi-8, Ka-50, NTTR, Normandy, Persian Gulf... and not enough time to fully enjoy it all

Link to comment
Share on other sites

Thanks for your reply!

 

You are right, it's not created in DCS user files directory by default.

The server.lua file resides in "C:\Program Files\Eagle Dynamics\DCS World\Config\View" by default.

You have to manually copy it to "..Saved Games\DCS\Config\View"

 

However, basically only FC3 planes are defined in it.

 

Actually, I now tried adding the M-2000C definitions from the modules install directory into the user side server.lua and it appears it worked. Max zoom out is now locked to 90 deg.

 

Something is not right with the default snap view though. Pressing enter renders a view with 60 deg... I guess I'll have to look around where the default snap view for the M-2000C is fetched from...

 

 

EDIT: Worked it out. SnapView settings were specified in the M-2000C "Views.lua".

Copied "C:\Program Files\Eagle Dynamics\DCS World\Config\View\SnapViewsDefault.lua" to DCS user dir and there renamed it to"SnapViews.lua"

Copied the SnapView settings from M-2000C "Views.lua" and made another section in SnapViews.lua for "M-2000C" where I pasted the settings.

It now works! Yay :)


Edited by chrisofsweden

GPU: PALIT NVIDIA RTX 3080 10GB | CPU: Intel Core i7-9700K 4,9GHz | RAM: 64GB DDR4 3000MHz
VR: HP Reverb G2 | HOTAS: TM Warthog Throttle and Stick
OS: Windows 10 22H2

Link to comment
Share on other sites

You can take an user made version of server.lua with more modules added by copying their settings from respective views.lua from here.

The default FOV is stored in the snap views file.

F/A-18, F-16, F-14, M-2000C, A-10C, AV-8B, AJS-37 Viggen, F-5E-3, F-86F, MiG-21bis, MiG-15bis, L-39 Albatros, C-101 Aviojet, P-51D, Spitfire LF Mk. IX, Bf 109 4-K, UH-1H, Mi-8, Ka-50, NTTR, Normandy, Persian Gulf... and not enough time to fully enjoy it all

Link to comment
Share on other sites

Since you seem to know so much about this topic, do you know if it's possible to have a user "snapviews.lua" containing only the default snapview [13] for all aircraft, omitting 1-12?

 

Would it then read snapviewsdefault.lua values first and then just replace snapview[13] values with values from the user snapviews.lua?

 

The reason would be to have a more "manageable" snapviews.lua

 

 

Same thing with Server.lua really. Suppose I'd like to change only CameraViewAngleLimits, could I detail only that part for every aircraft and omit the rest?


Edited by chrisofsweden

GPU: PALIT NVIDIA RTX 3080 10GB | CPU: Intel Core i7-9700K 4,9GHz | RAM: 64GB DDR4 3000MHz
VR: HP Reverb G2 | HOTAS: TM Warthog Throttle and Stick
OS: Windows 10 22H2

Link to comment
Share on other sites

I don't think it's possible to do it this way, most probably it'll crash. I can check it later if I get some free time but I wouldn't hope for it.

On the other hand, assuming that there is no snapviews.lua file in user folder, every time you generate a snapviews the process actually takes the most up to date values from the respective DCS folders. Afterwards you can go through it just change the values at index 13. Takes a moment but it's not a total disaster.

 

The values stored in snapviews and view/server.lua should be controlled by in-game options. Unfortunatelly such functionality doesn't exist jet but working with snapviews.lua and server.lua stored in user folder is usually a single time effort. Afterwards it's just a short updates from time to time.

F/A-18, F-16, F-14, M-2000C, A-10C, AV-8B, AJS-37 Viggen, F-5E-3, F-86F, MiG-21bis, MiG-15bis, L-39 Albatros, C-101 Aviojet, P-51D, Spitfire LF Mk. IX, Bf 109 4-K, UH-1H, Mi-8, Ka-50, NTTR, Normandy, Persian Gulf... and not enough time to fully enjoy it all

Link to comment
Share on other sites

  • 10 months later...

Gotta bump this.

 

Today, update 2.5.0.15184.338 (update 4 SF hotfix) made the old way of modifying the plane specific views.lua files impossible due to the IC which now triggers right at the start of DCS and not just when joining MP. Well, I thought I'd dig this thread out and move the settings I prefer (zoom levels 30, 60, 90) for all planes from the specific views.lua files to the server.cfg in the user folder. This fixed my IC / CP problem (https://forums.eagle.ru/showpost.php?p=3426723&postcount=3) and makes it possible for me to join IC enabled servers again.

To make it easy, I took your files from...

 

https://forums.eagle.ru/showpost.php?p=3305863&postcount=687

 

... and dropped them to "C:\Users\Eldur\Saved Games\DCS.openbeta\Config\View", saving my old ones beforehoof.

 

I just changed one line in Server.cfg...

 

local gCameraViewAngleLimits = {30.000000, 90.000000} -- Field of view,

 

... and did the search and replace in the SnapViews.lua, replacing all instances of "viewAngle = 107.000000,--FOV" by "viewAngle = 60.000000,--FOV chg".

 

But now comes my problem. This works well for all planes that don't have either a Views.lua or Entry\Views.lua file. For them, the changes don't apply at all, seems like they override the Server.cfg in my user folder and I don't know if this is a new behaviour now. This also affects the M-2000C mentioned in this thread already as well as the most recent addition of the AV-8B and many others.

 

Is there a definite way that works or did I just miss something? I don't need that 140° fish eye view. I've got "zoom in fast" for 30°, "zoom normal" for 60° and "zoom out fast" for 90°, just in the good old Il-2 style, mapped to Del, End and PgDn. I'm using this for almost two decades now, almost every day in all sims I fly. It's impossible to give this up now rdlaugh.png

dcsdashie-hb-ed.jpg

 

Link to comment
Share on other sites

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...