View Single Post
Marttt
Veteran Member
Join Date: Jan 2019
Location: Brazil
Old 03-26-2021 , 23:37   Re: How to override particles manifest?
Reply With Quote #4

Sorry for necro this thread. Don't know if you had solved this issue.

But I had this same question recently and your valve article link reference helped me a lot.

So first of all according to the wiki, if you change the "particles/particles_manifest.txt" it doesn't work, cause it will read the file inside the "pak01_dir.vpk" anyway.

Source here:
Code:
Source 2007 usage
Due to the recent Steampipe update, particles now require VPK integration. This is because the VPK takes priority over non-VPK files, so the VPK's manifest will always overwrite your own.
What I have tried on L4D2, I created a file inside the maps folder (dead center for example)
So my file will end like this: "left4dead2/maps/c1m1_hotel_particles.txt"
And I added a new line (based on the original "particles/particles_manifest.txt") to the end of the file

Would look something like this:

Code:
particles_manifest
{
	"file"		"!particles/error.pcf"
... // A lot of lines here
... // then

	"file"		"particles/custom_particle_test.pcf"
}
What I have to add to my plugin?
I had to use a FastDL to transmit this .txt to my clients and also the custom particle (.pcf)

So the code ended up like this:

PHP Code:
public void OnMapStart()
{
    
AddFileToDownloadsTable("maps/c1m1_hotel_particles.txt");
    
AddFileToDownloadsTable("particles/custom_particle_test.pcf");
    
PrecacheGeneric("particles/custom_particle_test.pcf"true);

Then it worked.

Just sharing here in case helps someone else.

Note: I didn't try the "particles/<mapname>_particles.txt" solution, which may work too.
This may not work for custom maps when the custom .vpk already has this file
__________________

Last edited by Marttt; 03-26-2021 at 23:40.
Marttt is offline