Decane / SRP

Sky Reclamation Project for S.T.A.L.K.E.R.: Clear Sky
http://www.moddb.com/mods/srp
124 stars 20 forks source link

Radiation progress bar is misaligned with certain aspect ratios #125

Open Georgiy-Timoshin opened 3 years ago

Georgiy-Timoshin commented 3 years ago

Fixes for the radiation indicator in the hud and inventory ss_admin_02-12-21_19-10-23_(escape) ss_admin_02-12-21_19-10-29_(escape) Not perfect better than it was. For 4x3 and 16x9. gamedata.zip P.S. Google Translate)

Decane commented 3 years ago

The radiation progress indicator is only misaligned in 5:4 mode; with widescreen resolutions, it's already properly aligned.

Thanks for supplying the 5:4 fix.

Committed in https://github.com/Decane/SRP/commit/7adee9b587d73e582a05ac89f01db223f166737a.

Decane commented 3 years ago

I jumped the gun. The radiation progress indicator is misaligned for 16:9 resolutions, too, not just 5:4. I wrongly concluded that the indicator isn't misaligned with any widescreen resolution on the basis that it is properly aligned with 16:10.

Decane commented 3 years ago

@Georgiy-Timoshin Your fix for 16:9 breaks the alignment for 16:10. And your fix for 4:3 (e.g. 1024x768) actually breaks 4:3 but fixes 5:4 (e.g. 1280x1024). In summary:

16:10 16:9 5:4 4:3
SRP :heavy_check_mark: :x: :x: :heavy_check_mark:
Your fix :x: :heavy_check_mark: :heavy_check_mark: :x:
Georgiy-Timoshin commented 3 years ago

You didn't notice, but there's also a new texture for the inventory(ui_hud2_rad01_over_new) and a fixed one for the hud on top of the arrow. I forgot about the problem of different aspect ratios on the same file. It's bad that can't make your own file for each aspect ratio.

Decane commented 3 years ago

Here is a table with the required positions of HUD element ui_hud2_rad01_progress in order for it to appear properly aligned under each of the four aforementioned aspect ratios:

Required x, y for ui_hud2_rad01_progress 16:10 16:9 5:4 4:3
actor_menu.xml - - x="3" y="37" x="3" y="40" (default)
actor_menu_16.xml x="2" y="40" x="2" y="44" - -
maingame.xml - - x="166" y="52" x="166" y="55" (default)
maingame_16.xml x="138" y="55" (default) x="138" y="59" - -
Georgiy-Timoshin commented 3 years ago

Yes, I've already figured that out. The main fix is these textures: 1 2

Decane commented 10 months ago

The texture that partially obscures the radiation detector's dial in the inventory screen does not blend properly when using the optional Transparent Inventory feature:

image

Georgiy-Timoshin commented 10 months ago

Moved the texture covering the radiation detector from "ui_hud.dds" to "ui_ingame2_common.dds". This will allow you to use "transparent inventory" without problems. The texture that is replaced in the "transparent inventory" mod (ui_ingame2_common.dds) does not have this insert and therefore everything will look the same. gamedata.zip

изображение

Decane commented 10 months ago

Radiation detector dial overlay fixed in https://github.com/Decane/SRP/commit/13e5122fe6b0abbd669a39dccf2e43fa863e8bd2.

I'm not sure how to fix the vertical misalignment of the red radiation progress bar across different aspect ratios, however. The game seems to have been made with 4:3 and 16:10 in mind and the progress bar doesn't scale correctly to 5:4 and 16:9. stretch="1" doesn't help. I don't really want to have aspect ratio -specific variants of actor_menu*.xml and maingame*.xml that the user must select between.

Georgiy-Timoshin commented 10 months ago

textures overlapped: ss_io_12-04-23_18-02-37_(marsh) here's the fix: gamedata.zip

Decane commented 10 months ago

Thanks - included in https://github.com/Decane/SRP/commit/78d11f155c27d7e1e7203f8e7ae260a4b950ec08.

vlad54rus commented 9 months ago

@Decane Speaking of widescreen - can you also include this fix for scope textures? They are slightly stretched on 16:9. gamedata.zip

Decane commented 9 months ago

Alex_Demolisher on ModDB sent me a nearly identical widescreen scopes fix in 2018 — the only difference being that his had width 129 instead of 128 for each wpn_crosshair_add_l. But I decided not to include it because it made scope textures vertically elliptical (stretched) on 16:10; it turned out that 16:9 needs the fix but 16:10 doesn't. And I didn't want to break 16:10 to fix 16:9.

@vlad54rus your fix has the same problem:

Screenshot2196

SurDno commented 9 months ago

Why not make 5:4/16:10 support a separate install, similarly to how Widescreen Patch used to be?