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

Shell script improvement suggestions #550

Closed
qkeitoe opened this issue Nov 26, 2024 · 6 comments
Closed

Shell script improvement suggestions #550

qkeitoe opened this issue Nov 26, 2024 · 6 comments

Comments

@qkeitoe
Copy link
Contributor

qkeitoe commented Nov 26, 2024

  • budhud-compiler has a very cool option --omitMissingDirectives. It seems to speed up hud_reloadscheme a bit (on potato PCs). But on the other hand, this option breaks things if any HUD mods are installed outside of budhud (not sure if it's a common case). So, I would like to suggest asking a user before compiling if they want to enable this option or not (not sure about the default choice though).
  • Recent updates to the shell script have added the parent directory check. However, 4 of the 6 script functions do not need this to work properly (if I understand it right). I don't know how many weirdos like me who keep all HUDs in one place and put either a symlink or in the case of budhud a compiled version in custom, but I'd really appreciate it if it could again be possible to compile the HUD with no need to run the script from tf/custom/<budhud folder name>/.

If you approve of any suggestions, I can potentially try to implement them (though I have barely any experience with powershell).

@rbjaxter
Copy link
Owner

For the first point, I'm a bit hesitant about it just because I have to imagine the compiler is already giving 99% of the performance benefits just from its initial pass of combining base directives. The only thing that flag would really be saving lines on are some "disabled by default" customization lines. I'm just not sure if the trade-off of the marginal performance gain outweighs the fact that they're stuck with whatever version of the hud they compiled (essentially). I suppose making it an option does allow someone to get the most pure-blooded non-#base-using-hud possible, but I just hope it wouldn't cause more confusion for those that use it.

For the parent directory check, I think i need to take a closer look myself at how that check compares to Check_HUDFiles and perhaps combine them. I may redo all the checks to avoid redunancy and also clean up them a bit more.

rbjaxter added a commit that referenced this issue Nov 28, 2024
Removes broad script location check in favor of localizing checks into individual functions where needed

also some minor changes to the compiler backup behavior
@rbjaxter
Copy link
Owner

@qkeitoe Let me know if this change to the check works for what you're doing. hopefully should, it just checks for folders it needs

@qkeitoe
Copy link
Contributor Author

qkeitoe commented Nov 30, 2024

Oh yeah, it works perfectly fine! Thanks! Sorry for not letting you know sooner.

@rbjaxter
Copy link
Owner

rbjaxter commented Dec 2, 2024

@qkeitoe That last commit adds a prompt for --omitMissingDirectives as well, I tested it on my end and had no issues but let me know if you run into anything 👍

@qkeitoe
Copy link
Contributor Author

qkeitoe commented Dec 4, 2024

One minor note: I think it's better to prompt a user for the m flag usage prior to

$StopWatch = [System.Diagnostics.Stopwatch]::StartNew()

@rbjaxter
Copy link
Owner

rbjaxter commented Dec 5, 2024

Agreed, I'll change that in a future commit

rbjaxter added a commit that referenced this issue Dec 8, 2024
In essence, instead of hiding player names outright this will draw names as squares. Places where player names are shown solely show squares whereas places that have important numbers (TargetID for medic charge, etc) will show squares & numbers.

Screenshots can be found in the GitHub issue that explain it better than I can #550
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants