Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,10 @@
# mods-core

**[简体中文](README.md) | [English](README_EN.md)**

> [!NOTE]
> 当前 mod 仍在开发测试期,可能存在功能不完整或不稳定的情况。商店与分发体系正在建设中。

SandboxWorld 的 mod 集合仓——源码、构建与**商店注册表源仓**。

## 结构
Expand Down
48 changes: 48 additions & 0 deletions README_EN.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,48 @@
# mods-core

**[简体中文](README.md) | [English](README_EN.md)**

> [!NOTE]
> Mods are still in active development and testing — features may be incomplete or unstable. The store and distribution infrastructure is under construction.

The SandboxWorld mod collection repository — source, builds, and the **store registry source repo**.

## Structure

```
<mod-id>/
mod.json # Store schema v2 (required: id/name/version/author/description/
# minEngine/category; optional: tags/dependencies/config)
icon.png # Store card icon
content/ # L1 declarative content / scripts/ (L2 scripting) / textures/ / i18n/
tools/gen-mod-registry.mjs # Registry generator (scan → registry.json)
```

## Store Architecture (three decoupled layers)

- **Source layer**: this repo (many mods, one repo). Giant mods (e.g. calamity)
live in dedicated `-port` repos and publish to the same registry schema;
- **Index layer**: `registry.json` (auto-regenerated by CI on merge, deployed to CDN);
- **Artifact layer**: `.swmod` builds distributed via GitHub Releases; the registry
records SHA-256 hashes.

## Building a mod

Inside the Open-Terraria repo: `node scripts/mod-cli.mjs build <path-to-mod>` → `.swmod`.

## Regenerating the registry locally

```bash
node tools/gen-mod-registry.mjs
```

## Conventions

- mod id: `[a-z0-9_]+` (store key domain, enforced by the validator);
- `minEngine`: minimum engine version (the in-game store filters by current version);
- a missing icon.png triggers a generator warning (non-blocking).

## License

Each mod's licensing is defined by its `mod.json` author field and PORTING.md (if present);
repo tooling is MIT.
Loading