ericwa / ericw-tools

Quake/Hexen 2 Map compiling tools - branch of http://disenchant.net/utils
http://ericwa.github.io/ericw-tools
GNU General Public License v2.0
309 stars 56 forks source link

31 character texture name length limitation relative to basedir, anything beyond that is silently discarded #396

Closed starfrost013 closed 7 months ago

starfrost013 commented 7 months ago

I am working on a quake 2 engine based game and this is not even indicated in a warning message, it would be nice to overload it with a command-line option or something.

lavenderdotpet commented 7 months ago

how r u gettint wads with textures above 31char

starfrost013 commented 7 months ago

i'm not using wads???? it's quake 2 based and I made engine modifications (.TGA textures only mostly) but the texture file name size limit is stlill arbitrary???

lavenderdotpet commented 7 months ago

agh i keep forgetting tho i think u can still use wads with q2

sorry about that

ericwa commented 7 months ago

It's limited to 31 chars in the Q2 .bsp format, it would require a new format to raise the limit.

There is a warning for this "WARNING: texture name '{}' exceeds maximum length {} and will be truncated\n" but maybe it's not printing, I'll double check.

Paril commented 7 months ago

Yeah unfortunately this isn't fixable without a secondary BSPX lump or something, and even then you'd still need modified engine support.

If you make an alternate BSP38-based format with longer filenames we can potentially add support for it.

ericwa commented 7 months ago

The warning is working in alpha4, it prints near the end of the qbsp output in the EmitFaces section:

image

This is running on the q2_long_texture_name.map testmap like this: qbsp.exe -q2bsp -basedir .\q2_wal_metadata\ .\q2_long_texture_name.map