MpqViewer

The MpqViewer is a tool to view and extract files from *.mpq archive files used by Blizzard. It's written in C# so you have to install Microsoft .NET Framework 2.0 or higher and it utilizes the C# MpqLibrary published by "The Hungry Programmers" (http://www.hungry.com/).

Check the changes section for updates.

Functions:

  • extract any file from any *.mpq archive

  • view files directly from the archive, without the need to export
  • convert *.blp to *.png images by default on extraction
  • filtering of the displayed file list
  • scripting through lua (http://www.lua.org) and the luanet api (http://www.lua.inf.puc-rio.br/luanet/)
  • How to use:

    • Load a *.mpq file using the "File" -> "Open File..." dialog

  • double click on a file to view it (*.blp files are displayed as image, *.wav files are displayed in a mini sound player, all other files are shown as text files)
  • select one or multiple files from the file list
  • export the selected files using the "Export" -> "Save File..." dialog
  • Options:

    • "Options" -> "Switch to LuaMode" will open the lua console (see 'Scripting')

  • "Options" -> "Keep Archive Structure" will, when it's checked, export the folder structure from the archive to the selected export folder
    e.g. you export the file "DBFilesClient\spell.dbc" to "MyExportFolder" it will create the folder "DBFilesClient" and put the "spell.dbc" in there, so you can find it under "MyExportFolder\DBFilesClient\spell.dbc", by default this behavior is disabled
  • "Options" -> "Use RegexFilter" will enable Regular Expressions in the filter field (see 'Filtering')
  • "Options" -> "Use RawExport" will enable export of files without converting them, this only has an effect on *.blp files, which are converted to *.png files on export
  • Filtering:

    • you may filter the file list of the opened *.mpq file to find a certain file or type of file much faster
    • there are two filters implemented: the "default" filter works like the file search on Windows, the second is the "regex" filter, it allows you to filter the list using Regular Expressions (see http://msdn2.microsoft.com/en-us/library/2k3te2cs(VS.90).aspx for details about Regex and the .NET Framework)
    • "default" filter example: "FrameXML" will display only files starting with this string, in this example this are all UI files; "*.blp" will display only files ending with the string ".blp" (image files), so you see it's a quiet simple and basic filter...

    Scripting:

    • switch to LuaMode through "Options" -> "Switch to LuaMode"
    • load a *.lua script by clicking on "File" -> "Open LuaScript..."
    • you may set a workspace through "File" -> "Open Workspace...", the default is "C:\"
    • you may use any .NET class because we use the luanet api (see the documentation at http://www.lua.inf.puc-rio.br/luanet/)
    • you can write to the console using print(...) (or interop.print(str) with only one param), clear the console calling interop.clear() and to keep the MpqViewer GUI unblocked when running long operations you may call interop.pulse()
    • the mpq functions avaiable are: mpq.OpenFile(string srcFile) to get the Stream of a file in the currently opened archive, mpq.ExportFile(string srcFile, string dstFile) to export a file, mpq.FilterFileList(string FilterPattern) to get a list of files using the "default" filter and mpq.RegexFilterFileList(string FilterPattern) to get a list of files using the "regex" filter
    • for an example look at the ExtractAndBuildMinimap.lua, on execution it will build the Minimap combining it from the hundreds of small pieces found in common.mpq

    Changelog:

    1.5.2:

    • fixed compatibility issue with Microsoft .NET Framework so you can use framework version 2.0 again instead of 3.5
    • when opening multiple *.mpq files they are sorted by date of last change so you get always the most recent file version out of the archives

    1.5.1:

    • added support for DXT5 compressed *.blp images
    • added boolean return value to mpq.ExportFile(...) wether the export succeded or not

    1.5:

    • added preview for files

    1.0:

    • initial release

    You must login to post a comment. Don't have an account? Register to get one!

    Facts

    Date created
    29 Sep 2008
    Categories
    Last update
    27 Apr 2009
    Development stage
    Release
    Language
    • enUS
    License
    MIT License
    Curse link
    MpqViewer
    Recent file

    Authors