Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NamePlate Improvements #25

Merged
merged 12 commits into from
May 5, 2024
Merged

NamePlate Improvements #25

merged 12 commits into from
May 5, 2024

Conversation

NickMillion
Copy link
Contributor

@NickMillion NickMillion commented May 4, 2024

My git was freaking out about perms and branch nonsense so I just axed all my local stuff and re-forked and now it's working right.

Adds more functionality and customization to NamePlates:

  • Replaced instances of Vector3.Distance in update screen space position with sqrMagnitude for better performance
  • Separated NamePlates into their own config category
  • Added option to completely hide the health bar
  • Added option to enable nameplates through PiP optics
  • Added option to decrease opacity of nameplates in peripheral
  • Added option to adjust opacity of nameplates while aiming
  • Added option to hide nameplates past a certain distance w/ fade out and shrink
  • Added option for minimum opacity
  • Added option for minimum nameplate scale
  • Refactored to add throttled updating for element visibility; this also fixes certain elements not respecting the config changes after the awake()

I tried to use IsVisible for occlusion but it's basically nonfunctional, raycasting also had some issues so I removed it entirely

@Lacyway
Copy link
Member

Lacyway commented May 4, 2024

Need to fix DLSS/SSAA before I can merge, the peripheral alpha is not working well with it

@Lacyway Lacyway self-requested a review May 4, 2024 17:42
@MerijnHendriks MerijnHendriks added the enhancement New feature or request label May 4, 2024
@MerijnHendriks
Copy link
Contributor

MerijnHendriks commented May 4, 2024

Thank you very much for your PR! It's appriciated!

Replaced instances of Vector3.Distance in update screen space position with sqrMagnitude for better performance

Is it possible for you to split this into a separate PR? I would like to keep this PR a bit smaller to make it easier to review and revert in case it's required 👍

@NickMillion
Copy link
Contributor Author

This PR only includes the changes within the FikaHealthBar.cs file; it should be pretty self-contained.

I've essentially just refactored most of FikaHealthBar.cs while adding the new options and functionality with the only other file changed being FikaPlugin.cs to add the new config options.

@Lacyway Lacyway merged commit da3184c into project-fika:dev May 5, 2024
1 check failed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants