Garux / netradiant-custom

The open-source, cross-platform level editor for id Tech based games.
https://garux.github.io/NRC/
Other
301 stars 52 forks source link

Period in map filename causes q3map2 to output wrong srf file #102

Closed hemebond closed 1 year ago

hemebond commented 2 years ago

If I have a map called test.q3.map, the srf file created by q3map2 -bsp will be called test.srf:

--- WriteSurfaceExtraFile ---
Writing /path/to/maps/test.srf
Writing /path/to/maps/test.q3.bsp

This then causes -light to fail

--- ProcessCommandLine ---
entering scripts/shaderlist.txt
entering scripts/q3shadersCopyForRadiant.shader
Loading /path/to/maps/test.q3.bsp
Script file /path/to/maps/test.q3.srf was not found: No such file or directory
************ ERROR ************

I compiled from source:

#### Executing '"q3map2" -fs_basepath /usr/local/games/ioquake3 -leaktest /path/to/maps/test.q3.map'
2.5.17n-git-eed75b00
threads: 8
Q3Map         - v1.0r (c) 1999 Id Software Inc.
Q3Map (ydnar) - v2.5.17n-git-eed75b00
NetRadiant    - v1.5.0n-git-eed75b00 May 23 2022 14:01:25
Your map saw the pretty lights from q3map2's BFG
/home/james/.local/bin/q3map2
VFS Init: /home/james/.q3a/baseq3/
VFS Init: /usr/local/games/ioquake3/baseq3/
Garux commented 2 years ago

Thanks for reporting. This must be fixable, but not in general case, because q3map2 supports input file path w/o extension.