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

PD HUD icons set by SetCountdownImage input in TF2 are not automatically packed #199

Open
14bit opened this issue Mar 8, 2023 · 4 comments

Comments

@14bit
Copy link

14bit commented Mar 8, 2023

In the mode Player Destruction in TF2, the texture used for the timer in the HUD can be changed mid-round via map logic. This is done by sending the tf_logic_player_destruction entity a SetCountdownImage input, similar to how the SetModel input works. Custom textures specified in this way function, but are not caught by CompilePal's automatic packing.

@Exactol
Copy link
Collaborator

Exactol commented Mar 25, 2023

Exactol added a commit that referenced this issue Mar 25, 2023
Refactored how I/O referenced assets are handled
#199
@Exactol
Copy link
Collaborator

Exactol commented Jul 29, 2023

Has your issue been resolved?

@14bit
Copy link
Author

14bit commented Jan 18, 2024

In both this build and the one you gave me in #228, the textures are now caught by CompilePal and packed correctly in most cases, provided they are in the /vgui folder.

Everything below is an edge case that causes the textures to be packed incorrectly:

In some cases, PD HUD textures can be placed in the wrong locations in the .BSP due to the inputs using ../ at the start to specify the file path. In this case, the .vtfs are put in the correct places, but the .vmts have an added vgui/../ at the start. Moving the files to be packed into /vgui, modifying the materials to match, and changing the inputs in hammer to remove the ../hud/ resulted in them packing correctly, so you can probably claim this is "user error."

Below is the setup that does not work:

Here was one of the old inputs in Hammer before I moved the textures:
image

Here is what got packed in CompilePal before I moved the textures:
CompilePalX_2024-01-18_14-44-54

Here's where the custom textures were in my /custom folder before I moved the textures:
image

And here's what it looked like in the final packed .BSP (looking at it with GCFScape) before I moved the textures:
GCFScape_2024-01-18_14-40-59

@Exactol
Copy link
Collaborator

Exactol commented Jan 20, 2024

If the relative paths work in game I'd say its probably a bug on my side, this build should fix the issue https://www.dropbox.com/scl/fi/izhbxvjcj6knk27ezl00l/Compile-Pal-028.2.zip?rlkey=iiekwopnn2tpbbwdu98nu0erp&dl=0 . If it's not too difficult could you move your files back to the hud folder and test it for me?

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