@team-antioch/sc2-adjutant-host-macos 0.0.0-stage → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/README.md +55 -2
- package/dist/.built +0 -0
- package/dist/capture-tour.js +881 -0
- package/dist/games.js +49 -0
- package/dist/index.js +249 -0
- package/dist/refresh.js +72 -0
- package/dist/whiteoutflakes.js +46 -0
- package/docs/macos-host.md +136 -0
- package/package.json +33 -4
- package/sc2-adjutant-plugin.json +8 -0
- package/scripts/build-whiteoutflakes.sh +82 -0
package/LICENSE
ADDED
|
@@ -0,0 +1,21 @@
|
|
|
1
|
+
MIT License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026 TeamAntioch
|
|
4
|
+
|
|
5
|
+
Permission is hereby granted, free of charge, to any person obtaining a copy
|
|
6
|
+
of this software and associated documentation files (the "Software"), to deal
|
|
7
|
+
in the Software without restriction, including without limitation the rights
|
|
8
|
+
to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
|
9
|
+
copies of the Software, and to permit persons to whom the Software is
|
|
10
|
+
furnished to do so, subject to the following conditions:
|
|
11
|
+
|
|
12
|
+
The above copyright notice and this permission notice shall be included in all
|
|
13
|
+
copies or substantial portions of the Software.
|
|
14
|
+
|
|
15
|
+
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
|
16
|
+
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
|
17
|
+
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
|
18
|
+
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
|
19
|
+
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
|
20
|
+
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
21
|
+
SOFTWARE.
|
package/README.md
CHANGED
|
@@ -1,3 +1,56 @@
|
|
|
1
|
-
#
|
|
1
|
+
# @team-antioch/sc2-adjutant-host-macos
|
|
2
2
|
|
|
3
|
-
|
|
3
|
+
The macOS **Host Adapter** for [sc2-adjutant](https://github.com/TeamAntioch/sc2-adjutant). It is the Plugin that does what a Mac can do with StarCraft II, so the co-design tools can open, test and look at your maps for you. Without it, those tools hand you the steps to follow in the Editor yourself.
|
|
4
|
+
|
|
5
|
+
## What it does
|
|
6
|
+
|
|
7
|
+
| Capability | How |
|
|
8
|
+
|---|---|
|
|
9
|
+
| `editor.open`, `editor.checkClosed`, `editor.refresh` | Opens a Map Package in the Galaxy Editor, tells whether the Editor has it open, and closes a clean copy so a compile can rewrite it. It never saves or discards your changes. |
|
|
10
|
+
| `editor.testDocument`, `editor.save` | Runs File > Test Document, and saves a throwaway copy of a map, through the Editor's menus. |
|
|
11
|
+
| `game.banksDir` | The folder the game keeps its banks in; test_mission snapshots it around a test game. |
|
|
12
|
+
| `editor.captureTour`, `editor.closeCaptureCopies`, `game.running` | Plays a capture map and screenshots each camera stop, then closes it unsaved. Captures run one at a time through the Editor Broker. A capture quits only the game it started. |
|
|
13
|
+
| `game.logsFolder` | `~/Library/Application Support/Blizzard/StarCraft II/GameLogs`. |
|
|
14
|
+
| `game.list`, `game.quit` | Lists the running games with their start times, and quits one recorded game gracefully (Cmd+Option+Q, then Yes), killing it only after a timeout. |
|
|
15
|
+
| `screen.capture` | Captures the game's window, else the Editor's. |
|
|
16
|
+
| `tts.speak` | Speaks placeholder voice lines with macOS's `say`. |
|
|
17
|
+
| `model.render`, `model.rendererKey`, `model.export`, `model.exportGltf` | Renders game and mod models to turntable thumbnails, and exports them as `.m3` or glTF, with the WhiteoutFlakes model viewer. |
|
|
18
|
+
|
|
19
|
+
It has no `game.launch`, because the Mac game starts only through the Editor's Test Document.
|
|
20
|
+
|
|
21
|
+
## Install
|
|
22
|
+
|
|
23
|
+
`npx @team-antioch/sc2-adjutant init` installs it in a new Workspace on a Mac, and names it in your machine config. To add it to an existing Workspace:
|
|
24
|
+
|
|
25
|
+
```sh
|
|
26
|
+
npm install @team-antioch/sc2-adjutant-host-macos
|
|
27
|
+
```
|
|
28
|
+
|
|
29
|
+
Then name it in your machine config, `~/.config/sc2-adjutant/machine.json`. It loads only when it's named:
|
|
30
|
+
|
|
31
|
+
```json
|
|
32
|
+
{
|
|
33
|
+
"hostAdapter": "bundled:host-macos",
|
|
34
|
+
"editorPath": "/Applications/StarCraft II Editor (Fixed).app",
|
|
35
|
+
"cacheDir": "~/Library/Caches/sc2-adjutant",
|
|
36
|
+
"modelViewerPath": "~/.cache/sc2-adjutant/whiteoutflakes/stage/WhiteoutFlakes.app/Contents/MacOS/WhiteoutFlakes"
|
|
37
|
+
}
|
|
38
|
+
```
|
|
39
|
+
|
|
40
|
+
It needs sc2-adjutant core (`@team-antioch/sc2-adjutant`) installed beside it, which is a peer dependency.
|
|
41
|
+
|
|
42
|
+
## What it needs
|
|
43
|
+
|
|
44
|
+
- **`editorPath`**: the Galaxy Editor app to launch. On Apple Silicon, the native Editor runs only through a community fix that ships as a launcher app ([the native Editor fix](https://github.com/TeamAntioch/sc2-adjutant/blob/main/packages/plugin-host-macos/docs/macos-host.md#the-native-editor-fix)). Point `editorPath` at that launcher, since the bare Editor crashes at launch.
|
|
45
|
+
- **`cacheDir`**: a folder outside the Workspace for capture copies and the model viewer's working copies.
|
|
46
|
+
- **Accessibility and Screen Recording permission** for the app that runs the MCP server (your terminal, or Claude Code). The Editor is driven through its menus, and captures read the screen.
|
|
47
|
+
- **For models, `modelViewerPath`**: the WhiteoutFlakes viewer, which `scripts/build-whiteoutflakes.sh [dir]` builds. It needs Xcode, with its Metal toolchain, Homebrew, git, and the GitHub CLI (`gh`) signed in, which downloads the shader compiler. Re-running it skips the steps already done.
|
|
48
|
+
|
|
49
|
+
Every path comes from the machine config. Nothing about your machine is built in, so a capability that needs a missing setting fails with the setting to add. The rest of the machine config is in [core's README](https://github.com/TeamAntioch/sc2-adjutant/tree/main/packages/core#the-machine-config).
|
|
50
|
+
|
|
51
|
+
## More
|
|
52
|
+
|
|
53
|
+
- [`docs/macos-host.md`](https://github.com/TeamAntioch/sc2-adjutant/blob/main/packages/plugin-host-macos/docs/macos-host.md): the Editor and game behaviour this adapter relies on, and how to do each step by hand.
|
|
54
|
+
- [The plugin API](https://github.com/TeamAntioch/sc2-adjutant/blob/main/docs/plugin-api.md#host-adapter-kinds): what every Host Adapter capability takes and returns.
|
|
55
|
+
|
|
56
|
+
MIT licensed.
|
package/dist/.built
ADDED
|
File without changes
|