The Health UI displayes incorrectly When Head and Head attachments have different sourcerect and origin
Discussed in https://github.com/FakeFishGames/Barotrauma/discussions/14646
Originally posted by Raven-233486 September 16, 2024
Disclaimers
- [X] I have searched the issue tracker to check if the issue has already been reported.
- [X] My issue happened while using mods.
What happened?
The incorrect health UI
However, the character displays correctly:
Reproduction steps
Biff_W reported issue 12068 that headattachments' sourcerects are unchangeable last year and it had been fixed, here's the link: https://github.com/FakeFishGames/Barotrauma/issues/12068
However, the fix only covered character limb, not about the health interface.
Reproduction steps (Make hair and head have different sourcerects): In human.xml:
<Wearable type="Hair" commonness="0.05" >
<sprite name="Hair 1" texture="%ModDir:2809175631%/Content/Characters/Human/Headattachments/Human_decor.png" sourcerect="0,0,240,480" origin="0.6125,0.3229" inheritorigin="false" inheritsourcerect="false" />
</Wearable>
In HumanDefaultRagdoll.xml
<limb Name="Head (1)" ID="1" Type="Head" >
<sprite texture="%ModDir:2809175631%/Content/Characters/Human/Human_[GENDER]_heads.png" sourcerect="0,0,160,228" depth="0.05" origin="0.6125,0.33" color="255,255,255,255" deadcolor="255,255,255,255" deadcolortime="0" ignoretint="False" />
<tintmask texture="%ModDir:2809175631%/Content/Characters/Human/Human_[GENDER]_heads_mask.png" />
</limb>
Bug prevalence
Happens every time I play
Single player or multiplayer?
Single player
-
No response
Version
v1.5.9.2 (Summer Update Hotfix 2)
-
No response
Which operating system did you encounter this bug on?
Windows
Relevant error messages and crash reports
No response
Fixed in https://github.com/FakeFishGames/Barotrauma-development/commit/ee8c6f2f0b2fd92d32d3ed32ee5ac6064324b1d1
This problem still haven't been fixed https://github.com/FakeFishGames/Barotrauma/discussions/14646#discussioncomment-11023056
The fix unfortunately didn't make it to this update, we still need to review and test it internally before we can get it to a public build. Sorry for the inconvenience!
Merged, closing. Fix coming up in the next release!
@Regalis11 I have a similar issue #15722 that hair is misaligned in character creation menu