Casasoft.IF.GBlorbLib
25.6.15
dotnet add package Casasoft.IF.GBlorbLib --version 25.6.15
NuGet\Install-Package Casasoft.IF.GBlorbLib -Version 25.6.15
<PackageReference Include="Casasoft.IF.GBlorbLib" Version="25.6.15" />
<PackageVersion Include="Casasoft.IF.GBlorbLib" Version="25.6.15" />
<PackageReference Include="Casasoft.IF.GBlorbLib" />
paket add Casasoft.IF.GBlorbLib --version 25.6.15
#r "nuget: Casasoft.IF.GBlorbLib, 25.6.15"
#:package Casasoft.IF.GBlorbLib@25.6.15
#addin nuget:?package=Casasoft.IF.GBlorbLib&version=25.6.15
#tool nuget:?package=Casasoft.IF.GBlorbLib&version=25.6.15
GBlorbLib
GBlorbLib is a .NET library for working with the GBlorb file format,
which is used to package resources for interactive fiction (IF) games.
It provides functionality to read, manipulate, and write GBlorb files,
including handling headers, resource indices, and chunks.
Features
- Parse GBlorb files to extract headers, resource indices, and chunks.
- Export individual chunks to files.
- Add or update optional text chunks (e.g., author, copyright, annotations).
- Write modified GBlorb files back to disk.
- Generate resource maps required by the Quixe interpreter.
Installation
To use GBlorbLib in your project, add a reference to the library. If using Visual Studio, you can include the NuGet package.
Usage
Reading a GBlorb File
using Casasoft.IF.GBlorbLib;
// Load a GBlorb file
GBlorb blorb = new("path/to/file.gblorb");
// Access header, resource index, and chunks
Console.WriteLine(blorb.Header);
Console.WriteLine(blorb.ResourceIndex);
foreach (var chunk in blorb.Chunks) { Console.WriteLine(chunk); }
Exporting a Chunk
// Export all chunks to a specified directory
blorb.Export("path/to/export/directory");
Adding/Updating Optional Text Chunks
// Add or update optional text chunks
blorb.AddUpdateOptionalTextChunk("AUTH", "Author Name");
blorb.AddUpdateOptionalTextChunk("(c) ", "2025 Author Copyright");
blorb.AddUpdateOptionalTextChunk("ANNO", "Annotations or remarks");
Writing a Modified GBlorb File
// Save changes to a new GBlorb file
blorb.Write("path/to/output.gblorb");
Generating a Resource Map for Quixe
ExtractDir = $"{ProjectName}.materials/Release";
file = $"{ExtractDir}/{Path.GetFileName(ProjectName)}.gblorb";
GBlorb blorb = new(file);
Blorb.ExportResourceMap(ExtractDir);
Online documentation
For detailed documentation, including API references, visit the GBlorbLib documentation site.
Dependencies
- .NET 8
- Mono.Options: Used for command-line option parsing in related tools.
- IronSoftware.System.Drawing: Used for image processing.
Contributing
Contributions are welcome! Feel free to submit issues or pull requests on the GitHub repository.
License
This project is licensed under the GNU Affero General Public License v3.0.
See the LICENSE file for details.
Acknowledgments
- Developed by Roberto Ceccarelli - Casasoft.
- Based on the Blorb Specification.
Product | Versions Compatible and additional computed target framework versions. |
---|---|
.NET | net8.0 is compatible. 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. net9.0 was computed. net9.0-android was computed. net9.0-browser was computed. net9.0-ios was computed. net9.0-maccatalyst was computed. net9.0-macos was computed. net9.0-tvos was computed. net9.0-windows was computed. net10.0 was computed. net10.0-android was computed. net10.0-browser was computed. net10.0-ios was computed. net10.0-maccatalyst was computed. net10.0-macos was computed. net10.0-tvos was computed. net10.0-windows was computed. |
-
net8.0
- IronSoftware.System.Drawing (>= 2025.6.2)
NuGet packages
This package is not used by any NuGet packages.
GitHub repositories
This package is not used by any popular GitHub repositories.