contentpack

package
v0.4.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 30, 2026 License: MIT Imports: 7 Imported by: 0

Documentation

Overview

Package contentpack assembles a kit/content Pack from a directory of UE5-exported files: NPC-template DataTables, animation montage timelines, baked navmeshes, and static-collision meshes.

The pack is the ship-cadence catalog and geometry surface — what kinds of NPCs exist (mesh refs, capsule sizes, AI archetype tags), how level collision and navmesh look. It does NOT contain spawn placements or runtime entity state — those live elsewhere (the spawn service, §81).

Build pipeline:

UE5 editor  →  UnrealForgeExport (§71)  →  staging dir  →  Builder.Build()
                                                            ↳ writes pack.json + assets
                                                              into a kit/content folder

Index

Constants

View Source
const (
	TypeNPCTemplates = "npc-templates"
	TypeMontage      = "montage"
	TypeNavMesh      = "navmesh"
	TypeCollision    = "collision"
)

Entry types used inside the assembled pack. Match the strings the runtime loader expects when fetching by type.

Variables

View Source
var (
	ErrNoInputs       = errors.New("contentpack: input directory has no recognised exports")
	ErrInvalidConfig  = errors.New("contentpack: invalid Config")
	ErrCrossRefBroken = errors.New("contentpack: cross-reference between entries broken")
)

Errors surfaced by the builder.

Functions

This section is empty.

Types

type Builder

type Builder struct {
	// contains filtered or unexported fields
}

Builder assembles a pack from a staging dir.

func New

func New(cfg Config) (*Builder, error)

New constructs a Builder.

func (*Builder) Build

func (b *Builder) Build() (content.Manifest, error)

Build walks InputDir for known export shapes and writes the assembled pack to OutputDir. Returns the resulting Manifest.

Layout expected under InputDir (any subset can be present):

npc-templates.json   — DataTable export consumed by §60.
montages/*.json      — per-montage exports consumed by §63.
navmesh.fnav         — single navmesh exported by §64.
collision.fcol       — level collision exported by §65.

type Config

type Config struct {
	PackID    content.PackID
	Version   content.Version
	InputDir  string // staging directory produced by UnrealForgeExport (§71)
	OutputDir string // target directory for the kit/content pack
}

Config configures a Builder.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL