flockbay 0.10.49 → 0.10.52

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.
Files changed (74) hide show
  1. package/README.md +60 -60
  2. package/bin/flockbay-mcp.mjs +62 -62
  3. package/bin/flockbay.mjs +95 -95
  4. package/dist/{index-r3VTdgFI.cjs → index-IntvnrmZ.cjs} +71 -14
  5. package/dist/{index-D8AeVbvv.mjs → index-wkeSi0iC.mjs} +70 -13
  6. package/dist/index.cjs +2 -2
  7. package/dist/index.mjs +2 -2
  8. package/dist/lib.cjs +1 -1
  9. package/dist/lib.mjs +1 -1
  10. package/dist/{migratePlugin-CEvGPul8.mjs → migratePlugin-C71hAoc5.mjs} +12 -2
  11. package/dist/{migratePlugin-wFK-k3Wk.cjs → migratePlugin-D1XjjWFq.cjs} +12 -2
  12. package/dist/{runCodex-DuyuYqoB.cjs → runCodex-B7i_ICoQ.cjs} +34 -23
  13. package/dist/{runCodex-ZfUyhHF6.mjs → runCodex-BSx-hCu6.mjs} +34 -23
  14. package/dist/{runGemini-DBU1mMdp.mjs → runGemini-Dwyh7_WI.mjs} +2 -2
  15. package/dist/{runGemini-D7j5Y5TF.cjs → runGemini-gBKR3rdL.cjs} +2 -2
  16. package/dist/{types-DNr0xwSy.cjs → types-5z8UADAi.cjs} +224 -15
  17. package/dist/{types-BRJuZQj_.mjs → types-Bgzap7qR.mjs} +224 -16
  18. package/package.json +131 -131
  19. package/scripts/claude_local_launcher.cjs +72 -72
  20. package/scripts/claude_remote_launcher.cjs +15 -15
  21. package/scripts/claude_version_utils.cjs +445 -445
  22. package/scripts/ripgrep_launcher.cjs +32 -32
  23. package/scripts/run-with-root-env.mjs +37 -32
  24. package/scripts/session_hook_forwarder.cjs +49 -49
  25. package/scripts/test-codex-abort-history.mjs +77 -77
  26. package/scripts/unpack-tools.cjs +244 -244
  27. package/tools/licenses/difftastic-LICENSE +21 -21
  28. package/tools/licenses/ripgrep-LICENSE +3 -3
  29. package/tools/unreal-mcp/UPSTREAM_VERSION.md +8 -8
  30. package/tools/unreal-mcp/upstream/Docs/README.md +8 -8
  31. package/tools/unreal-mcp/upstream/Docs/Tools/README.md +6 -6
  32. package/tools/unreal-mcp/upstream/Docs/Tools/actor_tools.md +183 -183
  33. package/tools/unreal-mcp/upstream/Docs/Tools/blueprint_tools.md +268 -268
  34. package/tools/unreal-mcp/upstream/Docs/Tools/editor_tools.md +104 -104
  35. package/tools/unreal-mcp/upstream/Docs/Tools/node_tools.md +274 -274
  36. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Config/FilterPlugin.ini +8 -8
  37. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/FlockbayMCP.uplugin +36 -36
  38. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/FlockbayMCP.Build.cs +82 -82
  39. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPBlueprintCommands.cpp +1364 -1364
  40. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPBlueprintNodeCommands.cpp +1310 -1310
  41. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPCommandSchema.cpp +756 -756
  42. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPCommonUtils.cpp +1177 -1177
  43. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPEditorCommands.cpp +2618 -2618
  44. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPProjectCommands.cpp +71 -71
  45. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPUMGCommands.cpp +543 -543
  46. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/MCPServerRunnable.cpp +372 -372
  47. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/UnrealMCPBridge.cpp +457 -457
  48. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/UnrealMCPModule.cpp +21 -21
  49. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPBlueprintCommands.h +35 -35
  50. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPBlueprintNodeCommands.h +30 -30
  51. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPCommandSchema.h +41 -41
  52. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPCommonUtils.h +59 -59
  53. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPEditorCommands.h +61 -61
  54. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPProjectCommands.h +20 -20
  55. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPUMGCommands.h +82 -82
  56. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/MCPServerRunnable.h +33 -33
  57. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/UnrealMCPBridge.h +64 -64
  58. package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/UnrealMCPModule.h +22 -22
  59. package/tools/unreal-mcp/upstream/Python/README.md +39 -39
  60. package/tools/unreal-mcp/upstream/Python/pyproject.toml +22 -22
  61. package/tools/unreal-mcp/upstream/Python/scripts/actors/test_cube.py +202 -202
  62. package/tools/unreal-mcp/upstream/Python/scripts/blueprints/test_create_and_spawn_blueprints_with_different_components.py +496 -496
  63. package/tools/unreal-mcp/upstream/Python/scripts/blueprints/test_create_and_spawn_cube_blueprint.py +193 -193
  64. package/tools/unreal-mcp/upstream/Python/scripts/node/test_component_reference.py +266 -266
  65. package/tools/unreal-mcp/upstream/Python/scripts/node/test_create_bird_blueprint_with_input_and_camera.py +617 -617
  66. package/tools/unreal-mcp/upstream/Python/scripts/node/test_input_mapping.py +365 -365
  67. package/tools/unreal-mcp/upstream/Python/scripts/node/test_physics_variables.py +389 -389
  68. package/tools/unreal-mcp/upstream/Python/tools/blueprint_tools.py +419 -419
  69. package/tools/unreal-mcp/upstream/Python/tools/editor_tools.py +369 -369
  70. package/tools/unreal-mcp/upstream/Python/tools/node_tools.py +429 -429
  71. package/tools/unreal-mcp/upstream/Python/tools/project_tools.py +63 -63
  72. package/tools/unreal-mcp/upstream/Python/tools/umg_tools.py +332 -332
  73. package/tools/unreal-mcp/upstream/Python/unreal_mcp_server.py +398 -398
  74. package/tools/unreal-mcp/upstream/Python/uv.lock +521 -521
@@ -18,12 +18,12 @@ import { fileURLToPath } from 'url';
18
18
  import process$1 from 'node:process';
19
19
  import { platform } from 'os';
20
20
  import net from 'node:net';
21
- import { spawn as spawn$1 } from 'node:child_process';
21
+ import { spawn as spawn$1, execFileSync } from 'node:child_process';
22
22
  import { createServer } from 'http';
23
23
  import open$2 from 'open';
24
24
 
25
25
  var name = "flockbay";
26
- var version = "0.10.49";
26
+ var version = "0.10.52";
27
27
  var description = "Flockbay CLI (local agent + daemon)";
28
28
  var author = "Eduardo Orellana";
29
29
  var license = "UNLICENSED";
@@ -3248,6 +3248,9 @@ class ApiSessionClient extends EventEmitter {
3248
3248
  this.socket.on("connect", () => {
3249
3249
  logger.debug("[session] socket connected");
3250
3250
  this.rpcHandlerManager.onSocketConnect(this.socket);
3251
+ if (this.agentStateVersion <= 0) {
3252
+ this.updateAgentState((s) => ({ ...s || {} }));
3253
+ }
3251
3254
  this.flush();
3252
3255
  this.emit("connect");
3253
3256
  });
@@ -3463,6 +3466,105 @@ function isInstalledEngineRoot(engineRootRaw) {
3463
3466
  return false;
3464
3467
  }
3465
3468
 
3469
+ function findFilesNamedUnderDir$2(options) {
3470
+ const rootDir = options.rootDir;
3471
+ const filename = options.filename;
3472
+ const maxDepth = Math.max(0, Math.floor(options.maxDepth));
3473
+ const results = [];
3474
+ const visit = (dir, depth) => {
3475
+ if (depth > maxDepth) return;
3476
+ let entries = [];
3477
+ try {
3478
+ entries = fs__default.readdirSync(dir, { withFileTypes: true });
3479
+ } catch {
3480
+ return;
3481
+ }
3482
+ for (const entry of entries) {
3483
+ if (entry.name === ".DS_Store") continue;
3484
+ const full = path__default.join(dir, entry.name);
3485
+ if (entry.isDirectory()) {
3486
+ visit(full, depth + 1);
3487
+ continue;
3488
+ }
3489
+ if (entry.isFile() && entry.name === filename) results.push(full);
3490
+ }
3491
+ };
3492
+ visit(rootDir, 0);
3493
+ return results;
3494
+ }
3495
+ function readJsonIfPossible$2(filePath) {
3496
+ try {
3497
+ return JSON.parse(fs__default.readFileSync(filePath, "utf8"));
3498
+ } catch {
3499
+ return null;
3500
+ }
3501
+ }
3502
+ function isRespacedFlockbayMcpPlugin(upluginJson) {
3503
+ const friendlyName = typeof upluginJson?.FriendlyName === "string" ? upluginJson.FriendlyName : "";
3504
+ const createdBy = typeof upluginJson?.CreatedBy === "string" ? upluginJson.CreatedBy : "";
3505
+ return friendlyName === "Flockbay MCP" && createdBy === "Respaced Inc.";
3506
+ }
3507
+ function looksLikeLegacyBrokenEngineCopy(upluginJson) {
3508
+ const enabledByDefault = Boolean(upluginJson?.EnabledByDefault);
3509
+ const installed = Boolean(upluginJson?.Installed);
3510
+ const hasEngineVersion = typeof upluginJson?.EngineVersion === "string" && upluginJson.EngineVersion.length > 0;
3511
+ return enabledByDefault || installed || hasEngineVersion;
3512
+ }
3513
+ function quarantineLegacyEnginePlugins(engineRootRaw) {
3514
+ const engineRoot = (engineRootRaw || "").trim();
3515
+ if (!engineRoot) {
3516
+ return { ok: true, disabledUpluginPaths: [], ignoredUpluginPaths: [] };
3517
+ }
3518
+ const enginePluginsDir = path__default.join(engineRoot, "Engine", "Plugins");
3519
+ const candidates = findFilesNamedUnderDir$2({ rootDir: enginePluginsDir, filename: "FlockbayMCP.uplugin", maxDepth: 6 }).map((p) => path__default.resolve(p)).filter((p, idx, arr) => arr.indexOf(p) === idx);
3520
+ const disabled = [];
3521
+ const ignored = [];
3522
+ for (const upluginPath of candidates) {
3523
+ const parsed = readJsonIfPossible$2(upluginPath);
3524
+ if (!parsed || typeof parsed !== "object") {
3525
+ ignored.push(upluginPath);
3526
+ continue;
3527
+ }
3528
+ if (!isRespacedFlockbayMcpPlugin(parsed)) {
3529
+ ignored.push(upluginPath);
3530
+ continue;
3531
+ }
3532
+ if (!looksLikeLegacyBrokenEngineCopy(parsed)) {
3533
+ ignored.push(upluginPath);
3534
+ continue;
3535
+ }
3536
+ const disabledPath = `${upluginPath}.disabled`;
3537
+ if (fs__default.existsSync(disabledPath)) {
3538
+ try {
3539
+ fs__default.rmSync(upluginPath, { force: true });
3540
+ } catch {
3541
+ }
3542
+ continue;
3543
+ }
3544
+ try {
3545
+ fs__default.renameSync(upluginPath, disabledPath);
3546
+ disabled.push(upluginPath);
3547
+ } catch (err) {
3548
+ const message = err instanceof Error ? err.message : String(err);
3549
+ return {
3550
+ ok: false,
3551
+ disabledUpluginPaths: disabled,
3552
+ ignoredUpluginPaths: ignored,
3553
+ errorMessage: `Detected a legacy engine-scope FlockbayMCP plugin install that can break builds on Installed Build engines, but failed to disable it.
3554
+
3555
+ Path: ${upluginPath}
3556
+ Error: ${message}
3557
+
3558
+ Fix:
3559
+ - Close Unreal Editor
3560
+ - Rename "${upluginPath}" to "${disabledPath}" (or delete the plugin folder)
3561
+ - Re-run the Flockbay MCP project install`
3562
+ };
3563
+ }
3564
+ }
3565
+ return { ok: true, disabledUpluginPaths: disabled, ignoredUpluginPaths: ignored };
3566
+ }
3567
+
3466
3568
  function looksLikeEngineRoot$1(engineRoot) {
3467
3569
  if (!engineRoot) return false;
3468
3570
  return fs__default.existsSync(path__default.join(engineRoot, "Engine")) && fs__default.existsSync(path__default.join(engineRoot, "Engine", "Plugins"));
@@ -3502,6 +3604,14 @@ function installUnrealMcpPluginToEngine(engineRootRaw) {
3502
3604
  };
3503
3605
  }
3504
3606
  if (isInstalledEngineRoot(engineRoot)) {
3607
+ const quarantine = quarantineLegacyEnginePlugins(engineRoot);
3608
+ if (!quarantine.ok) {
3609
+ return { ok: false, errorMessage: quarantine.errorMessage };
3610
+ }
3611
+ const disabledMeta = quarantine.disabledUpluginPaths.length ? `
3612
+
3613
+ Detected and disabled legacy engine plugin descriptor(s) to unblock builds:
3614
+ ` + quarantine.disabledUpluginPaths.map((p) => `- ${p}`).join("\n") : "";
3505
3615
  return {
3506
3616
  ok: false,
3507
3617
  errorMessage: [
@@ -3516,7 +3626,7 @@ function installUnrealMcpPluginToEngine(engineRootRaw) {
3516
3626
  "If you are using the Flockbay UI/CLI, choose a project-scope install or pass a project path.",
3517
3627
  "Example:",
3518
3628
  " flockbay unreal-mcp migrate --engine-root <ENGINE_ROOT> --project <PATH_TO_.UPROJECT> --remove-legacy"
3519
- ].join("\n")
3629
+ ].join("\n") + disabledMeta
3520
3630
  };
3521
3631
  }
3522
3632
  const srcDir = unrealMcpPluginSourceDir();
@@ -3870,20 +3980,107 @@ Expected: ${binariesDir}
3870
3980
  Log: ${buildLogPath}`
3871
3981
  };
3872
3982
  }
3873
- const setEnabled = setEnabledByDefault(pluginUpluginPath, true);
3874
- if (!setEnabled.ok) {
3875
- return {
3876
- ok: false,
3877
- buildLogPath,
3878
- errorMessage: `Built the plugin, but failed to enable it.
3983
+ if (options.enableByDefault) {
3984
+ const setEnabled = setEnabledByDefault(pluginUpluginPath, true);
3985
+ if (!setEnabled.ok) {
3986
+ return {
3987
+ ok: false,
3988
+ buildLogPath,
3989
+ errorMessage: `Built the plugin, but failed to enable it.
3879
3990
  Plugin: ${pluginUpluginPath}
3880
3991
  Error: ${setEnabled.error}
3881
3992
  Log: ${buildLogPath}`
3882
- };
3993
+ };
3994
+ }
3883
3995
  }
3884
3996
  return { ok: true, buildLogPath };
3885
3997
  }
3886
3998
 
3999
+ function normalizeWindowsPath(value) {
4000
+ return path__default.win32.normalize(String(value || "").trim()).replace(/[\\/]+$/, "");
4001
+ }
4002
+ function equalsIgnoreCaseWindows(a, b) {
4003
+ return normalizeWindowsPath(a || "").toLowerCase() === normalizeWindowsPath(b || "").toLowerCase();
4004
+ }
4005
+ function extractUprojectPathFromCommandLine(commandLine) {
4006
+ const raw = String(commandLine || "").trim();
4007
+ if (!raw) return null;
4008
+ const matches = Array.from(raw.matchAll(/"([^"\r\n]+?\.uproject)"|([^\s"]+?\.uproject)/gi));
4009
+ for (const match of matches) {
4010
+ const candidate = String(match[1] || match[2] || "").trim();
4011
+ if (!candidate) continue;
4012
+ return normalizeWindowsPath(candidate);
4013
+ }
4014
+ return null;
4015
+ }
4016
+ function inferEngineRootFromExecutablePath(executablePath) {
4017
+ const normalized = normalizeWindowsPath(executablePath);
4018
+ if (!normalized) return null;
4019
+ const marker = `${path__default.win32.sep}Engine${path__default.win32.sep}Binaries${path__default.win32.sep}`;
4020
+ const idx = normalized.toLowerCase().indexOf(marker.toLowerCase());
4021
+ if (idx === -1) return null;
4022
+ return normalized.slice(0, idx);
4023
+ }
4024
+ function compareCreationDateDesc(a, b) {
4025
+ const aa = String(a || "").trim();
4026
+ const bb = String(b || "").trim();
4027
+ return bb.localeCompare(aa);
4028
+ }
4029
+ function parseRunningUnrealEditorProjectsFromWindowsJson(input) {
4030
+ const engineRoot = String(input.engineRoot || "").trim();
4031
+ const wantedEngineRoot = engineRoot ? normalizeWindowsPath(engineRoot) : "";
4032
+ const raw = String(input.raw || "").trim();
4033
+ if (!raw) return [];
4034
+ let parsed;
4035
+ try {
4036
+ parsed = JSON.parse(raw);
4037
+ } catch {
4038
+ return [];
4039
+ }
4040
+ const records = (Array.isArray(parsed) ? parsed : [parsed]).filter(Boolean);
4041
+ const out = [];
4042
+ for (const record of records) {
4043
+ const uprojectPath = extractUprojectPathFromCommandLine(String(record?.CommandLine || ""));
4044
+ if (!uprojectPath) continue;
4045
+ const executablePath = record?.ExecutablePath ? normalizeWindowsPath(record.ExecutablePath) : null;
4046
+ const inferredEngineRoot = executablePath ? inferEngineRootFromExecutablePath(executablePath) : null;
4047
+ if (wantedEngineRoot && !equalsIgnoreCaseWindows(inferredEngineRoot, wantedEngineRoot)) continue;
4048
+ const processIdNumber = Number(record?.ProcessId);
4049
+ out.push({
4050
+ processId: Number.isFinite(processIdNumber) && processIdNumber > 0 ? processIdNumber : null,
4051
+ executablePath,
4052
+ engineRoot: inferredEngineRoot,
4053
+ uprojectPath,
4054
+ commandLine: record?.CommandLine ? String(record.CommandLine) : null,
4055
+ creationDate: record?.CreationDate ? String(record.CreationDate) : null
4056
+ });
4057
+ }
4058
+ out.sort((a, b) => compareCreationDateDesc(a.creationDate, b.creationDate));
4059
+ return out;
4060
+ }
4061
+ function detectRunningUnrealEditorProject(options) {
4062
+ if (process.platform !== "win32") return null;
4063
+ const execFileSyncImpl = options?.execFileSyncImpl || execFileSync;
4064
+ const script = [
4065
+ '$ErrorActionPreference = "Stop"',
4066
+ `$procs = Get-CimInstance Win32_Process -Filter "Name = 'UnrealEditor.exe'" | Select-Object ProcessId, ExecutablePath, CommandLine, CreationDate`,
4067
+ 'if ($null -eq $procs) { "[]" } else { $procs | ConvertTo-Json -Compress -Depth 3 }'
4068
+ ].join("; ");
4069
+ try {
4070
+ const raw = execFileSyncImpl("powershell.exe", ["-NoProfile", "-Command", script], {
4071
+ encoding: "utf8",
4072
+ windowsHide: true
4073
+ });
4074
+ const matches = parseRunningUnrealEditorProjectsFromWindowsJson({
4075
+ raw: typeof raw === "string" ? raw : String(raw || ""),
4076
+ engineRoot: options?.engineRoot
4077
+ });
4078
+ return matches[0] || null;
4079
+ } catch {
4080
+ return null;
4081
+ }
4082
+ }
4083
+
3887
4084
  function canWriteDir$1(dir) {
3888
4085
  const root = String(dir || "").trim();
3889
4086
  if (!root) return false;
@@ -3959,11 +4156,14 @@ function getUnrealMcpPluginDiskStatus(params) {
3959
4156
  const checkedAtMs = Date.now();
3960
4157
  const engineRoot = String(params?.engineRoot || "").trim();
3961
4158
  const installScope = String(params?.installScope || "auto");
3962
- const projectUprojectPathRaw = typeof params?.projectUprojectPath === "string" ? params.projectUprojectPath.trim() : "";
4159
+ const requestedProjectUprojectPath = typeof params?.projectUprojectPath === "string" ? params.projectUprojectPath.trim() : "";
3963
4160
  if (!engineRoot) return { success: false, error: "Missing engineRoot." };
3964
4161
  if (!looksLikeEngineRoot(engineRoot)) {
3965
4162
  return { success: false, error: `Invalid engine root (expected an Unreal Engine install folder containing Engine/Plugins): ${engineRoot}` };
3966
4163
  }
4164
+ const installedEngine = isInstalledEngineRoot(engineRoot);
4165
+ const runningProject = detectRunningUnrealEditorProject({ engineRoot });
4166
+ const projectUprojectPathRaw = runningProject?.uprojectPath || requestedProjectUprojectPath;
3967
4167
  const enginePluginsDir = path__default.join(engineRoot, "Engine", "Plugins");
3968
4168
  const enginePluginDir = path__default.join(enginePluginsDir, "FlockbayMCP");
3969
4169
  const engineUpluginPath = path__default.join(enginePluginDir, "FlockbayMCP.uplugin");
@@ -4031,7 +4231,7 @@ function getUnrealMcpPluginDiskStatus(params) {
4031
4231
  }
4032
4232
  const engineInstalled = engineInfo.exists && engineInfo.descriptorOk && engineInfo.hasBinaries;
4033
4233
  const projectInstalled = Boolean(project && project.exists && project.descriptorOk && project.enabledInUproject);
4034
- const effectiveScope = installScope === "engine" ? "engine" : installScope === "project" ? "project" : engineInstalled ? "engine" : project && !engineInfo.enginePluginsWritable ? "project" : "engine";
4234
+ const effectiveScope = installScope === "engine" ? "engine" : installScope === "project" ? "project" : installedEngine && project ? "project" : engineInstalled ? "engine" : project && !engineInfo.enginePluginsWritable ? "project" : "engine";
4035
4235
  const conflict = engineInfo.conflicts.length > 0;
4036
4236
  const legacyConflict = engineInfo.legacy.length > 0;
4037
4237
  const baseInstalled = effectiveScope === "engine" ? engineInstalled : projectInstalled;
@@ -4746,12 +4946,18 @@ class ApiMachineClient {
4746
4946
  async (params) => {
4747
4947
  const engineRoot = String(params?.engineRoot || "").trim();
4748
4948
  const scope = String(params?.installScope || "auto");
4749
- const projectUprojectPath = typeof params?.projectUprojectPath === "string" ? params.projectUprojectPath.trim() : "";
4949
+ const requestedProjectUprojectPath = typeof params?.projectUprojectPath === "string" ? params.projectUprojectPath.trim() : "";
4750
4950
  const enginePluginsDir = path__default.join(engineRoot, "Engine", "Plugins");
4751
4951
  const enginePluginDir = path__default.join(enginePluginsDir, "FlockbayMCP");
4752
4952
  const enginePluginUplugin = path__default.join(enginePluginDir, "FlockbayMCP.uplugin");
4753
4953
  const enginePluginHasBinaries = fs__default.existsSync(path__default.join(enginePluginDir, "Binaries"));
4754
4954
  const installedEngine = isInstalledEngineRoot(engineRoot);
4955
+ const runningProject = installedEngine ? detectRunningUnrealEditorProject({ engineRoot }) : null;
4956
+ const projectUprojectPath = runningProject?.uprojectPath || requestedProjectUprojectPath;
4957
+ if (installedEngine) {
4958
+ const quarantine = quarantineLegacyEnginePlugins(engineRoot);
4959
+ if (!quarantine.ok) return { success: false, error: quarantine.errorMessage };
4960
+ }
4755
4961
  if (scope === "engine" && installedEngine) {
4756
4962
  return {
4757
4963
  success: false,
@@ -4788,7 +4994,8 @@ class ApiMachineClient {
4788
4994
  const built = await buildAndInstallUnrealMcpPlugin({
4789
4995
  engineRoot,
4790
4996
  flockbayHomeDir: this.machine?.metadata?.flockbayHomeDir || os__default.homedir(),
4791
- pluginDir: installedProject.destDir
4997
+ pluginDir: installedProject.destDir,
4998
+ enableByDefault: false
4792
4999
  });
4793
5000
  if (!built.ok) return { success: false, error: built.errorMessage };
4794
5001
  return { success: true, engineRoot, destDir: installedProject.destDir, buildLogPath: built.buildLogPath };
@@ -4803,7 +5010,8 @@ class ApiMachineClient {
4803
5010
  }
4804
5011
  const built = await buildAndInstallUnrealMcpPlugin({
4805
5012
  engineRoot: result.engineRoot,
4806
- flockbayHomeDir: this.machine?.metadata?.flockbayHomeDir || os__default.homedir()
5013
+ flockbayHomeDir: this.machine?.metadata?.flockbayHomeDir || os__default.homedir(),
5014
+ enableByDefault: true
4807
5015
  });
4808
5016
  if (!built.ok) return { success: false, error: built.errorMessage };
4809
5017
  return { success: true, engineRoot: result.engineRoot, destDir: result.destDir, buildLogPath: built.buildLogPath };
@@ -5345,4 +5553,4 @@ const RawJSONLinesSchema = z$1.discriminatedUnion("type", [
5345
5553
  }).passthrough()
5346
5554
  ]);
5347
5555
 
5348
- export { ApiClient as A, buildShellInvocation as B, clearCredentials as C, clearMachineId as D, authenticateCodex as E, syncCodexCliAuth as F, authenticateClaude as G, authenticateGemini as H, buildAndInstallUnrealMcpPlugin as I, getLatestDaemonLog as J, normalizeServerUrlForNode as K, RawJSONLinesSchema as R, ApiSessionClient as a, isInstalledEngineRoot as b, configuration as c, installUnrealMcpPluginToEngine as d, projectPath as e, backoff as f, delay as g, readDaemonState as h, installUnrealMcpPluginToProject as i, clearDaemonState as j, readCredentials as k, logger as l, unrealMcpPythonDir as m, acquireDaemonLock as n, openBrowser as o, packageJson as p, writeDaemonState as q, readSettings as r, ApiMachineClient as s, releaseDaemonLock as t, updateSettings as u, sendUnrealMcpTcpCommand as v, writeCredentials as w, validatePath as x, run$1 as y, run as z };
5556
+ export { ApiClient as A, run as B, buildShellInvocation as C, clearCredentials as D, clearMachineId as E, authenticateCodex as F, syncCodexCliAuth as G, authenticateClaude as H, authenticateGemini as I, buildAndInstallUnrealMcpPlugin as J, getLatestDaemonLog as K, normalizeServerUrlForNode as L, RawJSONLinesSchema as R, ApiSessionClient as a, isInstalledEngineRoot as b, configuration as c, installUnrealMcpPluginToEngine as d, projectPath as e, backoff as f, delay as g, readDaemonState as h, installUnrealMcpPluginToProject as i, clearDaemonState as j, readCredentials as k, logger as l, unrealMcpPythonDir as m, acquireDaemonLock as n, openBrowser as o, packageJson as p, quarantineLegacyEnginePlugins as q, readSettings as r, writeDaemonState as s, ApiMachineClient as t, updateSettings as u, releaseDaemonLock as v, writeCredentials as w, sendUnrealMcpTcpCommand as x, validatePath as y, run$1 as z };
package/package.json CHANGED
@@ -1,131 +1,131 @@
1
- {
2
- "name": "flockbay",
3
- "version": "0.10.49",
4
- "description": "Flockbay CLI (local agent + daemon)",
5
- "author": "Eduardo Orellana",
6
- "license": "UNLICENSED",
7
- "type": "module",
8
- "homepage": "https://flockbay.com",
9
- "bugs": "https://flockbay.com",
10
- "repository": {
11
- "type": "git",
12
- "url": "https://flockbay.com"
13
- },
14
- "bin": {
15
- "flockbay": "bin/flockbay.mjs",
16
- "flockbay-mcp": "bin/flockbay-mcp.mjs"
17
- },
18
- "main": "./dist/index.cjs",
19
- "module": "./dist/index.mjs",
20
- "types": "./dist/index.d.cts",
21
- "exports": {
22
- ".": {
23
- "require": {
24
- "types": "./dist/index.d.cts",
25
- "default": "./dist/index.cjs"
26
- },
27
- "import": {
28
- "types": "./dist/index.d.mts",
29
- "default": "./dist/index.mjs"
30
- }
31
- },
32
- "./lib": {
33
- "require": {
34
- "types": "./dist/lib.d.cts",
35
- "default": "./dist/lib.cjs"
36
- },
37
- "import": {
38
- "types": "./dist/lib.d.mts",
39
- "default": "./dist/lib.mjs"
40
- }
41
- },
42
- "./codex/flockbayMcpStdioBridge": {
43
- "require": {
44
- "types": "./dist/codex/flockbayMcpStdioBridge.d.cts",
45
- "default": "./dist/codex/flockbayMcpStdioBridge.cjs"
46
- },
47
- "import": {
48
- "types": "./dist/codex/flockbayMcpStdioBridge.d.mts",
49
- "default": "./dist/codex/flockbayMcpStdioBridge.mjs"
50
- }
51
- }
52
- },
53
- "files": [
54
- "dist",
55
- "bin",
56
- "scripts",
57
- "tools/licenses",
58
- "tools/unreal-mcp",
59
- "package.json"
60
- ],
61
- "scripts": {
62
- "why do we need to build before running tests / dev?": "We need the binary to be built so daemon commands run the built CLI (avoids drift between dev entrypoints and the packaged runtime).",
63
- "typecheck": "tsc --noEmit",
64
- "build": "shx rm -rf dist && npx tsc --noEmit && pkgroll",
65
- "test": "yarn build && vitest run",
66
- "start": "yarn build && node ./bin/flockbay.mjs",
67
- "dev": "tsx src/index.ts",
68
- "dev:local-server": "yarn build && tsx --env-file .env.dev-local-server src/index.ts",
69
- "dev:integration-test-env": "yarn build && tsx --env-file .env.integration-test src/index.ts",
70
- "prepublishOnly": "node scripts/run-with-root-env.mjs yarn build && node scripts/run-with-root-env.mjs yarn test",
71
- "npm:whoami": "node scripts/run-with-root-env.mjs npm whoami",
72
- "publish:public": "node scripts/run-with-root-env.mjs npm publish --access public",
73
- "release": "yarn install && release-it",
74
- "postinstall": "node scripts/unpack-tools.cjs"
75
- },
76
- "dependencies": {
77
- "@agentclientprotocol/sdk": "^0.8.0",
78
- "@modelcontextprotocol/sdk": "^1.22.0",
79
- "@stablelib/base64": "^2.0.1",
80
- "@stablelib/hex": "^2.0.1",
81
- "@types/cross-spawn": "^6.0.6",
82
- "@types/http-proxy": "^1.17.17",
83
- "@types/ps-list": "^6.2.1",
84
- "@types/qrcode-terminal": "^0.12.2",
85
- "@types/react": "^19.2.7",
86
- "@types/tmp": "^0.2.6",
87
- "ai": "^5.0.107",
88
- "axios": "^1.13.2",
89
- "chalk": "^5.6.2",
90
- "cross-spawn": "^7.0.6",
91
- "expo-server-sdk": "^3.15.0",
92
- "fastify": "^5.6.2",
93
- "fastify-type-provider-zod": "4.0.2",
94
- "http-proxy": "^1.18.1",
95
- "http-proxy-middleware": "^3.0.5",
96
- "ink": "^6.5.1",
97
- "open": "^10.2.0",
98
- "ps-list": "^8.1.1",
99
- "qrcode-terminal": "^0.12.0",
100
- "react": "^19.2.0",
101
- "socket.io-client": "^4.8.1",
102
- "tar": "^7.5.2",
103
- "tmp": "^0.2.5",
104
- "tweetnacl": "^1.0.3",
105
- "zod": "^3.23.8"
106
- },
107
- "devDependencies": {
108
- "@eslint/compat": "^1",
109
- "@types/node": ">=20",
110
- "cross-env": "^10.1.0",
111
- "dotenv": "^16.6.1",
112
- "eslint": "^9",
113
- "eslint-config-prettier": "^10",
114
- "pkgroll": "^2.14.2",
115
- "release-it": "^19.0.6",
116
- "shx": "^0.3.3",
117
- "ts-node": "^10",
118
- "tsx": "^4.20.6",
119
- "typescript": "^5",
120
- "vitest": "^3.2.4"
121
- },
122
- "resolutions": {
123
- "whatwg-url": "14.2.0",
124
- "parse-path": "7.0.3",
125
- "@types/parse-path": "7.0.3"
126
- },
127
- "publishConfig": {
128
- "registry": "https://registry.npmjs.org"
129
- },
130
- "packageManager": "yarn@1.22.22"
131
- }
1
+ {
2
+ "name": "flockbay",
3
+ "version": "0.10.52",
4
+ "description": "Flockbay CLI (local agent + daemon)",
5
+ "author": "Eduardo Orellana",
6
+ "license": "UNLICENSED",
7
+ "type": "module",
8
+ "homepage": "https://flockbay.com",
9
+ "bugs": "https://flockbay.com",
10
+ "repository": {
11
+ "type": "git",
12
+ "url": "https://flockbay.com"
13
+ },
14
+ "bin": {
15
+ "flockbay": "bin/flockbay.mjs",
16
+ "flockbay-mcp": "bin/flockbay-mcp.mjs"
17
+ },
18
+ "main": "./dist/index.cjs",
19
+ "module": "./dist/index.mjs",
20
+ "types": "./dist/index.d.cts",
21
+ "exports": {
22
+ ".": {
23
+ "require": {
24
+ "types": "./dist/index.d.cts",
25
+ "default": "./dist/index.cjs"
26
+ },
27
+ "import": {
28
+ "types": "./dist/index.d.mts",
29
+ "default": "./dist/index.mjs"
30
+ }
31
+ },
32
+ "./lib": {
33
+ "require": {
34
+ "types": "./dist/lib.d.cts",
35
+ "default": "./dist/lib.cjs"
36
+ },
37
+ "import": {
38
+ "types": "./dist/lib.d.mts",
39
+ "default": "./dist/lib.mjs"
40
+ }
41
+ },
42
+ "./codex/flockbayMcpStdioBridge": {
43
+ "require": {
44
+ "types": "./dist/codex/flockbayMcpStdioBridge.d.cts",
45
+ "default": "./dist/codex/flockbayMcpStdioBridge.cjs"
46
+ },
47
+ "import": {
48
+ "types": "./dist/codex/flockbayMcpStdioBridge.d.mts",
49
+ "default": "./dist/codex/flockbayMcpStdioBridge.mjs"
50
+ }
51
+ }
52
+ },
53
+ "files": [
54
+ "dist",
55
+ "bin",
56
+ "scripts",
57
+ "tools/licenses",
58
+ "tools/unreal-mcp",
59
+ "package.json"
60
+ ],
61
+ "scripts": {
62
+ "why do we need to build before running tests / dev?": "We need the binary to be built so daemon commands run the built CLI (avoids drift between dev entrypoints and the packaged runtime).",
63
+ "typecheck": "tsc --noEmit",
64
+ "build": "shx rm -rf dist && npx tsc --noEmit && pkgroll",
65
+ "test": "yarn build && vitest run",
66
+ "start": "yarn build && node ./bin/flockbay.mjs",
67
+ "dev": "tsx src/index.ts",
68
+ "dev:local-server": "yarn build && tsx --env-file .env.dev-local-server src/index.ts",
69
+ "dev:integration-test-env": "yarn build && tsx --env-file .env.integration-test src/index.ts",
70
+ "prepublishOnly": "node scripts/run-with-root-env.mjs yarn build && node scripts/run-with-root-env.mjs yarn test",
71
+ "npm:whoami": "node scripts/run-with-root-env.mjs npm whoami",
72
+ "publish:public": "node scripts/run-with-root-env.mjs npm publish --access public",
73
+ "release": "yarn install && release-it",
74
+ "postinstall": "node scripts/unpack-tools.cjs"
75
+ },
76
+ "dependencies": {
77
+ "@agentclientprotocol/sdk": "^0.8.0",
78
+ "@modelcontextprotocol/sdk": "^1.22.0",
79
+ "@stablelib/base64": "^2.0.1",
80
+ "@stablelib/hex": "^2.0.1",
81
+ "@types/cross-spawn": "^6.0.6",
82
+ "@types/http-proxy": "^1.17.17",
83
+ "@types/ps-list": "^6.2.1",
84
+ "@types/qrcode-terminal": "^0.12.2",
85
+ "@types/react": "^19.2.7",
86
+ "@types/tmp": "^0.2.6",
87
+ "ai": "^5.0.107",
88
+ "axios": "^1.13.2",
89
+ "chalk": "^5.6.2",
90
+ "cross-spawn": "^7.0.6",
91
+ "expo-server-sdk": "^3.15.0",
92
+ "fastify": "^5.6.2",
93
+ "fastify-type-provider-zod": "4.0.2",
94
+ "http-proxy": "^1.18.1",
95
+ "http-proxy-middleware": "^3.0.5",
96
+ "ink": "^6.5.1",
97
+ "open": "^10.2.0",
98
+ "ps-list": "^8.1.1",
99
+ "qrcode-terminal": "^0.12.0",
100
+ "react": "^19.2.0",
101
+ "socket.io-client": "^4.8.1",
102
+ "tar": "^7.5.2",
103
+ "tmp": "^0.2.5",
104
+ "tweetnacl": "^1.0.3",
105
+ "zod": "^3.23.8"
106
+ },
107
+ "devDependencies": {
108
+ "@eslint/compat": "^1",
109
+ "@types/node": ">=20",
110
+ "cross-env": "^10.1.0",
111
+ "dotenv": "^16.6.1",
112
+ "eslint": "^9",
113
+ "eslint-config-prettier": "^10",
114
+ "pkgroll": "^2.14.2",
115
+ "release-it": "^19.0.6",
116
+ "shx": "^0.3.3",
117
+ "ts-node": "^10",
118
+ "tsx": "^4.20.6",
119
+ "typescript": "^5",
120
+ "vitest": "^3.2.4"
121
+ },
122
+ "resolutions": {
123
+ "whatwg-url": "14.2.0",
124
+ "parse-path": "7.0.3",
125
+ "@types/parse-path": "7.0.3"
126
+ },
127
+ "publishConfig": {
128
+ "registry": "https://registry.npmjs.org"
129
+ },
130
+ "packageManager": "yarn@1.22.22"
131
+ }