Jump to content

[WIP] [1.12.x] HUDReplacer - (v1.2.11-beta)


UltraJohn

Recommended Posts

  

5 hours ago, zapsnh said:

Does anyone know what the Steam (presumably the Steam Workshop) icon texture in the VAB is called?

steamButton.

 

2 hours ago, mateusviccari said:

I'm seeing some missing buttons in the RP-1 tech tree, can this be the culprit (I'm using ZTheme)?

0kRZAh1.png

Probably not, although I haven't tried RP-1 so I don't know how it interacts with that. Try removing HUDReplacer and see if it's fixed, and post your logs.

Edited by UltraJohn
Link to comment
Share on other sites

1 hour ago, UltraJohn said:

  

steamButton.

 

Probably not, although I haven't tried RP-1 so I don't know how it interacts with that. Try removing HUDReplacer and see if it's fixed, and post your logs.

Did that, the culprit was actually "Hide empty tech tree nodes". Should have tried it before posting, sorry for that. Amazing mod by the way, revamping the interface was something that made the game even more enjoyable.

Link to comment
Share on other sites

2 minutes ago, mateusviccari said:

Did that, the culprit was actually "Hide empty tech tree nodes". Should have tried it before posting, sorry for that. Amazing mod by the way, revamping the interface was something that made the game even more enjoyable.

Ah, I had a feeling that might've been the case. No problem, it happens. :) 

Thanks! Glad you're enjoying it!

Link to comment
Share on other sites

On 6/2/2023 at 9:02 PM, UltraJohn said:

Ok so in your screenshot I noticed it's actually loading some of your textures already. That would indicate it might be using the same scene as the main menu.

Since there's no toolbar button on the main menu, what you can try is loading into KSC to spawn the button, then enable debug, back out to the main menu and then try the debug hotkeys. Let me know how that goes.

It doesn't work.

I think going to the KSC, enabling debug (and pressing Q), backing out to the main menu and then going to mission builder was the reason it loaded in the first place since I went into the mission builder first and the textures didn't load.
Oh and it seems that the mission select dialog uses the same textures as the VAB/SPH since it was mostly themed when I opened it (though it's only themed when I do the steps above).

(and for some reason doing the steps above can result in the play mission dialog to be half themed until I press Q again)

Link to comment
Share on other sites

1.2.0-pre is released.

This is a pre-release for testing everything works as intended before going on CKAN.

https://github.com/UltraJohn/HUDReplacer/releases/tag/1.2.0-pre

 

What's Changed

  • Bit of code cleanup
  • Added support for recoloring the PAW Titlebar, and the Tumber numerals. See below for an example config. Let me know if there's other textures that cannot be recolored through the texture itself, and I will add support for those as well.
  • Added dependency for HarmonyKSP. Will be required going forward.

 

Config example:

HUDReplacerRecolor:NEEDS[HUDReplacer]
{
	priority = 1 // Same as main config
	tumblerNumerals = 1,0,0,1 // RGBA (values from 0-1)
	PAWTitleBar = 0,0,1,1 // RGBA (values from 0-1)
}

 

1 hour ago, zapsnh said:

It doesn't work.

I think going to the KSC, enabling debug (and pressing Q), backing out to the main menu and then going to mission builder was the reason it loaded in the first place since I went into the mission builder first and the textures didn't load.
Oh and it seems that the mission select dialog uses the same textures as the VAB/SPH since it was mostly themed when I opened it (though it's only themed when I do the steps above).

I think you're right, that going to KSC first was the reason some textures loaded. between certain scenes there are textures that persist and don't unload, which is what you're seeing. Since the debug mode also persists between scenes, I figured it would let you use the hotkeys, but it looks like it might be a separate scene after all. The hotkeys won't function in any scene I haven't specified. I'll look into this some more, and worse case scenario I'll just have to buy the dlc so I can properly figure it out. Thanks for testing.

Link to comment
Share on other sites

8 hours ago, UltraJohn said:

Added support for recoloring the PAW Titlebar, and the Tumber numerals. See below for an example config.

Does the recolor also affect the tumbler color when the altimeter/ship is below sea level? (ignore everything else I am too lazy to crop it out and this is just a pic from a reddit post)
modded-ksp-1-looks-so-beautiful-v0-2z3jn

8 hours ago, UltraJohn said:

Let me know if there's other textures that cannot be recolored through the texture itself, and I will add support for those as well.

From the picture above (and what I can remember):
Navball Markers (the pointer thing and the vectors)
Ship Fuel Indicators
Stage deltaV numbers
Gauge Needle
Gauge Knob (the vertical speed knob)
Upper left Mission Time and CommNet status
 

Link to comment
Share on other sites

2 minutes ago, zapsnh said:

Does the recolor also affect the tumbler color when the altimeter/ship is below sea level? (ignore everything else I am too lazy to crop it out and this is just a pic from a reddit post)

It's funny, I was literally just thinking this when I was watching a KSP stream on twitch right now lol. I suppose it would overwrite the color since going underwater causes the numbers to change color, but I don't know for sure as I haven't tested that.

 

3 minutes ago, zapsnh said:

From the picture above (and what I can remember):
Navball Markers (the pointer thing and the vectors)
Ship Fuel Indicators
Stage deltaV numbers
Gauge Needle
Gauge Knob (the vertical speed knob)
Upper left Mission Time and CommNet status

Thanks. If you can provide the names of these textures as well, that would help speed it up a little.

Link to comment
Share on other sites

4 minutes ago, UltraJohn said:

Thanks. If you can provide the names of these textures as well, that would help speed it up a little.

In a bit of a rush rn so I can't give you the most texture names but I can remember two:
GaugeNeedle.png
GaugeKnob.png

Link to comment
Share on other sites

I heard if you tag @HebaruSanhe will appear and grant you three wishes.

Hi, I'd like to request a metadata change for CKAN. I'm not sure where I'd do this myself. I need to add HarmonyKSP as a dependency for HUDReplacer version 1.2.0 and forward. I've currently flagged this release as a pre-release on github to avoid it going live on CKAN until then.

From HarmonyKSP's github page this should be what's required:

"depends": [ { "name": "Harmony2" } ],

Thanks! :)

Link to comment
Share on other sites

5 minutes ago, Nazalassa said:

It does work... Except for the KAL window, which still has its "ugly" orange bar. But its icons and stuff do load properly, no need to press 'q' on scene change anymore :)

 

Ah, I had a feeling that would be the case. I did notice last night that both the PAW titlebar and the KAL titlebar uses the same texture, which I figured means they both need an override for the color in code.

While I was fixing up the Tumbler number colors I realized why the Tumbler specifically was colored in code. It's due to going underwater having a different color for the numbers, so ofcourse instead of swapping textures they just recolor it.

As zap mentioned in a previous post, there's a few other textures that are colored in code, and I'm wondering if there's a specific reason for those as well. You'll have to let me know if you come across one of these textures changing back to the original color when doing certain things (when I get them added in a future update).

Link to comment
Share on other sites

1.2.2-beta is released.

https://github.com/UltraJohn/HUDReplacer/releases/tag/1.2.2-beta

What's Changed

  • First non-prerelease of the new features, as it should be stable now
  • A few optimizations
  • You can now change the color of the tumbler's positive and negative value independently. The recolor config options have been slightly altered to accomodate this. See the config example below for a list of all currently possible recolor options

 

HUDReplacerRecolor:NEEDS[HUDReplacer]
{
	priority = 1
	tumblerColorPositive = 0,1,0,1 // RGBA value from 0-1
	tumblerColorNegative = 0,0,1,1 // RGBA value from 0-1
	PAWTitleBar = 0,0,1,1 // RGBA value from 0-1
}

 

Link to comment
Share on other sites

5 hours ago, UltraJohn said:

1.2.2-beta is released.

https://github.com/UltraJohn/HUDReplacer/releases/tag/1.2.2-beta

What's Changed

  • First non-prerelease of the new features, as it should be stable now
  • A few optimizations
  • You can now change the color of the tumbler's positive and negative value independently. The recolor config options have been slightly altered to accomodate this. See the config example below for a list of all currently possible recolor options

 

HUDReplacerRecolor:NEEDS[HUDReplacer]
{
	priority = 1
	tumblerColorPositive = 0,1,0,1 // RGBA value from 0-1
	tumblerColorNegative = 0,0,1,1 // RGBA value from 0-1
	PAWTitleBar = 0,0,1,1 // RGBA value from 0-1
}

 

I haven't been able to play KSP that much so I couldn't test the recoloring but how do I recolor the tumbler?  It doesn't work.

Config:

Spoiler

HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/PluginData/
    priority = 1
}
HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/universalUI/
    priority = 2
}
HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/vab/
    priority = 4
}
HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/ksc/
    priority = 3
}
HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/flight/
    priority = 5
}
HUDReplacer:NEEDS[HUDReplacer]
{
    filePath = GameData/ZTheme/mods/
    priority = 10
}
HUDReplacer:NEEDS[HUDReplacer,GPP]
{
    filePath = GameData/ZTheme/gpp/
    priority = 6
}
HUDReplacerRecolor:NEEDS[HUDReplacer]
{
    priority = 100
    tumblerColorPositive = 0,1,0,1
    tumblerColorNegative = 0,0,1,1
    PAWTitleBar = 0,0,1,1
}

 

Link to comment
Share on other sites

9 hours ago, zapsnh said:

I haven't been able to play KSP that much so I couldn't test the recoloring but how do I recolor the tumbler?  It doesn't work.

 

The config is correct, the problem is that I accidentally made a typo in the code right before releasing that build. Oops! :D 

 

 

1.2.3-beta is released.

A quick hotfix

https://github.com/UltraJohn/HUDReplacer/releases/tag/1.2.3-beta

 

What's Changed

  • Fixed a typo in the tumbler positive color setting
Edited by UltraJohn
Link to comment
Share on other sites

On 6/5/2023 at 12:07 AM, zapsnh said:

From the picture above (and what I can remember):
Navball Markers (the pointer thing and the vectors)
Ship Fuel Indicators
Stage deltaV numbers
Gauge Needle
Gauge Knob (the vertical speed knob)
Upper left Mission Time and CommNet status

You might wanna recheck these, as I just spent some time writing a patch for GaugeNeedle, GaugeKnob, and GaugePointer which it turns out I didn't need to. They can be colored normally through the texture.

 

Though the ones I can confirm needs a patch is the navball markers and the mission time.

And by CommNet I assume you mean the green icons, and the stage deltaV is the text? And the ship fuel indicator I don't know which one you mean :)

Link to comment
Share on other sites

Just now, UltraJohn said:

You might wanna recheck these, as I just spent some time writing a patch for GaugeNeedle, GaugeKnob, and GaugePointer which it turns out I didn't need to. They can be colored normally through the texture.

The knobs in the bottom-left corner (and possibly others) will probably need a patch, as they're applied color overlay (they turn orange and blue and stuff like this).

Link to comment
Share on other sites

11 minutes ago, Nazalassa said:

The knobs in the bottom-left corner (and possibly others) will probably need a patch, as they're applied color overlay (they turn orange and blue and stuff like this).

You mean the Yaw/Roll/Pitch?

Link to comment
Share on other sites

1.2.4-beta is released.

https://github.com/UltraJohn/HUDReplacer/releases/tag/1.2.4-beta

 

What's Changed

  • KAL Titlebar recolor support
  • Yaw/Pitch/Roll gauge needle recolor support
  • Clock recolor support

 

These are the currently allowed recolor options:

HUDReplacerRecolor:NEEDS[HUDReplacer]
{
	priority = 1
	tumblerColorPositive = 0,1,0,1 // RGBA values from 0-1
	tumblerColorNegative = 0,0,1,1
	PAWTitleBar = 0,0,1,1
	KALTitleBar = 0,1,1,1
	gaugeNeedleYawPitchRoll = 1,0,0,1
	gaugeNeedleYawPitchRollPrecision = 0,1,0,1
	METDisplayColorRed = 0,0,1,1
	METDisplayColorYellow = 1,0,1,1
	METDisplayColorGreen = 0,1,1,1
}

 

Link to comment
Share on other sites

16 minutes ago, OnlyLightMatters said:

Hi all.
I did not understand whether this mod is able to replace the Navball Texture without using the NavBallTextureChanger mod.
Is it?

You can replace the navball texture without NavBallTextureChanger, it's navball#512x256.png. AFAIK HUDReplacer only supports 512x256 textures while NavBallTextureChanger supports up to 1024x512 and it doesn't replace the IVA navball.

(also HUDReplacer can replace other things, not just the HUD *cough* *cough* *cough*)
(just realized that it's very similar to TextureReplacer since it can replace planet textures, skybox, and kerbal heads))

Edited by zapsnh
Link to comment
Share on other sites

1 hour ago, zapsnh said:

AFAIK HUDReplacer only supports 512x256 textures

What if you omit the texture size from the file name? The size is there to avoid overwriting similarly named textures on other objects, but if the game only has one reference to a "navball" texture, then it should be fine doing that. Like for example "rect_round_color" has 4 different textures with various sizes, and this is where you'd need to use file size in the file name.

 

1 hour ago, zapsnh said:

(just realized that it's very similar to TextureReplacer since it can replace planet textures, skybox, and kerbal heads))

Fun fact, I initially wanted to name this mod TextureReplacer, but as it already existed I had to pick something else!

Also from what I know, TR is more focused on the replacement of kerbal space suits, correct? Whereas this mod is more focused on the HUD specifically, although some form of overlap will occur between these two mods.

Link to comment
Share on other sites

24 minutes ago, UltraJohn said:

What if you omit the texture size from the file name? The size is there to avoid overwriting similarly named textures on other objects, but if the game only has one reference to a "navball" texture, then it should be fine doing that. Like for example "rect_round_color" has 4 different textures with various sizes, and this is where you'd need to use file size in the file name.

It works!
Let's see if I can use a ludicrously hi res image for the navball.

--

I can confirm that 16K textures work. Unfortunately, my computer, for some unknown reason idk why, just didn't want to resize the texture to 32K and died for no real reason.

Edited by zapsnh
Link to comment
Share on other sites

4 hours ago, UltraJohn said:

What if you omit the texture size from the file name? The size is there to avoid overwriting similarly named textures on other objects, but if the game only has one reference to a "navball" texture, then it should be fine doing that. Like for example "rect_round_color" has 4 different textures with various sizes, and this is where you'd need to use file size in the file name.

Should allow us to get rid of all these issues with misaligned pixels because the texture is 1 pixel too wide :)

Link to comment
Share on other sites

This thread is quite old. Please consider starting a new thread rather than reviving this one.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...