flockbay 0.10.15 → 0.10.16
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/dist/codex/flockbayMcpStdioBridge.cjs +339 -0
- package/dist/codex/flockbayMcpStdioBridge.mjs +339 -0
- package/dist/{index--o4BPz5o.cjs → index-Cau-_Qvn.cjs} +2683 -609
- package/dist/{index-CUp3juDS.mjs → index-DtmFQzXY.mjs} +2684 -611
- package/dist/index.cjs +3 -5
- package/dist/index.mjs +3 -5
- package/dist/lib.cjs +7 -9
- package/dist/lib.d.cts +219 -531
- package/dist/lib.d.mts +219 -531
- package/dist/lib.mjs +7 -9
- package/dist/{runCodex-o6PCbHQ7.mjs → runCodex-Di9eHddq.mjs} +263 -42
- package/dist/{runCodex-D3eT-TvB.cjs → runCodex-DzP3VUa-.cjs} +264 -43
- package/dist/{runGemini-Bt0oEj_g.mjs → runGemini-BS6sBU_V.mjs} +63 -28
- package/dist/{runGemini-CBxZp6I7.cjs → runGemini-CpmehDQ2.cjs} +64 -29
- package/dist/{types-DGd6ea2Z.mjs → types-CwzNqYEx.mjs} +465 -1142
- package/dist/{types-C-jnUdn_.cjs → types-SUAKq-K0.cjs} +466 -1146
- package/package.json +1 -1
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/Commands/UnrealMCPBlueprintCommands.cpp +195 -6
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/Commands/UnrealMCPBlueprintNodeCommands.cpp +376 -5
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/Commands/UnrealMCPCommandSchema.cpp +731 -0
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/Commands/UnrealMCPCommonUtils.cpp +476 -8
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/Commands/UnrealMCPEditorCommands.cpp +1518 -94
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/MCPServerRunnable.cpp +7 -4
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Private/UnrealMCPBridge.cpp +150 -112
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Public/Commands/UnrealMCPBlueprintCommands.h +2 -1
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Public/Commands/UnrealMCPBlueprintNodeCommands.h +4 -1
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Public/Commands/UnrealMCPCommandSchema.h +42 -0
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/Public/Commands/UnrealMCPEditorCommands.h +21 -0
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/UnrealMCP/Source/UnrealMCP/UnrealMCP.Build.cs +4 -1
- package/dist/flockbayScreenshotGate-DJX3Is5d.mjs +0 -136
- package/dist/flockbayScreenshotGate-DkxU24cR.cjs +0 -138
|
@@ -1,138 +0,0 @@
|
|
|
1
|
-
'use strict';
|
|
2
|
-
|
|
3
|
-
var path = require('node:path');
|
|
4
|
-
|
|
5
|
-
function uniqPush(into, seen, value) {
|
|
6
|
-
const v = value.trim();
|
|
7
|
-
if (!v) return;
|
|
8
|
-
if (seen.has(v)) return;
|
|
9
|
-
seen.add(v);
|
|
10
|
-
into.push(v);
|
|
11
|
-
}
|
|
12
|
-
function normalizeFilePathToken(token) {
|
|
13
|
-
return token.trim().replace(/^['"`]+/, "").replace(/['"`]+$/, "").replace(/[),.;:'"`]+$/, "").trim();
|
|
14
|
-
}
|
|
15
|
-
function resolveCandidatePath(candidate, cwd) {
|
|
16
|
-
const raw = normalizeFilePathToken(candidate);
|
|
17
|
-
if (!raw) return raw;
|
|
18
|
-
if (raw.startsWith("~/")) {
|
|
19
|
-
const home = process.env.HOME || process.env.USERPROFILE || "";
|
|
20
|
-
if (home) return path.join(home, raw.slice(2));
|
|
21
|
-
}
|
|
22
|
-
return path.isAbsolute(raw) ? raw : path.resolve(cwd, raw);
|
|
23
|
-
}
|
|
24
|
-
function isImageBlock(block) {
|
|
25
|
-
if (!block || typeof block !== "object") return false;
|
|
26
|
-
if (block.type !== "image") return false;
|
|
27
|
-
if (typeof block.data === "string" && block.data.length > 0) return true;
|
|
28
|
-
if (block.source && typeof block.source === "object" && typeof block.source.data === "string" && block.source.data.length > 0) return true;
|
|
29
|
-
return false;
|
|
30
|
-
}
|
|
31
|
-
function tryParseJsonObjectWithViews(text) {
|
|
32
|
-
const trimmed = text.trim();
|
|
33
|
-
if (!trimmed) return null;
|
|
34
|
-
try {
|
|
35
|
-
const direct = JSON.parse(trimmed);
|
|
36
|
-
if (direct && typeof direct === "object" && Array.isArray(direct.views)) return direct;
|
|
37
|
-
} catch {
|
|
38
|
-
}
|
|
39
|
-
for (let i = trimmed.length - 1; i >= 0; i -= 1) {
|
|
40
|
-
if (trimmed[i] !== "{") continue;
|
|
41
|
-
const candidate = trimmed.slice(i);
|
|
42
|
-
try {
|
|
43
|
-
const parsed = JSON.parse(candidate);
|
|
44
|
-
if (parsed && typeof parsed === "object" && Array.isArray(parsed.views)) return parsed;
|
|
45
|
-
} catch {
|
|
46
|
-
}
|
|
47
|
-
}
|
|
48
|
-
return null;
|
|
49
|
-
}
|
|
50
|
-
function extractScreenshotViewsFromText(text, cwd) {
|
|
51
|
-
const out = [];
|
|
52
|
-
const seen = /* @__PURE__ */ new Set();
|
|
53
|
-
const re = /(?:^|[\s"'(])(?:-\s*)?([^\s"'()]*Saved[\\/]+Screenshots[\\/]+Flockbay[\\/]+[^\s"'()]+\.(?:png|jpg|jpeg))/gi;
|
|
54
|
-
for (const match of text.matchAll(re)) {
|
|
55
|
-
const token = String(match[1] || "");
|
|
56
|
-
const resolved = resolveCandidatePath(token, cwd);
|
|
57
|
-
if (!resolved) continue;
|
|
58
|
-
if (!resolved.includes(`${path.sep}Saved${path.sep}Screenshots${path.sep}Flockbay${path.sep}`) && !resolved.includes("Saved/Screenshots/Flockbay/") && !resolved.includes("Saved\\Screenshots\\Flockbay\\")) {
|
|
59
|
-
continue;
|
|
60
|
-
}
|
|
61
|
-
uniqPush(out, seen, resolved);
|
|
62
|
-
}
|
|
63
|
-
if (out.length === 0 && (text.includes("Saved/Screenshots/Flockbay") || text.includes("Saved\\Screenshots\\Flockbay"))) {
|
|
64
|
-
const filenameRe = /(?:^|[\s"'(\\/])(?:-\s*)?(Flockbay_[A-Za-z0-9_.-]+\.(?:png|jpg|jpeg))/gi;
|
|
65
|
-
for (const match of text.matchAll(filenameRe)) {
|
|
66
|
-
const filename = normalizeFilePathToken(String(match[1] || ""));
|
|
67
|
-
if (!filename) continue;
|
|
68
|
-
const rel = path.join("Saved", "Screenshots", "Flockbay", filename);
|
|
69
|
-
const resolved = resolveCandidatePath(rel, cwd);
|
|
70
|
-
uniqPush(out, seen, resolved);
|
|
71
|
-
}
|
|
72
|
-
}
|
|
73
|
-
return out;
|
|
74
|
-
}
|
|
75
|
-
function extractViewsFromParsedJson(parsed, cwd) {
|
|
76
|
-
const out = [];
|
|
77
|
-
const seen = /* @__PURE__ */ new Set();
|
|
78
|
-
const views = Array.isArray(parsed?.views) ? parsed.views : [];
|
|
79
|
-
for (const v of views) {
|
|
80
|
-
const p = typeof v?.path === "string" ? v.path : "";
|
|
81
|
-
if (!p.trim()) continue;
|
|
82
|
-
uniqPush(out, seen, resolveCandidatePath(p, cwd));
|
|
83
|
-
}
|
|
84
|
-
return out;
|
|
85
|
-
}
|
|
86
|
-
function extractFromContentBlocks(content, cwd) {
|
|
87
|
-
const texts = [];
|
|
88
|
-
let hasImages = false;
|
|
89
|
-
for (const block of content) {
|
|
90
|
-
if (block && typeof block === "object" && block.type === "text" && typeof block.text === "string") {
|
|
91
|
-
texts.push(block.text);
|
|
92
|
-
}
|
|
93
|
-
if (!hasImages && isImageBlock(block)) hasImages = true;
|
|
94
|
-
}
|
|
95
|
-
const text = texts.join("\n");
|
|
96
|
-
const parsed = tryParseJsonObjectWithViews(text);
|
|
97
|
-
const jsonPaths = parsed ? extractViewsFromParsedJson(parsed, cwd) : [];
|
|
98
|
-
const pathMatches = extractScreenshotViewsFromText(text, cwd);
|
|
99
|
-
const combined = [];
|
|
100
|
-
const seen = /* @__PURE__ */ new Set();
|
|
101
|
-
for (const p of jsonPaths) uniqPush(combined, seen, p);
|
|
102
|
-
for (const p of pathMatches) uniqPush(combined, seen, p);
|
|
103
|
-
return { paths: combined, hasImages };
|
|
104
|
-
}
|
|
105
|
-
function detectScreenshotsForGate(args) {
|
|
106
|
-
const cwd = args.cwd && args.cwd.trim().length > 0 ? args.cwd : process.cwd();
|
|
107
|
-
const output = args.output;
|
|
108
|
-
if (Array.isArray(output)) {
|
|
109
|
-
const extracted = extractFromContentBlocks(output, cwd);
|
|
110
|
-
return { paths: extracted.paths, hasImageBlocks: extracted.hasImages };
|
|
111
|
-
}
|
|
112
|
-
if (output && typeof output === "object" && Array.isArray(output.content)) {
|
|
113
|
-
const extracted = extractFromContentBlocks(output.content, cwd);
|
|
114
|
-
return { paths: extracted.paths, hasImageBlocks: extracted.hasImages };
|
|
115
|
-
}
|
|
116
|
-
if (output && typeof output === "object" && Array.isArray(output.views)) {
|
|
117
|
-
return { paths: extractViewsFromParsedJson(output, cwd), hasImageBlocks: false };
|
|
118
|
-
}
|
|
119
|
-
const candidates = [
|
|
120
|
-
typeof output === "string" ? output : null,
|
|
121
|
-
typeof output?.stdout === "string" ? output.stdout : null,
|
|
122
|
-
typeof output?.stderr === "string" ? output.stderr : null,
|
|
123
|
-
typeof output?.output === "string" ? output.output : null,
|
|
124
|
-
typeof output?.message === "string" ? output.message : null
|
|
125
|
-
];
|
|
126
|
-
const combinedText = candidates.filter((v) => typeof v === "string" && v.trim().length > 0).join("\n");
|
|
127
|
-
if (!combinedText) return { paths: [], hasImageBlocks: false };
|
|
128
|
-
const parsed = tryParseJsonObjectWithViews(combinedText);
|
|
129
|
-
const jsonPaths = parsed ? extractViewsFromParsedJson(parsed, cwd) : [];
|
|
130
|
-
const pathMatches = extractScreenshotViewsFromText(combinedText, cwd);
|
|
131
|
-
const out = [];
|
|
132
|
-
const seen = /* @__PURE__ */ new Set();
|
|
133
|
-
for (const p of jsonPaths) uniqPush(out, seen, p);
|
|
134
|
-
for (const p of pathMatches) uniqPush(out, seen, p);
|
|
135
|
-
return { paths: out, hasImageBlocks: false };
|
|
136
|
-
}
|
|
137
|
-
|
|
138
|
-
exports.detectScreenshotsForGate = detectScreenshotsForGate;
|