Special Aircraft Service

Please login or register.

Login with username, password and session length
Advanced search  
Pages: [1] 2 3   Go Down

Author Topic: WxTech's P-38 cockpit improvements  (Read 4276 times)

0 Members and 1 Guest are viewing this topic.


  • Modder
  • member
  • Offline Offline
  • Posts: 3781
WxTech's P-38 cockpit improvements
« on: December 31, 2020, 07:01:41 PM »

A number of small fixes to the P-38 cockpit. And for head tracker users, expanded range of virtual head movement.

A few screen grabs to illustrate the more apparent graphical changes:

The side 'X' frame attachment points at upper left and right no longer PASS THROUGH the frame arches.

The upper canopy frame arch now has the disc shadows in better alignment.

Now has my new Lynn-3 gun sight and support arm, and tinted armored glass.

A properly sized, circular reticle mask is present, as well as a dynamically lit collimator lens reflection.

A number of panel gauges have been improved. The most notable are the artificial horizon, gyro compass and the radio compass repeater. Note the addition of various knobs.

The gauge night textures are now properly uniform in intensity (no silly shadow darkening simply copied over from the day textures.)

Get it here:


From the included readme file:

Based on 4.12, with PA_Jeronimo's canopy frame and instrument panel smoothing incorporated. I think this is also the BAT version...

Not as thorough a job as done for my Wildcat and P-39 mods, but then the '38 is in a better state to start with. I haven't done much work on updating instruments, and have not touched the damaged textures at all. This is a quicker, less thorough treatment that falls well short of a *real* overhaul.

I include EVERY file in the cockpit folder, so that it's ready to tackle by any other modder who might want to dive in. Not all meshes have been converted to plain ASCII txt; only those I had to alter or just wanted to peek into.


Here is a summary of the changes made to the P-38 cockpit:

1 - Replaced the stock gun sight and its mounting arm with my own Lynn-3 creation. Supplied with a 70 mil ring-and-dot reticle, the ring having gaps where the supports for the central occluding disk block the light.

2 - Instituted a proper-sized, circular reticle mask, and collimating lens reflection.

3 - Tinted the armored glass a greenish hue.

4 - Added a new gyro compass texture, with more rounded compass tape drum. And replaced the too-light 'box' for it on the back side of the panel with a totally black backing surface. No more strange lighting up of the interior of the housing! (A bad problem for a fair number of other compasses.)

5 - Added the adjustment knob texture to the altimeter.

6 - Fixed up all the instrument night mats, to fill in the invisible parts due to the originals not ignoring the daytime shadow darkening of the upper dial faces. And made them brighter.

7 - Fixed the slight gaps Jeronimo introduced when rounding the instrument panel 'corners.'

8 - For the canopy side 'X' frame bar upper attachment points, adjusted so that the ends don't pass THROUGH the surface of the frame arches.

9 - For the texture of the upper frame arch at mid canopy, adjusted so that the shadows align with the attached discs.

10 - Closed a minor gap in the perspex at the right side middle.

11 - For the canopy perspex, reversed the surface normals so that 'shmutz' shows more strongly in the up-Sun direction due to the greater efficiency of forward scattering.

12 - Made a better radio compass face, with higher resolution so that the individual degree marks stand apart clearly. Also added the adjustment knob.

13 - Created a dedicated graphic for the artificial horizon face, in order to fit the extension for the caging knob. And added a knob texture floating above.

14 - For the artificial horizon's pitch/bank bar, I moved the texture from the artificial horizon face graphic to a dedicated place on another texture having room to incorporate it. The former scheme used the small hash mark on the left side of the dial face. This is dangerous because of the tight constraints! The slightest position change anyone might make for a new dial face graphic could bugger up the mapping. Hence my solution to avoid this nasty potentiality.

15 - For the artificial horizon, altered the graphics and the positioning of the three elements so as to achieve a correct level condition, and with reduced parallax error.

16 - For the instrument panel texture, Jeronimo's corner rounding resulted in the remapping failing to extend as high up near the top of the texture as it should. This caused a stretching in the uppermost part that made for an obvious mismatch with the clock. That's been fixed.

17 - In the cockpit class, replaced a night mat entry due to dedicating a new texture to the gyro compass tape, and added a new night mat entry for the dedicated artificial horizon face.

18 - In the cockpit class, added 6DoF code (to override the defaults as set elsewhere) in order to expanded the range of head movement in all directions.


I've positioned the PoV hooks to my preference as a TrackIR user. For those not having the benefit of this kit, you can easily tweak the two view hooks to your liking. In Body.msh, at the top, you'll find this:


0 0 -1 -1 0 0 0 1 0 0 0.173 0.35
0 0 -1 -1 0 0 0 1 0 0 0.168 0.12

The top line of numbers is the basic view hook (CAMERA), and the lower one is for the 'gun sight' view (CAMERAAIM), when pressing SHF-F1. The crucial values are the last 3. They move the PoV LEFT, UP and REARWARD, respectively, when increasing in value, and are in meters. For example, note the CAMERAAIM vertical value of 0.168. You could set its equivalent CAMERA value the same, from the current 0.173, which is a bit higher, thus making the sight line through the sight both of the same height, the only difference now being in the fore-aft distance.


If you find the intensity of the armored glass green tint to be too strong for your liking (or not strong enough  ;)  ), you can easily tweak to your liking. In ArmoredGlass.mat, look for this line:

  ColorScale 1.0 1.0 1.0 0.3  //0.2

The last number of the four is the opacity. You'll see I once had it set to 0.2 (20%), but then boosted it to the current value of 0.3 for a stronger tint. You can put in any number from 0.0 to 1.0.


The CockpitP_38J.class comprises these 4 files:

The CockpitP_38J.java is included. Readable with any text editor; Notepad++ is excellent due to supported formatting!

The new 6DoF code (the first two lines here are the defaults set in another class, with a decode guide):

// limits6DoF = (new float[] {0.5F, 0.08F, -0.05F, 0.15F, 0.2F, -0.2F, 0.05F, -0.05F});   //DEFAULTS GUIDE
// (0)spineL, (1)faceL, (2)spineOffsetX, (3)leanSideMax, (4)leanForwardMax, (5)leanForwardMin, (6)raiseMax, (7)raiseMin
limits6DoF = new float[] { 0.6F, 0.07F, -0.07F, 0.18F, 0.3F, -0.2F, 0.08F, -0.15F };

The stock night mats, and the two changes made (one replacement and one new):

stock = "gauges1"
stock = "gauges1_dam"
stock = "gauges2"
stock = "gauges2_dam"
stock = "gauges3"
stock = "gauges3_dam"
stock = "gauges4"
stock = "gauges4_dam"
stock = "gauges5"
stock = "leftcontroles"
stock = "misc2"
stock = "swbox"   REMOVED and REPLACED with "compasstape" (gyro compass tape)
stock = "swbox2"
NEW = "gauges6" (new dedicated texture for the artificial horizon face)

Needless to say, it's a good idea to be sure that the cockpit class always reflect these changes if these new textures are to be utilized. Meaning: Keep these classfiles together with this mod unless another modded class also reflects these changes. Modders take note!


This work is offered for use by any and all, for any purpose, without restriction or hindrance.

New Years's Eve 2020
Great minds discuss ideas. Average minds discuss events. Small minds discuss people. - Hyman Rickover (but probably predating his use.)


  • member
  • Offline Offline
  • Posts: 648
Re: WxTech's P-38 cockpit improvements
« Reply #1 on: January 01, 2021, 02:11:05 AM »

A great job as always!!


  • member
  • Offline Offline
  • Posts: 958
  • BAT 4.2 Flashpoint & WAW
Re: WxTech's P-38 cockpit improvements
« Reply #2 on: January 01, 2021, 03:41:20 AM »

Looking great, thanks a lot


  • member
  • Online Online
  • Posts: 392
Re: WxTech's P-38 cockpit improvements
« Reply #3 on: January 01, 2021, 03:43:00 AM »

Thank you very much! As usual, TOP level of work.

Andy H

  • member
  • Offline Offline
  • Posts: 1218
Re: WxTech's P-38 cockpit improvements
« Reply #4 on: January 01, 2021, 05:06:22 AM »

Working fine in BAT. Great stuff! Thanks very much.  :)


  • member
  • Offline Offline
  • Posts: 564
Re: WxTech's P-38 cockpit improvements
« Reply #5 on: January 01, 2021, 05:30:03 AM »

Great work WxTech! The P-38 is amongst my favourites of all time and this addition is just the good news i needed today!  8)


  • Avid FMB user
  • SAS Honourable Member
  • member
  • Offline Offline
  • Posts: 3559
  • Help Ukraine fight
    • Check out my modded campaigns
Re: WxTech's P-38 cockpit improvements
« Reply #6 on: January 01, 2021, 06:08:04 AM »

Super job, really SUPER!!!  :P
You want to give financial support to a front line Ukraine unit fighting the Russian invaders? Paypal kyivragnarock@gmail.com


  • member
  • Offline Offline
  • Posts: 350
Re: WxTech's P-38 cockpit improvements
« Reply #7 on: January 01, 2021, 07:04:44 AM »

Happy New Year!

Thank you for this great work, WxTech.



  • SAS Team
  • member
  • Offline Offline
  • Posts: 5578
Re: WxTech's P-38 cockpit improvements
« Reply #8 on: January 02, 2021, 03:08:47 AM »

Great job! Many thanks for sharing and a Happy New Year,  8)

Peter Lynn

  • member
  • Offline Offline
  • Posts: 431
Re: WxTech's P-38 cockpit improvements
« Reply #9 on: January 02, 2021, 05:42:52 AM »

Thank you WxTech....really nice work, just like all your other creations....and a Happy New Year to you!


  • member
  • Offline Offline
  • Posts: 206
Re: WxTech's P-38 cockpit improvements
« Reply #10 on: January 02, 2021, 05:55:22 AM »

superb improvement, many many thanks,kev.


  • member
  • Offline Offline
  • Posts: 699
Re: WxTech's P-38 cockpit improvements
« Reply #11 on: January 02, 2021, 08:04:22 AM »

Nice gift to P-38 drivers. Thank you.
Pages: [1] 2 3   Go Up

Page created in 0.24 seconds with 26 queries.