是控制台程序,需要在 DOS 模式下加参数运行。以下是使用说明,抱歉我没有时间翻译。
# v3.0.8 Copyright 2004 by Electronic Arts Inc.
# This program will create a resource data file using a script
# Usage: MakePack Infile
# Switches : [-Z] = Do not save the .h file EVER!, [-V] Verbose output
# [-M] create a manifest file (outfile.csv)
# [-L] Dump a file list to "FileList.txt"
# [-S] Suppress output, useful for debugging input scripts
# [-X *.mp3] Extract file(s) with a wildcard
# Script commands are as follows
// Script file for creating the pack file for Medal of Honor: Pacific Assault
//
// Copyright 2004, Electronic Arts Inc.
//
// For filename operands, quotes are optional, but recommended.
// Spaces are accepted inside quotes, but discouraged.
//
// Environment variables are invoked by using the form %PATH% where
// the word PATH is replaced with the variable to be used.
//
// Comments are C++ double slash style.
//
// Command list:
// outputname
// compress
// basedirectory
// add
// remove
// addrecursive
// removerecursive
// pack
// dontpack
//
/////////////////
//
// outputname: specify the name of the output file. This command should occur
// only once and near the beginning of the script. If found a second time,
// it will trigger an error.
//
// Examples:
// outputname "Outputfilename.pak"
// outputname "z:\data\foo\data.pak"
//
/////////////////
//
// compress: Specify the compression algorithms to use on the data if compression is allowed.
// The dontpack command will take precidence on a file, but if compression is allowed, attempt
// to use these codecs.
//
// Codecs supported: Use a maximum of three.
// lzss A custom lzss codec, not compatible with the one that's out on the 'net, extremely fast decoding
// rle A simple run length encoder, extremely fast decoding
// inflate ZLib compression, slow decoding.
// Not support, but planned
// refpack A custom EA compression, better than rle, but not as good as inflate, fast decoding.
// lz77 LZW. Decent compression, but not as good as inflate
// huffman Straight huffman compression. Moderate decoding speed, and great for high concentrations of few numbers
// lzari Great compression, sucks at decoding time
//
// Example:
// compress none // Completely shut off ALL compression
// compress inflate,lzss,rle // Use these three codecs
// compress lzss // Use lzss only.
//
/////////////////
//
// basedirectory: Specify the base directory for where all subsequent file operations
// will work from. The default is the same directory that the script file itself
// exists. This command will allow the script file to be placed anywhere on the
// hard drive and import data from any other directory.
//
// Note: This should be a fully qualified pathname with a drive letter.
//
// Examples:
// basedirectory "Z:\mohpa\data\demo"
// basedirectory "Z:\mohpa\data\release"
//
/////////////////
//
// include: Filename to include into the pack file. Wildcards
// are acceptable.
//
// Examples:
// add "*.tga" // Include tga files in this directory only
// add "data\*.*" // Include all files in the directory "data"
//
/////////////////
//
// addrecursive: Filename to include into the pack file. Wildcards
// are acceptable. If any directories are found, they will be recursively
// searched and all their matching contents will be included
//
// Examples:
// addrecursive "*.tga" // Include all tga files
// addrecursive "data\*.*" // Include all files in the data folder
// addrecursive "*.*" // Include everything
//
/////////////////
//
// remove: Filename to explictly exclude from the pack file. Wildcards
// are acceptable.
//
// Examples:
// remove "*.bmp" // Remove all bmp files from the root folder
// remove "temp\*.*" // Remove all files in the temp folder
//
/////////////////
//
// removerecursive: Filename to explictly exclude from the pack file. Wildcards
// are acceptable. If any directories are found, they will be recursively
// searched and all their matching contents will be removed.
//
// Examples:
// removerecursive "*.gif" // Exclude all gif files
// removerecursive "logfile\*.*" // Exclude all files in the logfile folder
// removerecursive "*.*" // Remove everything (Why? But then, you can do it if you want to)
//
/////////////////
//
// pack: Filenames that are allowed to be compressed. The default is no compression.
//
// Examples:
// pack "*.*" // Pack everything
// pack "*.tga" // Pack tga files
// pack "data\*.*" // Pack everything in the data folder
//
/////////////////
//
// dontpack: Filenames that are explictily barred from being compressed. Useful
// in hinting that movie and compress audio files do not need to be compressed
// a second time.
//
// Examples:
// dontpack "*.mp3" // Don't pack mp3s
// dontpack "*.avi" // Don't pack movie files.
//
/////////////////
//
// Preflight
compress inflate,lzss,rle // Enable these codecs
basedirectory "Z:\PackFileTest\demo" // Working data folder
cachename "DemoCache" // Save the cache here
outputname "pak0.rez" // Output file
// Grab the files
addrecursive "*.*" // Grab everything
removerecursive "*.tmp" // Don't add the temp files (Test)
remove "settings.ini" // Don't include this into the pack file
//removerecursive "*.mp3" // This is to simulate the original pakfile
//removerecursive "*.mp3.mp3"
// Twiddle compression
pack "*.*" // This is the default
dontpack "*.bik" // Yeah, right
dontpack "*.mp3" // Nope, no need to waste my time on this
//dontpack "*.avi"
//dontpack "*.mov"
// All done!