WadParser 1.1.1

There is a newer version of this package available.
See the version list below for details.
dotnet add package WadParser --version 1.1.1                
NuGet\Install-Package WadParser -Version 1.1.1                
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="WadParser" Version="1.1.1" />                
For projects that support PackageReference, copy this XML node into the project file to reference the package.
paket add WadParser --version 1.1.1                
#r "nuget: WadParser, 1.1.1"                
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
// Install WadParser as a Cake Addin
#addin nuget:?package=WadParser&version=1.1.1

// Install WadParser as a Cake Tool
#tool nuget:?package=WadParser&version=1.1.1                

WadParser-dotnet

A C# .NET Core (2.1) helper library to parse WAD files and extract lumps contained in Doom, Quake and Half-life WAD files.

Based on:

Supported Formats

  • IWAD/PWAD
    • Doom, Heretic, Hexen and Strife
  • WAD2
    • Quake
  • WAD3
    • Half-Life, Opposing Force, Blue Shift

Usage

using System;
using nz.doom.WadParser;

namespace WadReader
{
    class Program
    {
        static int Main(string[] args)
        {
            if(args == null || args.Length != 1)
            {
                Console.Error.WriteLine("WAD file required");
                return 2;
            }

            Wad wad = WadParser.Parse(args[0]);

            foreach(var lump in wad.Lumps)
            {
                Console.WriteLine(lump.Name);
            }

            return 0;
        }
    }
}
using System;
using nz.doom.WadParser;

namespace WadReader
{
    class Program
    {
        static int Main(string[] args)
        {
            if(args == null || args.Length != 1)
            {
                Console.Error.WriteLine("WAD file required");
                return 2;
            }

            Wad wad = WadParser.Parse(args[0], false);

            Lump endoomLump = wad.GetLumpByName("ENDOOM");
            
            if( endoomLump != null )
            {
                WadParser.ReadBytesIntoLump(args[0], endoomLump);
                Console.WriteLine($"{endoomLump.Name} is {endoomLump.Bytes.Length} bytes long");
            }
            return 0;
        }
    }
}

See also

Also available for Java https://github.com/elephantflea/WadParser

Product Compatible and additional computed target framework versions.
.NET net5.0 was computed.  net5.0-windows was computed.  net6.0 was computed.  net6.0-android was computed.  net6.0-ios was computed.  net6.0-maccatalyst was computed.  net6.0-macos was computed.  net6.0-tvos was computed.  net6.0-windows was computed.  net7.0 was computed.  net7.0-android was computed.  net7.0-ios was computed.  net7.0-maccatalyst was computed.  net7.0-macos was computed.  net7.0-tvos was computed.  net7.0-windows was computed.  net8.0 was computed.  net8.0-android was computed.  net8.0-browser was computed.  net8.0-ios was computed.  net8.0-maccatalyst was computed.  net8.0-macos was computed.  net8.0-tvos was computed.  net8.0-windows was computed. 
.NET Core netcoreapp2.1 is compatible.  netcoreapp2.2 was computed.  netcoreapp3.0 was computed.  netcoreapp3.1 was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • .NETCoreApp 2.1

    • No dependencies.

NuGet packages (1)

Showing the top 1 NuGet packages that depend on WadParser:

Package Downloads
IS4.SFI.Formats.GameArchives

Provides support for old games archive formats.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last updated
1.1.2 847 8/17/2019
1.1.1 491 7/13/2019
1.1.0 493 7/6/2019
1.0.1 515 7/4/2019

Bug fix in lump names when run on non-Windows machines