Open Ramalayha opened 4 years ago
Idk where the other is, but I'm pretty sure this is a duplicate issue
This is probably for the better though, so that when file.Find() is called with the DATA location, it doesn't have to recursively search through every workshop & legacy addon's data folders. I imagine on servers & clients where people have hundreds or even thousands of addons, this would have a noticible performance impact.
Edit: Never mind, misread.
https://wiki.facepunch.com/gmod/File_Search_Paths It shouldn't return data from addons. Only garrysmod/data
I think the goal here is to be able to publish things to workshop like "Advdupe2 vehicle pack" or "E2 script pack", but since the those addons read from DATA, it's impossible.
I think the goal here is to be able to publish things to workshop like "Advdupe2 vehicle pack" or "E2 script pack", but since the those addons read from DATA, it's impossible.
It is possible by manually copying each file to data folder using lua
Yea, that's the best solution probably.
gmad.exe can't pack files in data folder, but I think it should be fixed for legacy addons.
We probably don't want to fix this, because addons cannot edit files in addons/, and will not be allowed to do so, so fixing this would lead to uneditable files, and since addons take precedence over the root folder, "fixing" this would cause addon data files to always be found/read over the written files in the root data folder.
If you have a file path like "garrysmod/addons/my_addon/data/foobar.txt" then file.Find("foobar.txt", "DATA") won't return anything but file.Find("data/foobar.txt","GAME") will.