Decide the VS Code setup (extensions, LSP, tasks) and how the AI is given context (captured docs, CLAUDE.md conventions, type definitions) so it can write and check mod scripts well.
Part of #1
Blocked by: #3
## Question
Decide the VS Code setup (extensions, LSP, tasks) and how the AI is given context (captured docs, CLAUDE.md conventions, type definitions) so it can write and check mod scripts well.
Teal config:tlconfig.lua, all_def.tl and .vscode/ live at the repo root (not in mod/, so the game never loads them), based on the game's vscode-template. Committed as a template plus a gitignored local copy that holds this machine's install path (D:/SteamLibrary/steamapps/common/Transport Fever 3/).
Tooling: install the VS Code extension pdesaulniers.vscode-teal (sumneko.lua is already installed) and the Teal compiler tl, used for type-checking only (tl check), since whether the game compiles .tl itself is undocumented.
AI context:
bring the offline docs (docs/reference/ from research/mod-tooling) onto main;
add a "Modding" section to CLAUDE.md (Teal, the mod/ layout, how to run tl check, "read the offline docs before guessing an API");
give the AI read access to the install's api/tealdef and base/tealdef via additionalDirectories in .claude/settings.json; these are the authoritative API types.
Repo baseline: make an initial commit on main (CLAUDE.md, CONTEXT.md, docs/agents/), merge both research branches into it (unrelated histories). Pushing main is left to the human.
Applying all of this is the follow-up task ticket "Apply the VS Code and AI workflow setup".
## Resolution
**Editor and AI workflow, decided:**
- **Teal config:** `tlconfig.lua`, `all_def.tl` and `.vscode/` live at the repo root (not in `mod/`, so the game never loads them), based on the game's `vscode-template`. Committed as a template plus a gitignored local copy that holds this machine's install path (`D:/SteamLibrary/steamapps/common/Transport Fever 3/`).
- **Tooling:** install the VS Code extension `pdesaulniers.vscode-teal` (`sumneko.lua` is already installed) and the Teal compiler `tl`, used for type-checking only (`tl check`), since whether the game compiles `.tl` itself is undocumented.
- **AI context:**
- bring the offline docs (`docs/reference/` from `research/mod-tooling`) onto `main`;
- add a "Modding" section to `CLAUDE.md` (Teal, the `mod/` layout, how to run `tl check`, "read the offline docs before guessing an API");
- give the AI read access to the install's `api/tealdef` and `base/tealdef` via `additionalDirectories` in `.claude/settings.json`; these are the authoritative API types.
- **Repo baseline:** make an initial commit on `main` (`CLAUDE.md`, `CONTEXT.md`, `docs/agents/`), merge both research branches into it (unrelated histories). Pushing `main` is left to the human.
- Applying all of this is the follow-up task ticket "Apply the VS Code and AI workflow setup".
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.
Part of #1
Blocked by: #3
Question
Decide the VS Code setup (extensions, LSP, tasks) and how the AI is given context (captured docs, CLAUDE.md conventions, type definitions) so it can write and check mod scripts well.
haylan referenced this issue2026-10-04 19:56:18 +00:00
Resolution
Editor and AI workflow, decided:
tlconfig.lua,all_def.tland.vscode/live at the repo root (not inmod/, so the game never loads them), based on the game'svscode-template. Committed as a template plus a gitignored local copy that holds this machine's install path (D:/SteamLibrary/steamapps/common/Transport Fever 3/).pdesaulniers.vscode-teal(sumneko.luais already installed) and the Teal compilertl, used for type-checking only (tl check), since whether the game compiles.tlitself is undocumented.docs/reference/fromresearch/mod-tooling) ontomain;CLAUDE.md(Teal, themod/layout, how to runtl check, "read the offline docs before guessing an API");api/tealdefandbase/tealdefviaadditionalDirectoriesin.claude/settings.json; these are the authoritative API types.main(CLAUDE.md,CONTEXT.md,docs/agents/), merge both research branches into it (unrelated histories). Pushingmainis left to the human.