Previous Thread
Next Thread
Print Thread
Rate This Thread
Hop To
Page 7 of 9 1 2 3 4 5 6 7 8 9
#4482911 - 07/15/19 04:55 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Ok, I've got the new MFD to display the same as the existing CRT display. I did this by changing the texture of the new MFD surface to be the same one used by the main CRT. The file I selected in LW is a TGA file, and I converted the objects with the TGA file, and it works. However, I know that the textures.bin contains the BMP version of the file with the same name, so it might be ignoring the TGA file from LW, and using the BMP file. I also think this, as the texture folder does not contain the required TGA file. I think there might be some caching in memory as well, as earlier I got an error when I deleted the texture file, and now I'm not.

But I'm not going to worry about that for now.

I'm going to experiment some more, by changing the main CRT to use the new texture file, and see if I can get it to work the other way round.

Attached Files IMAGE016.jpgIMAGE017.jpg
#4482916 - 07/15/19 05:04 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


if you copy mfd texture and paste in another place , this also works.

#4482920 - 07/15/19 05:18 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Now I changed the main CRT and the small MFD to use a new texture file, copied from the same file that the main CRT uses. In textname.h it is a new entry for this, so I changed the mfd code to use this new entry, but it doesn't render either MFD now. It's using a BMP file, with all the same LW surface settings as in my previous post, with just the texture file changed.

This is the problem we're having trying to add a new MFD.

We can't use the existing MFD filename, as this is what is referred to in the code. It basically says, find a texture called X and render the MFD on it. But copying that code, but for a new MFD doesn't want to work. Each MFD has to have a unique texture name.

Attached Files IMAGE018.jpg
#4482922 - 07/15/19 05:30 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


In apache cpg both mfd were hardcoced, uneditable.
just like here. thealx made them editable.
if you understand what the thealx did in apache cpg, you will find the golden grail wink

#4482924 - 07/15/19 05:50 PM Re: Mi-28 Working Instrument Needles [Re: ]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Originally Posted by BANITA
In apache cpg both mfd were hardcoced, uneditable.
just like here. thealx made them editable.
if you understand what the thealx did in apache cpg, you will find the golden grail wink


The apache A or D? I'll have a look again at those, but I think I went through a lot of the code already.

#4482925 - 07/15/19 05:56 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


D of course. arneh made this mfd hardcoded.
thealx made editable.

#4482928 - 07/15/19 06:19 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
I wonder if it's not rebuilding the index for the textures somehow.

This is the line of code from ha_mfd.c that assigns the texture.

Code
mfd_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_HAVOC_TRQ_GAUGE, TEXTURE_TYPE_SINGLEALPHA);


The TEXTURE_INDEX_HAVOC_TRQ_GAUGE refers to the index in textname.h. In the IDE, it resolves as 2318, which relates to the index. But maybe it's not rebuilding the index. I'll try adding some logging and see what happens. If I change textname.h and run a dmake build, it doesn't show anything changing. If I run remake, then dmake, it rebuilds everything again, but hasn't fixed the MFD display.

#4482931 - 07/15/19 06:25 PM Re: Mi-28 Working Instrument Needles [Re: ]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Originally Posted by BANITA
D of course. arneh made this mfd hardcoded.
thealx made editable.


I had a look. He reused existing textures from the Hokum, so maybe he couldn't get a new one either??

Code
	lhs_mfd_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_AVCKPT_DISPLAY_LHS_MFD, TEXTURE_TYPE_NOALPHA);
	rhs_mfd_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_AVCKPT_DISPLAY_RHS_MFD, TEXTURE_TYPE_NOALPHA);
	cpg_lhs_mfd_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_HOKUM_COCKPIT_MFD_LHS_1, TEXTURE_TYPE_NOALPHA);
	cpg_rhs_mfd_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_HOKUM_COCKPIT_MFD_RHS_1, TEXTURE_TYPE_NOALPHA);
	ort_texture_screen = create_system_texture_screen (mfd_texture_size, mfd_texture_size, TEXTURE_INDEX_HOKUM_COCKPIT_MFD_RHS_2, TEXTURE_TYPE_SCREEN);


However, there is a new texture for the Hind Map.

#4482933 - 07/15/19 06:31 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


"He reused existing textures from the Hokum, so maybe he couldn't get a new one either??"

Yes! Is impossible edit hardcoded mfd. you can only reuse another,I thought it was known.

#4482935 - 07/15/19 06:39 PM Re: Mi-28 Working Instrument Needles [Re: ]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Originally Posted by BANITA
"He reused existing textures from the Hokum, so maybe he couldn't get a new one either??"

Yes! Is impossible edit hardcoded mfd. you can only reuse another,I thought it was known.


What do you mean by hardcoded?

I can't understand why we can't add new MFD's. That's what Javelin and I have been trying to work out.

Do you mean you have to use an existing MFD texture name, instead of being able to add new ones? How did the Hind get added then, as it has a new texture for the moving map.

This is the end of textname.h showing the new Hind ones added, then a comment saying to add new ones at the end

Code
	TEXTURE_INDEX_LAST_DEFAULT_INDEX = TEXTURE_INDEX_WOOD_PLANK,

	// DO NOT EDIT THESE NAMES, THEY ARE HARDCODED
	TEXTURE_INDEX_AVCKPT_DISPLAY_CPG_LHS_MFD,
	TEXTURE_INDEX_AVCKPT_DISPLAY_CPG_RHS_MFD,
	TEXTURE_INDEX_AVCKPT_DISPLAY_ORT,
	TEXTURE_INDEX_AVCKPT_ALNUM_DISPLAY,
	TEXTURE_INDEX_AVCKPT_ALTITUDE_COUNTER,
	TEXTURE_INDEX_HIND_MAP_DISPLAY,

	// INSERT NEW TEXTURE INDICES HERE (before TEXTURE_INDEX_LAST, after everything else)

	TEXTURE_INDEX_HAVOC_TRQ_GAUGE,

	TEXTURE_INDEX_LAST,

#4482936 - 07/15/19 06:47 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


Now we are MUCH closer to find solutnion biggrin

Im not programmer. Hardcoded i think i mean that havoc cockpit, and apache arneh cpg no have any AVCKPT_DISPLAY_CPG_LHS_MFD (or similar)texture. And cannot be editable.

As we see also arneh and thealx made the same, copied ka52 mfd texture, and this is only way to make editable mfds.

#4482940 - 07/15/19 07:20 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Apr 2018
Posts: 300
Javelin Offline
Member
Javelin  Offline
Member

Joined: Apr 2018
Posts: 300
Idaho Falls, Idaho USA
Even if we have to reuse an existing texture, there are plenty to choose from. Comanche has eight.

#4482942 - 07/15/19 07:22 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
I changed the small MFD to use a comanche one, and now it's not showing at all in the cockpit. However, I think that's progress as I wouldn't expect it to render if the code had found it as an MFD surface. It's not drawing the engine bars on it though, so I'll investigate why.

#4482943 - 07/15/19 07:36 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  

**DONOTDELETE**
Unregistered
BANITA
Unregistered


I think you need to find out how it is done, that it recognizes the Hind cockpit instead of ka52 etc



And probably i found reason smile first released ee apache havoc and this game has no editable hardcoded mfds.
netx released much modern ee comanche hokum and this helos has editable mfds.

Last edited by BANITA; 07/15/19 07:37 PM.
#4482963 - 07/15/19 11:06 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
I'm going to leave this for now and concentrate on finishing off the instruments for the KA50. I'm not far from having them all working. Maybe Javelin can progress some more with what I've found so far.

#4482983 - 07/16/19 02:33 AM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Apr 2018
Posts: 300
Javelin Offline
Member
Javelin  Offline
Member

Joined: Apr 2018
Posts: 300
Idaho Falls, Idaho USA
I just need the HAVOC_TRQ_GAUGE.lwo or eeo with the copied Comanche texture attached to it. I can take it from there. It will have to wait until Friday though, I'm on 12 hr shift work until Thursday. Don't worry about the code, I can make it work with new.

#4483413 - 07/19/19 10:52 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Apr 2018
Posts: 300
Javelin Offline
Member
Javelin  Offline
Member

Joined: Apr 2018
Posts: 300
Idaho Falls, Idaho USA
Well, I tried a few more things, but no luck. I need someone who does modeling to paste a working MFD screen object from a different helicopter into the Havoc HAVOC_VIRTUAL_COCKPIT_INSTRUMENT_NEEDLES.ees file right over the engine gauges, then save it. Send me the ees or lws file and the name of the MFD object you pasted in (and the texture name if you know what it is) then I can fix the Havoc engine gauges. I don't think it will work any other way.

I can send you the NEEDLES.lws file if you tell me where to send it via a PM.

I think I'll go work on something else for a while.

Last edited by Javelin; 07/19/19 10:53 PM.
#4483455 - 07/20/19 06:10 AM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
You can download the trq gauge object and scene here

https://drive.google.com/open?id=1XzgMjktq9GVxVyKIsfqo-KenX-k86LaV

The texture for the MFD is called COMANCHE_MFD1

#4483477 - 07/20/19 02:19 PM Re: Mi-28 Working Instrument Needles [Re: messyhead]  
Joined: Apr 2018
Posts: 300
Javelin Offline
Member
Javelin  Offline
Member

Joined: Apr 2018
Posts: 300
Idaho Falls, Idaho USA
Excellent! Thanks, I'll get back to work on it.

Yes! We have ignition! It's drawing right over the engine gauges, transparent. Now I just need to draw the bars in the right places.

Last edited by Javelin; 07/20/19 02:46 PM.
#4483483 - 07/20/19 03:12 PM Re: Mi-28 Working Instrument Needles [Re: Javelin]  
Joined: Dec 2010
Posts: 1,883
messyhead Offline
Member
messyhead  Offline
Member

Joined: Dec 2010
Posts: 1,883
Originally Posted by Javelin
Excellent! Thanks, I'll get back to work on it.

Yes! We have ignition! It's drawing right over the engine gauges, transparent. Now I just need to draw the bars in the right places.


Awesome

Page 7 of 9 1 2 3 4 5 6 7 8 9

Moderated by  RacerGT 

Quick Search
Recent Articles
Support SimHQ

If you shop on Amazon use this Amazon link to support SimHQ
.
Social


Recent Topics
Grown ups joke time
by NoFlyBoy. 03/18/24 10:34 PM
Anyone Heard from Nimits?
by F4UDash4. 03/18/24 10:01 PM
RIP Gemini/Apollo astronaut Tom Stafford
by semmern. 03/18/24 02:14 PM
10 years after 3/8/2014
by NoFlyBoy. 03/17/24 10:25 AM
Hans Zimmer North American concert tour 2024
by NoFlyBoy. 03/16/24 10:54 PM
Steam Spring Sale.
by RedToo. 03/15/24 09:09 PM
Starship Attempt Three
by F4UDash4. 03/14/24 12:06 PM
This is one cool turbofan model
by Zamzow. 03/14/24 02:41 AM
Map Errors
by F4UDash4. 03/13/24 11:25 AM
Copyright 1997-2016, SimHQ Inc. All Rights Reserved.

Powered by UBB.threads™ PHP Forum Software 7.6.0