Addons & Mods Depot => ArmA - Configs & Scripting => Topic started by: fortran on 09 Jan 2009, 17:43:15

Title: A-10 HUD?
Post by: fortran on 09 Jan 2009, 17:43:15
Sorry if this is the wrong section but I wanted to try find a solution for this. I just noticed this when peering extremely hard at the screen during a simulated CAS run...I always thought the HUD for the A-10 looked a bit "empty"...took a screenie and changed the levels in PS and I see there is a fully functional HUD lost in the opacity



Is there any way to get those HUD elements to have less opacity so I can actually see them normally ? They are very useful to a pilot and although not essential to play ARMA they would be useful. The HUD for the harrier etc look fine, just seems to be the A-10

Not modded for ARMA before but have had quite a long history of modding in general. Found the actual HUD file in Addons/A10.pbo/Data/a10_hud1024_ca.paa opened it up and it is the correct file, however the opacity in the alpha channel is set to full (white) so it appears the opacity of this HUD element is being controlled by a? I think it is somewhere in the config.bin for the A-10 maybe. Have converted it to cpp and have found a couple of alpha entries, although changing them doesn't seem to effect the part of the HUD im attempting to change. Have managed to change the colour of the text on the HUD to white, but still can't see the additional elements.

Also I wanted to ask if I do manage to alter this, will I be able to play online without getting kicked ? I don't fully understand the whole precedure of getting your addon "signed". Or would this just be client-side and not require a signed file for it?
Title: Re: A-10 HUD?
Post by: Planck on 09 Jan 2009, 21:49:48
Firstly, welcome to OFPEC, I hope we are able to help you with this and any future editing questions.

To begin with the texture you identified seems to be the correct one, however, I looked at the alpha channel it is using and the lettering is white and the rest is pure black (picture attached).
It also uses an .rvmat (rvmat (http://community.bistudio.com/wiki/RVMAT))file as well as the texture itself.

The .rvmat:
Code: [Select]
//Class a10_hud.rvmat{
ambient[] = {0,0,0,5};
diffuse[] = {0,0,0,1};
forcedDiffuse[] = {0.005,0.005,0.005,0};
emmisive[] = {0,20,0,1};
specular[] = {0,0,0,0};
specularPower = 0;
renderFlags[] = {"NoZWrite","NoAlphaWrite","AddBlend"};
PixelShaderID = "Normal";
VertexShaderID = "Basic";

I doubt very much if you will find any relevant textures or texture paths for the hud in the config for the A10.

Presuming you managed to sort this out by editing the files for the A10, there is a high possibility that you would be shut out of many servers that are set to detect changed game files.
Only other hope I can see is if BI know about this and are planning to fix it in the next patch, but I wouldn't count on it.  :dry:

Any other info needed just ask, I will try to help.

Title: Re: A-10 HUD?
Post by: fortran on 09 Jan 2009, 22:53:30
Hi Planck,
Many thanks for responding mate. Im not quite sure where the problem lies with this. In my understanding "white" in an alpha map denotes 0% transparency, therefore that image file should be showing all the white areas in the mask with no transparency, the diffuse layer which is green is giving the HUD the green colour. The RVMAT for that texture ....could it be the render flag:

Code: [Select]
renderFlags[] = {"NoZWrite","NoAlphaWrite","AddBlend"};

If it were changed to the opposite of "NoAlphaWrite" which I am presuming would be just "AlphaWrite" or just remove it altogether. Would that force it to use the textures alpha channel to control the transparency ?

Thanks again for your assistance with this.

EDIT: Just tried it with the NoAlphaWrite flag removed from the RVMAT but it had no effect in-game. Shame as this seemed to be an "obvious" step.
Title: Re: A-10 HUD?
Post by: Planck on 10 Jan 2009, 00:17:05
Yes indeed the white areas of the above picture are non-transparent (the numbers and scales), the rest is transparent (black).

The Av8b on the other hand is more of a mystery to compare against, as I cannot find any hud textures for it.

As a comparison, here is the su34 hud texture and alpha, which also uses the same rvmat as the a10.

Title: Re: A-10 HUD?
Post by: Gnat on 10 Jan 2009, 02:39:06
Wow fortran, didn't even realise all that HUD detail was there.
Best of luck.
Title: Re: A-10 HUD?
Post by: fortran on 10 Jan 2009, 04:38:22
Yeah :) after looking around on youtube it appears that it was working at one point as this video shows:


You might need to hit "watch in high quality" to see it properly but its definitely there. I don't know which patch it has been broken with but hopefully they might fix it for the next one. Have tried to sign up for the bis community so I can report it as a bug. Its a real shame, as with it you have so many more visual cues on screen to aid flying, especially at lower levels.

To be honest I have no idea how to attempt to fix this. The config doesn't hold any answers, although it does list the entries for those transparent elements and the texture file seems fine, so does the rvmat as show by Panck comparing it to the su34's texture and rvmat. It must be a source code problem as far as I can see. Thanks for the help none the less, just hope it gets fixed.

Ok so as I own the European version of the game I didn't get the chance to play the added A-10 mission that comes with Combat Ops. So after some searching I found it over at armaholic: Mission 14 Devils Cross http://www.armaholic.com/page.php?id=1496. Loaded up that mission, powered up the A-10 ....and the Hud is working!!!!


So the question is, what is in that mission that enables that part of the HUD ? I tested the A-10 again in the editor to check I wasn't going crazy, and no it doesnt work there but it does in that one mission. Could it be some extra script executed on the vehicle in that mission? I don't really have enough knowledge of mission creating to be able to open it and take a look. But if anybody knows how, I think the answer is in that mission file somewhere.

EDIT2: Ok well a little closer but still confused lol. I managed to extract that mission pbo and got the mission opened up in the editor. Now, I can use "clear" and clear the whole map, place a new player (pilot) and a new A-10 (empty) and the HUD still works when I power up the jet. This leads me to believe that its getting executed by script from one of the other extracted files in that folder.
Title: Re: A-10 HUD?
Post by: Wolfrug on 10 Jan 2009, 11:34:36
I've tested this, and my conclusions are: at the default time of the year (in the editor), the HUD is only visible clearly at about 6 AM and earlier. Try it yourself : set the time to 6:30 (almost no HUD) and then to 6:00 (HUD clearly visible). During the night the HUD is lit up like...fireworks! I'm guessing the A-10 mission is simply set at a time/date that allows for the HUD to be visible.

So I'd say it's not the HUD disappears, it's just that it's not visible in daylight  :no:

Wolfrug out.
Title: Re: A-10 HUD?
Post by: kju on 10 Jan 2009, 13:46:00
i am not entirely sure, yet check the class MFD / class AirplaneHUD - especially class Draw

this should be what you are looking for.

if not search BI forum for nuxils work. he has done it from what i know:
http://forums.bistudio.com/ (use new VB search. far better)
Title: Re: A-10 HUD?
Post by: fortran on 10 Jan 2009, 15:30:34
@Wolfrug: AHHH YES!! I just checked for myself and your absolutely correct :). Mission 14 is also set at 5:50 pm as well, that is why I could see it on that map even when I cleared everything but not on the same map if I started from scratch! Thank you SO much! It doesn't fix the issue of it not being visible in daylight but at least we know why now. Thanks again!!

@PROPER.Q: Thanks mate, im just waiting on my membership details to come through (have to sign up for that forum via email!) then I will go search . As for the class MFD / class AirplaneHUD do you mean in the config ?

Anyway thanks again to everybody so far. Might continue with this (unless its been fixed by nuxils) so it can be seen at any time of day. Trouble is that means unless the TOD is correct in multiplayer (including custom missions) then no A-10 pilots will have their HUD.
Title: Re: A-10 HUD?
Post by: Planck on 10 Jan 2009, 16:40:09
Ah well, sounds to me like a negative effect from the HDR lighting effects of the game then.

I suspected it might be HDR at fault here, but it never occurred to me that there might be times where the hud would be visible.   :blink:

Title: Re: A-10 HUD?
Post by: kju on 10 Jan 2009, 16:51:13
yes config. not sure if you can influence the HDR effect on the HUD.
maybe check the rvmat of the a10 model.
Title: Re: A-10 HUD?
Post by: nuxil on 04 Feb 2009, 03:20:00
maybe this can help

you can adjust the alpha a bit. it helps a little .. but. as Wolfrug said about time.. the more light there is in the ENV the less you will see the hud!
Title: Re: A-10 HUD?
Post by: HailStorm on 08 Feb 2009, 18:35:03
hi fortran, sorry to hear about this problem, but a good question is what graphics card and driver are you using?

i'm currently using a nvidia 9800GT with the latest drivers, and before that a 7600gt - with both cards, i had no problem seeing either HUD at any time of day (i should know - i've been working on an A-10 mission for a very long time). maybe a simple hardware check may resolve your problem?