From cee344c7c1f7778fdc2fce0459e0ffde8baa229a Mon Sep 17 00:00:00 2001 From: veclavtalica Date: Sun, 16 Feb 2025 01:31:42 +0300 Subject: [PATCH] /docs/wiki/packaging.html --- docs/wiki/index.html | 6 ++++++ docs/wiki/packaging.html | 39 +++++++++++++++++++++++++++++++++++++++ 2 files changed, 45 insertions(+) create mode 100644 docs/wiki/packaging.html diff --git a/docs/wiki/index.html b/docs/wiki/index.html index 44ff5d0..0d8bc04 100644 --- a/docs/wiki/index.html +++ b/docs/wiki/index.html @@ -13,6 +13,8 @@ T2. Input System + T3. Packaging +

T1. About Townengine

@@ -24,6 +26,10 @@

T2.1 Design

T2.2 API

+

T3. Packaging

+
+

T3.1 Overview

+

G1. Making 2.5D Shooters

diff --git a/docs/wiki/packaging.html b/docs/wiki/packaging.html new file mode 100644 index 0000000..0560293 --- /dev/null +++ b/docs/wiki/packaging.html @@ -0,0 +1,39 @@ + + + + Townengine Wiki : Packaging + + + +

T3. Packaging{twn}

+ Go back +

T3.1 Overview +

+

Assets are distributed by packs, which can come in either archived or, for development purposes, folder form. + {twn} games are sandboxes and operate only on supplied content. + +

Archives are limited to zip format, with .btw file extension. + +

One pack by the name of 'data' is always assumed to be present alongside executable, + whether in folder /data/ or /data.btw archive, where precedence is taking over for /data/ folder variant. + +

Root /data/ could be used to point to other packs in its /packs/data.toml file. + It results in a union filesystem, where directory structures are overlaid on top of each other. + +

Packs which are loaded first have precedence over later ones, preserving their contents. + For example, if /assets/foo exists in root /data/, and another /assets/foo is found elsewhere, + only the root /data/ version will be available. + +

+# Example of data.toml file
+# `deps` array of tables is loaded sequentially, where dependencies of dependencies are processed first before continuing.
+
+[[deps]]
+source = "../../common-data" # where does it come from
+name = "common-data"         # should be a globally unique identifier
+ +

Compilation utility might later be available to combine packs for easier distribution. + +

+ +