StormLib API Reference

SFileAddListFile

Description

int WINAPI SFileAddListFile(
  HANDLE hMpq,                      // Handle to an open MPQ
  const char * szListFile           // Name of a listfile to add
);

StormLib maintains list of all files within the MPQ, as long as the MPQ is open. At the moment of MPQ opening, when the MPQ contains an internal list file, that listfile is parsed and all files in the listfile are checked against the hash table. Every file name that exists within the MPQ is added to the internal name list. This is done by calling SFileAddListFile internally.

SFileAddListFile adds an external listfile to the open MPQ. Note that the listfile is merely added to the memory structures of the open MPQ. On-disk structures of the MPQ are not changed. Use this function to specify an extra listfile to an opened MPQ, for example when there is no internal listfile, or if the internal listfile is not complete.

Parameters

hMpq
[in] Handle to an open MPQ.
szListFile
[in] Listfile name to add. If this parameter is NULL, the function adds the internal listfile from the MPQ, if present. Adding the same listfile multiple times has no effect.

Return Value

When the function succeeds, it returns ERROR_SUCCESS. On an error, the function returns error code.

Availability in Storm.dll

Available in Storm.dll No
Ordinal number in Storm.dll 1.00 N/A
Ordinal number in Storm.dll 1.09 N/A