Texture tool for Quake 1 wads ============================= BACKGROUND There are a lot of utilities for Q1 that can merge texture wads and eliminate duplicate textures in the process. This is very convenient, but wads always get bigger with this additive method. DupWad is a Q1 texture tool that instead can shrink wads by eliminating textures that already exist in other wads, so called reference wads. DupWad handles both Quake 1 native wad2 format and HalfLife's wad3 format transparently, i.e. the processed wad maintains its format and any reference wad can have any format. Processed wad3 files will be padded with the Q1 palette for each texture entry for maximum compatibility. DupWad only uses the texture names when checking for duplicates, neither texture size nor texture contents will be considered. Palette entries will always be considered unique and kept in the processed wad. When done, the processed wad will only contain unique textures that don't exist in any of the reference wads. If there are no unique textures, the wad will be deleted. ================================================================================================== QUICK START To delete textures in a wad named "wad.wad" that already exist in another wad named "refwad.wad", just enter the command "dupwad refwad wad". Note that the processed wad will be unchanged, resized (shrunk) or even deleted, depending on if its textures are correspondingly all unique, some unique or all duplicate compared to the reference wad. ================================================================================================== COMMAND SYNTAX The full command syntax is : dupwad [options] refwad1 [refwad2 refwad3 ...] wad Options : -quiet : Display only file summary The standard wad file extension ".wad" is automatically added to the supplied filename(s) if you don't specify it explicitly. You can enter multiple reference wads but NO wildcards (e.g. abc*). Reference wads will never be changed in any way. If a reference wad name begins with a '@' (e.g. "@myscript.txt"), it indicates a script file (standard text file) that should contain the actual reference wads, one for each line. Explicit reference wads and script files may be mixed in any combination on the command line but scripts cannot be nested, i.e. one script file cannot contain script file names. Duplicate reference wads will automatically be skipped and the maximum # of reference wads is limited to 1024. A brief description can be obtained by running DupWad without any parameters. ================================================================================================== NOTES DupWad may (and probably will) CHANGE or even DELETE the processed wad (the last wad on the command line), so use with caution. However, since the utility only deletes textures with duplicate names, the deleted contents should in theory also exist in one or more of the reference wads. There is no check for texture size nor actual texture contents. During processing, DupWad will print out more or less information depending on the selected options. Default it will print # found textures in each wad, how many unique and duplicate textures in the processed wad and finally the action performed on the output file. When using the "-quiet" option, only the final file summary will be printed. DupWad can always be aborted by hitting Ctrl-Break, but then a temporary file with the same name as the processed wad in the same directory but with extension ".wa0" might be left. You can safely delete this file or it will be deleted next time DupWad is run on the same wad. ================================================================================================== CHANGES The changes are as follows : DupWad 1.00 (Mar 16 2004) 1. First version ==================================================================================================