The TTS extension can sync scripts between TTS and VSCode, but it requires specific setup:
- Tabletop Simulator must be running
- Must have a saved game in TTS (scripts are saved with games)
- Extension needs to connect to TTS's scripting editor
1. Load your script into TTS first:
- Open TTS
- Objects → Scripting → Global
- Paste
gyrinx2tts.luacontent - Click "Save & Play"
- Save the game: Games → Save & Apply
2. Get scripts from TTS to VSCode:
- In VSCode:
Ctrl+Shift+P - Type: "Tabletop Simulator Lua: Get Lua Scripts"
- Select your save game
- Extension creates files in workspace
3. Now you can edit and sync:
- Edit
Global.-1.ttslua(or similar) in VSCode Ctrl+Shift+P→ "Tabletop Simulator Lua: Save and Play"- Script uploads to TTS and reloads
TTS plugin expects files named like:
Global.-1.ttslua- Global scriptObjectName.guid.ttslua- Object scripts
Your gyrinx2tts.lua:
- ✅ Is a standalone development file
- ❌ Doesn't have TTS file naming
- ❌ Isn't linked to a TTS save game
- ✅ Works perfectly for development/testing
For your use case (single script development):
✅ Keep doing:
- Develop in
gyrinx2tts.lua - Test with
lua tests/test_tts_script.lua - Manually copy to TTS when ready
❌ Don't need plugin sync because:
- Single file is simpler
- Local testing is faster
- Manual copy is quick enough
- No complex multi-object scripts
Use "Get/Save Scripts" when:
- Multiple objects with different scripts
- Frequently switching between TTS and VSCode
- Working on an existing complex mod
- Collaborating with others on TTS mods
┌─────────────┐
│ VSCode │ 1. Edit gyrinx2tts.lua
│ │ 2. Test: lua tests/test_tts_script.lua
└──────┬──────┘
│
│ Ctrl+A, Ctrl+C
▼
┌─────────────┐
│ TTS │ 3. Paste into Global script
│ │ 4. Save & Play
└─────────────┘
┌─────────────┐
│ TTS │ 1. Initial: Save game with script
└──────┬──────┘
│
│ Get Lua Scripts
▼
┌─────────────┐
│ VSCode │ 2. Edit Global.-1.ttslua
│ │ 3. Save and Play (uploads)
└──────┬──────┘
│
│ Auto-reload
▼
┌─────────────┐
│ TTS │ 4. Script updated in game
└─────────────┘
"Get Lua Scripts" does nothing:
- Is TTS running?
- Is scripting editor open? (Press
`) - Is a game loaded/saved?
- Try: Save current game in TTS first
"Save and Play" fails:
- File must be named
Global.-1.ttsluaor similar - TTS must be running
- May need to "Get Scripts" first to establish connection
Press Ctrl+Shift+P and type "Tabletop" to see all available commands:
- Tabletop Simulator Lua: Get Lua Scripts
- Tabletop Simulator Lua: Save and Play
- Tabletop Simulator Lua: Create TTS Lua File
- Tabletop Simulator Lua: Execute Lua Code
Your current workflow is fine! The plugin's sync features are optional convenience features for complex mods. For single-script development:
Your workflow is actually better because:
- ✅ Local testing is instant
- ✅ Full Lua error messages in terminal
- ✅ No TTS connection required during development
- ✅ Simple file structure
- ✅ Easy version control
Only switch to plugin sync if you need rapid TTS iteration.