Skip to content
Front Matter Metadata

Front Matter Metadata

Front Matter is a YAML-formatted metadata block at the beginning of a file, used to define basic game information.

Syntax

---
key: value
key2: "string value"
---

# Game content starts here...

Starts and ends with ---, with YAML key-value pairs in between.

Supported Fields

Basic Information Fields

FieldTypeRequiredDescription
titleStringNoGame title
nameStringNoGame name (used for package filename)
authorStringNoAuthor name
versionStringNoVersion number, e.g., 1.0.0
descriptionStringNoGame description

Resource Path Fields

FieldTypeDefaultDescription
base_bg_pathStringassets/bg/Background image base path
base_sprite_pathStringassets/sprites/Sprite image base path
base_audio_pathStringassets/audio/Audio file base path

Runtime Configuration Fields

FieldTypeDefaultDescription
entry_sceneStringFirst sceneEntry scene ID
default_fontStringSystem defaultDefault font
default_font_sizeNumber24Default font size
default_text_speedNumber50Default text speed (chars/sec)

Complete Example

---
title: Mist Forest
name: mist_forest
author: NovaMark Team
version: 1.0.0
description: An adventure story about being lost and finding your way
entry_scene: scene_intro
base_bg_path: assets/backgrounds/
base_sprite_path: assets/characters/
base_audio_path: assets/sounds/
default_font: SourceHanSansCN-Regular.ttf
default_font_size: 28
default_text_speed: 60
---

#scene_intro "Prologue"

@bg forest_mist.png
> The morning mist shrouds the forest...

Single File vs Project Configuration

Single File Mode

When building a single .nvm file with nova-cli build game.nvm:

  • Front Matter metadata is read
  • If no Front Matter, the filename is used as the game name

Project Mode

When building a project with project.yaml:

  • project.yaml configuration takes priority over Front Matter
  • Front Matter resource path settings are preserved

Read Order

NovaMark determines game metadata in this order:

  1. project.yaml (project mode)
  2. Front Matter of the first .nvm file
  3. Default values
Last updated on