DarkPlacesEngine / DarkPlaces

The DarkPlaces Quake engine, created by LadyHavoc. Official Git repository (replaces SVN).
https://icculus.org/twilight/darkplaces/
GNU General Public License v2.0
290 stars 43 forks source link

Use imageformats_nopath when looking for per-map texture overrides #207

Open hemebond opened 2 months ago

hemebond commented 2 months ago

Merge imageformats_nopath into imageformats_other and remove its use. This now correctly loads per-map texture overrides that are looked for in the textures directory.

Fixes #198

divVerent commented 1 month ago

This removes support for %s.lmp - is that intended?

divVerent commented 1 month ago

Also wonder if it wouldn't be better to add the override/ variants everywhere.

hemebond commented 1 month ago

Also wonder if it wouldn't be better to add the override/ variants everywhere.

That definitely is not intended, but I suspect lmp files are only used for the interface and menus and are usually under /gfx which would get caught by imageformats_gfx. Ironwail only seems to load /gfx/*.lmp.

Any idea why each imageformats_nopath seems to restrict the types? Could we just add lmp to imageformats_nopath?

divVerent commented 1 month ago

First of all, no objections to adding lmp to imageformats_nopath.

The other issue I have is - this makes imageformats_other unused. So maybe just merge the two into one (and call it imageformats_other, as there now is no more special handling for texture names without a slash)?

hemebond commented 1 month ago

@divVerent Thanks, I've merged _nopath into _other. Tested with texture override mod and it still correctly loaded the map-specific overrides.

divVerent commented 1 month ago

This change is definitely harmless now - once someone tested it that it at least does no damage (it really shouldn't be able to, other than slightly more IO load during map load), it should be OK to merge.