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.
- package/README.md +60 -60
- package/bin/flockbay-mcp.mjs +62 -62
- package/bin/flockbay.mjs +95 -95
- package/dist/{index-r3VTdgFI.cjs → index-IntvnrmZ.cjs} +71 -14
- package/dist/{index-D8AeVbvv.mjs → index-wkeSi0iC.mjs} +70 -13
- package/dist/index.cjs +2 -2
- package/dist/index.mjs +2 -2
- package/dist/lib.cjs +1 -1
- package/dist/lib.mjs +1 -1
- package/dist/{migratePlugin-CEvGPul8.mjs → migratePlugin-C71hAoc5.mjs} +12 -2
- package/dist/{migratePlugin-wFK-k3Wk.cjs → migratePlugin-D1XjjWFq.cjs} +12 -2
- package/dist/{runCodex-DuyuYqoB.cjs → runCodex-B7i_ICoQ.cjs} +34 -23
- package/dist/{runCodex-ZfUyhHF6.mjs → runCodex-BSx-hCu6.mjs} +34 -23
- package/dist/{runGemini-DBU1mMdp.mjs → runGemini-Dwyh7_WI.mjs} +2 -2
- package/dist/{runGemini-D7j5Y5TF.cjs → runGemini-gBKR3rdL.cjs} +2 -2
- package/dist/{types-DNr0xwSy.cjs → types-5z8UADAi.cjs} +224 -15
- package/dist/{types-BRJuZQj_.mjs → types-Bgzap7qR.mjs} +224 -16
- package/package.json +131 -131
- package/scripts/claude_local_launcher.cjs +72 -72
- package/scripts/claude_remote_launcher.cjs +15 -15
- package/scripts/claude_version_utils.cjs +445 -445
- package/scripts/ripgrep_launcher.cjs +32 -32
- package/scripts/run-with-root-env.mjs +37 -32
- package/scripts/session_hook_forwarder.cjs +49 -49
- package/scripts/test-codex-abort-history.mjs +77 -77
- package/scripts/unpack-tools.cjs +244 -244
- package/tools/licenses/difftastic-LICENSE +21 -21
- package/tools/licenses/ripgrep-LICENSE +3 -3
- package/tools/unreal-mcp/UPSTREAM_VERSION.md +8 -8
- package/tools/unreal-mcp/upstream/Docs/README.md +8 -8
- package/tools/unreal-mcp/upstream/Docs/Tools/README.md +6 -6
- package/tools/unreal-mcp/upstream/Docs/Tools/actor_tools.md +183 -183
- package/tools/unreal-mcp/upstream/Docs/Tools/blueprint_tools.md +268 -268
- package/tools/unreal-mcp/upstream/Docs/Tools/editor_tools.md +104 -104
- package/tools/unreal-mcp/upstream/Docs/Tools/node_tools.md +274 -274
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Config/FilterPlugin.ini +8 -8
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/FlockbayMCP.uplugin +36 -36
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/FlockbayMCP.Build.cs +82 -82
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPBlueprintCommands.cpp +1364 -1364
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPBlueprintNodeCommands.cpp +1310 -1310
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPCommandSchema.cpp +756 -756
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPCommonUtils.cpp +1177 -1177
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPEditorCommands.cpp +2618 -2618
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPProjectCommands.cpp +71 -71
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/Commands/UnrealMCPUMGCommands.cpp +543 -543
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/MCPServerRunnable.cpp +372 -372
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/UnrealMCPBridge.cpp +457 -457
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Private/UnrealMCPModule.cpp +21 -21
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPBlueprintCommands.h +35 -35
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPBlueprintNodeCommands.h +30 -30
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPCommandSchema.h +41 -41
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPCommonUtils.h +59 -59
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPEditorCommands.h +61 -61
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPProjectCommands.h +20 -20
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/Commands/UnrealMCPUMGCommands.h +82 -82
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/MCPServerRunnable.h +33 -33
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/UnrealMCPBridge.h +64 -64
- package/tools/unreal-mcp/upstream/MCPGameProject/Plugins/FlockbayMCP/Source/FlockbayMCP/Public/UnrealMCPModule.h +22 -22
- package/tools/unreal-mcp/upstream/Python/README.md +39 -39
- package/tools/unreal-mcp/upstream/Python/pyproject.toml +22 -22
- package/tools/unreal-mcp/upstream/Python/scripts/actors/test_cube.py +202 -202
- package/tools/unreal-mcp/upstream/Python/scripts/blueprints/test_create_and_spawn_blueprints_with_different_components.py +496 -496
- package/tools/unreal-mcp/upstream/Python/scripts/blueprints/test_create_and_spawn_cube_blueprint.py +193 -193
- package/tools/unreal-mcp/upstream/Python/scripts/node/test_component_reference.py +266 -266
- package/tools/unreal-mcp/upstream/Python/scripts/node/test_create_bird_blueprint_with_input_and_camera.py +617 -617
- package/tools/unreal-mcp/upstream/Python/scripts/node/test_input_mapping.py +365 -365
- package/tools/unreal-mcp/upstream/Python/scripts/node/test_physics_variables.py +389 -389
- package/tools/unreal-mcp/upstream/Python/tools/blueprint_tools.py +419 -419
- package/tools/unreal-mcp/upstream/Python/tools/editor_tools.py +369 -369
- package/tools/unreal-mcp/upstream/Python/tools/node_tools.py +429 -429
- package/tools/unreal-mcp/upstream/Python/tools/project_tools.py +63 -63
- package/tools/unreal-mcp/upstream/Python/tools/umg_tools.py +332 -332
- package/tools/unreal-mcp/upstream/Python/unreal_mcp_server.py +398 -398
- package/tools/unreal-mcp/upstream/Python/uv.lock +521 -521
|
@@ -1,21 +1,21 @@
|
|
|
1
|
-
#include "UnrealMCPModule.h"
|
|
2
|
-
#include "UnrealMCPBridge.h"
|
|
3
|
-
#include "Modules/ModuleManager.h"
|
|
4
|
-
#include "EditorSubsystem.h"
|
|
5
|
-
#include "Editor.h"
|
|
6
|
-
|
|
7
|
-
#define LOCTEXT_NAMESPACE "FUnrealMCPModule"
|
|
8
|
-
|
|
9
|
-
void FUnrealMCPModule::StartupModule()
|
|
10
|
-
{
|
|
11
|
-
UE_LOG(LogTemp, Display, TEXT("Flockbay MCP Module has started"));
|
|
12
|
-
}
|
|
13
|
-
|
|
14
|
-
void FUnrealMCPModule::ShutdownModule()
|
|
15
|
-
{
|
|
16
|
-
UE_LOG(LogTemp, Display, TEXT("Flockbay MCP Module has shut down"));
|
|
17
|
-
}
|
|
18
|
-
|
|
19
|
-
#undef LOCTEXT_NAMESPACE
|
|
20
|
-
|
|
21
|
-
IMPLEMENT_MODULE(FUnrealMCPModule, FlockbayMCP)
|
|
1
|
+
#include "UnrealMCPModule.h"
|
|
2
|
+
#include "UnrealMCPBridge.h"
|
|
3
|
+
#include "Modules/ModuleManager.h"
|
|
4
|
+
#include "EditorSubsystem.h"
|
|
5
|
+
#include "Editor.h"
|
|
6
|
+
|
|
7
|
+
#define LOCTEXT_NAMESPACE "FUnrealMCPModule"
|
|
8
|
+
|
|
9
|
+
void FUnrealMCPModule::StartupModule()
|
|
10
|
+
{
|
|
11
|
+
UE_LOG(LogTemp, Display, TEXT("Flockbay MCP Module has started"));
|
|
12
|
+
}
|
|
13
|
+
|
|
14
|
+
void FUnrealMCPModule::ShutdownModule()
|
|
15
|
+
{
|
|
16
|
+
UE_LOG(LogTemp, Display, TEXT("Flockbay MCP Module has shut down"));
|
|
17
|
+
}
|
|
18
|
+
|
|
19
|
+
#undef LOCTEXT_NAMESPACE
|
|
20
|
+
|
|
21
|
+
IMPLEMENT_MODULE(FUnrealMCPModule, FlockbayMCP)
|
|
@@ -1,35 +1,35 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Json.h"
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Handler class for Blueprint-related MCP commands
|
|
8
|
-
*/
|
|
9
|
-
class FLOCKBAYMCP_API FUnrealMCPBlueprintCommands
|
|
10
|
-
{
|
|
11
|
-
public:
|
|
12
|
-
FUnrealMCPBlueprintCommands();
|
|
13
|
-
|
|
14
|
-
// Handle blueprint commands
|
|
15
|
-
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
-
|
|
17
|
-
private:
|
|
18
|
-
// Specific blueprint command handlers
|
|
19
|
-
TSharedPtr<FJsonObject> HandleCreateBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
-
TSharedPtr<FJsonObject> HandleAddComponentToBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
-
TSharedPtr<FJsonObject> HandleSetComponentProperty(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
-
TSharedPtr<FJsonObject> HandleSetPhysicsProperties(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
-
TSharedPtr<FJsonObject> HandleCompileBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
-
TSharedPtr<FJsonObject> HandleCompileBlueprintsAll(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
-
TSharedPtr<FJsonObject> HandleSpawnBlueprintActor(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
-
TSharedPtr<FJsonObject> HandleSetBlueprintProperty(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
-
TSharedPtr<FJsonObject> HandleSetStaticMeshProperties(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
-
TSharedPtr<FJsonObject> HandleSetPawnProperties(const TSharedPtr<FJsonObject>& Params);
|
|
29
|
-
|
|
30
|
-
// Helper functions
|
|
31
|
-
TSharedPtr<FJsonObject> AddComponentToBlueprint(const FString& BlueprintName, const FString& ComponentType,
|
|
32
|
-
const FString& ComponentName, const FString& MeshType,
|
|
33
|
-
const TArray<float>& Location, const TArray<float>& Rotation,
|
|
34
|
-
const TArray<float>& Scale, const TSharedPtr<FJsonObject>& ComponentProperties);
|
|
35
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Json.h"
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Handler class for Blueprint-related MCP commands
|
|
8
|
+
*/
|
|
9
|
+
class FLOCKBAYMCP_API FUnrealMCPBlueprintCommands
|
|
10
|
+
{
|
|
11
|
+
public:
|
|
12
|
+
FUnrealMCPBlueprintCommands();
|
|
13
|
+
|
|
14
|
+
// Handle blueprint commands
|
|
15
|
+
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
+
|
|
17
|
+
private:
|
|
18
|
+
// Specific blueprint command handlers
|
|
19
|
+
TSharedPtr<FJsonObject> HandleCreateBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
+
TSharedPtr<FJsonObject> HandleAddComponentToBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
+
TSharedPtr<FJsonObject> HandleSetComponentProperty(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
+
TSharedPtr<FJsonObject> HandleSetPhysicsProperties(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
+
TSharedPtr<FJsonObject> HandleCompileBlueprint(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
+
TSharedPtr<FJsonObject> HandleCompileBlueprintsAll(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
+
TSharedPtr<FJsonObject> HandleSpawnBlueprintActor(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
+
TSharedPtr<FJsonObject> HandleSetBlueprintProperty(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
+
TSharedPtr<FJsonObject> HandleSetStaticMeshProperties(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
+
TSharedPtr<FJsonObject> HandleSetPawnProperties(const TSharedPtr<FJsonObject>& Params);
|
|
29
|
+
|
|
30
|
+
// Helper functions
|
|
31
|
+
TSharedPtr<FJsonObject> AddComponentToBlueprint(const FString& BlueprintName, const FString& ComponentType,
|
|
32
|
+
const FString& ComponentName, const FString& MeshType,
|
|
33
|
+
const TArray<float>& Location, const TArray<float>& Rotation,
|
|
34
|
+
const TArray<float>& Scale, const TSharedPtr<FJsonObject>& ComponentProperties);
|
|
35
|
+
};
|
|
@@ -1,30 +1,30 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Json.h"
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Handler class for Blueprint Node-related MCP commands
|
|
8
|
-
*/
|
|
9
|
-
class FLOCKBAYMCP_API FUnrealMCPBlueprintNodeCommands
|
|
10
|
-
{
|
|
11
|
-
public:
|
|
12
|
-
FUnrealMCPBlueprintNodeCommands();
|
|
13
|
-
|
|
14
|
-
// Handle blueprint node commands
|
|
15
|
-
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
-
|
|
17
|
-
private:
|
|
18
|
-
// Specific blueprint node command handlers
|
|
19
|
-
TSharedPtr<FJsonObject> HandleConnectBlueprintNodes(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintGetSelfComponentReference(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintGetComponentNode(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintEvent(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintFunctionCall(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintVariable(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintInputActionNode(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
-
TSharedPtr<FJsonObject> HandleAddBlueprintSelfReference(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
-
TSharedPtr<FJsonObject> HandleFindBlueprintNodes(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
-
TSharedPtr<FJsonObject> HandleSearchBlueprintFunctions(const TSharedPtr<FJsonObject>& Params);
|
|
29
|
-
TSharedPtr<FJsonObject> HandleResolveBlueprintFunction(const TSharedPtr<FJsonObject>& Params);
|
|
30
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Json.h"
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Handler class for Blueprint Node-related MCP commands
|
|
8
|
+
*/
|
|
9
|
+
class FLOCKBAYMCP_API FUnrealMCPBlueprintNodeCommands
|
|
10
|
+
{
|
|
11
|
+
public:
|
|
12
|
+
FUnrealMCPBlueprintNodeCommands();
|
|
13
|
+
|
|
14
|
+
// Handle blueprint node commands
|
|
15
|
+
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
+
|
|
17
|
+
private:
|
|
18
|
+
// Specific blueprint node command handlers
|
|
19
|
+
TSharedPtr<FJsonObject> HandleConnectBlueprintNodes(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintGetSelfComponentReference(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintGetComponentNode(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintEvent(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintFunctionCall(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintVariable(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintInputActionNode(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
+
TSharedPtr<FJsonObject> HandleAddBlueprintSelfReference(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
+
TSharedPtr<FJsonObject> HandleFindBlueprintNodes(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
+
TSharedPtr<FJsonObject> HandleSearchBlueprintFunctions(const TSharedPtr<FJsonObject>& Params);
|
|
29
|
+
TSharedPtr<FJsonObject> HandleResolveBlueprintFunction(const TSharedPtr<FJsonObject>& Params);
|
|
30
|
+
};
|
|
@@ -1,41 +1,41 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Dom/JsonObject.h"
|
|
5
|
-
|
|
6
|
-
struct FUnrealMCPParamSchema
|
|
7
|
-
{
|
|
8
|
-
FString Name;
|
|
9
|
-
FString Type;
|
|
10
|
-
bool bRequired = false;
|
|
11
|
-
FString Description;
|
|
12
|
-
TArray<FString> Aliases;
|
|
13
|
-
TArray<FString> EnumValues;
|
|
14
|
-
TMap<FString, FString> ValueAliases;
|
|
15
|
-
|
|
16
|
-
TSharedPtr<FJsonObject> ToJson() const;
|
|
17
|
-
};
|
|
18
|
-
|
|
19
|
-
struct FUnrealMCPCommandSchema
|
|
20
|
-
{
|
|
21
|
-
FString Command;
|
|
22
|
-
FString Title;
|
|
23
|
-
FString Description;
|
|
24
|
-
TArray<FUnrealMCPParamSchema> Params;
|
|
25
|
-
TSharedPtr<FJsonObject> ExampleParams;
|
|
26
|
-
|
|
27
|
-
TSharedPtr<FJsonObject> ToJson() const;
|
|
28
|
-
};
|
|
29
|
-
|
|
30
|
-
class FLOCKBAYMCP_API FUnrealMCPCommandSchemaRegistry
|
|
31
|
-
{
|
|
32
|
-
public:
|
|
33
|
-
static int32 SchemaVersion();
|
|
34
|
-
static const FUnrealMCPCommandSchema* FindSchema(const FString& CommandType);
|
|
35
|
-
static TArray<FString> GetSupportedCommands();
|
|
36
|
-
|
|
37
|
-
// Returns { success:false, error, details:{...} } on validation issues.
|
|
38
|
-
static bool NormalizeParams(const FString& CommandType, const TSharedPtr<FJsonObject>& InParams, TSharedPtr<FJsonObject>& OutParams, TSharedPtr<FJsonObject>& OutError);
|
|
39
|
-
static TSharedPtr<FJsonObject> GetSchemaResponse(const FString& CommandTypeOrEmpty);
|
|
40
|
-
static TSharedPtr<FJsonObject> GetCapabilitiesResponse();
|
|
41
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Dom/JsonObject.h"
|
|
5
|
+
|
|
6
|
+
struct FUnrealMCPParamSchema
|
|
7
|
+
{
|
|
8
|
+
FString Name;
|
|
9
|
+
FString Type;
|
|
10
|
+
bool bRequired = false;
|
|
11
|
+
FString Description;
|
|
12
|
+
TArray<FString> Aliases;
|
|
13
|
+
TArray<FString> EnumValues;
|
|
14
|
+
TMap<FString, FString> ValueAliases;
|
|
15
|
+
|
|
16
|
+
TSharedPtr<FJsonObject> ToJson() const;
|
|
17
|
+
};
|
|
18
|
+
|
|
19
|
+
struct FUnrealMCPCommandSchema
|
|
20
|
+
{
|
|
21
|
+
FString Command;
|
|
22
|
+
FString Title;
|
|
23
|
+
FString Description;
|
|
24
|
+
TArray<FUnrealMCPParamSchema> Params;
|
|
25
|
+
TSharedPtr<FJsonObject> ExampleParams;
|
|
26
|
+
|
|
27
|
+
TSharedPtr<FJsonObject> ToJson() const;
|
|
28
|
+
};
|
|
29
|
+
|
|
30
|
+
class FLOCKBAYMCP_API FUnrealMCPCommandSchemaRegistry
|
|
31
|
+
{
|
|
32
|
+
public:
|
|
33
|
+
static int32 SchemaVersion();
|
|
34
|
+
static const FUnrealMCPCommandSchema* FindSchema(const FString& CommandType);
|
|
35
|
+
static TArray<FString> GetSupportedCommands();
|
|
36
|
+
|
|
37
|
+
// Returns { success:false, error, details:{...} } on validation issues.
|
|
38
|
+
static bool NormalizeParams(const FString& CommandType, const TSharedPtr<FJsonObject>& InParams, TSharedPtr<FJsonObject>& OutParams, TSharedPtr<FJsonObject>& OutError);
|
|
39
|
+
static TSharedPtr<FJsonObject> GetSchemaResponse(const FString& CommandTypeOrEmpty);
|
|
40
|
+
static TSharedPtr<FJsonObject> GetCapabilitiesResponse();
|
|
41
|
+
};
|
|
@@ -1,59 +1,59 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Json.h"
|
|
5
|
-
|
|
6
|
-
// Forward declarations
|
|
7
|
-
class AActor;
|
|
8
|
-
class UBlueprint;
|
|
9
|
-
class UEdGraph;
|
|
10
|
-
class UEdGraphNode;
|
|
11
|
-
class UEdGraphPin;
|
|
12
|
-
class UK2Node_Event;
|
|
13
|
-
class UK2Node_CallFunction;
|
|
14
|
-
class UK2Node_VariableGet;
|
|
15
|
-
class UK2Node_VariableSet;
|
|
16
|
-
class UK2Node_InputAction;
|
|
17
|
-
class UK2Node_Self;
|
|
18
|
-
class UFunction;
|
|
19
|
-
|
|
20
|
-
/**
|
|
21
|
-
* Common utilities for UnrealMCP commands
|
|
22
|
-
*/
|
|
23
|
-
class FLOCKBAYMCP_API FUnrealMCPCommonUtils
|
|
24
|
-
{
|
|
25
|
-
public:
|
|
26
|
-
// JSON utilities
|
|
27
|
-
static TSharedPtr<FJsonObject> CreateErrorResponse(const FString& Message);
|
|
28
|
-
static TSharedPtr<FJsonObject> CreateSuccessResponse(const TSharedPtr<FJsonObject>& Data = nullptr);
|
|
29
|
-
static void GetIntArrayFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName, TArray<int32>& OutArray);
|
|
30
|
-
static void GetFloatArrayFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName, TArray<float>& OutArray);
|
|
31
|
-
static FVector2D GetVector2DFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
32
|
-
static FVector GetVectorFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
33
|
-
static FRotator GetRotatorFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
34
|
-
|
|
35
|
-
// Actor utilities
|
|
36
|
-
static TSharedPtr<FJsonValue> ActorToJson(AActor* Actor);
|
|
37
|
-
static TSharedPtr<FJsonObject> ActorToJsonObject(AActor* Actor, bool bDetailed = false);
|
|
38
|
-
|
|
39
|
-
// Blueprint utilities
|
|
40
|
-
static UBlueprint* FindBlueprint(const FString& BlueprintName);
|
|
41
|
-
static UBlueprint* FindBlueprintByName(const FString& BlueprintName);
|
|
42
|
-
static UEdGraph* FindOrCreateEventGraph(UBlueprint* Blueprint);
|
|
43
|
-
|
|
44
|
-
// Blueprint node utilities
|
|
45
|
-
static UK2Node_Event* CreateEventNode(UEdGraph* Graph, const FString& EventName, const FVector2D& Position);
|
|
46
|
-
static UK2Node_CallFunction* CreateFunctionCallNode(UEdGraph* Graph, UFunction* Function, const FVector2D& Position);
|
|
47
|
-
static UK2Node_VariableGet* CreateVariableGetNode(UEdGraph* Graph, UBlueprint* Blueprint, const FString& VariableName, const FVector2D& Position);
|
|
48
|
-
static UK2Node_VariableSet* CreateVariableSetNode(UEdGraph* Graph, UBlueprint* Blueprint, const FString& VariableName, const FVector2D& Position);
|
|
49
|
-
static UK2Node_InputAction* CreateInputActionNode(UEdGraph* Graph, const FString& ActionName, const FVector2D& Position);
|
|
50
|
-
static UK2Node_Self* CreateSelfReferenceNode(UEdGraph* Graph, const FVector2D& Position);
|
|
51
|
-
static bool ConnectGraphNodes(UEdGraph* Graph, UEdGraphNode* SourceNode, const FString& SourcePinName,
|
|
52
|
-
UEdGraphNode* TargetNode, const FString& TargetPinName);
|
|
53
|
-
static UEdGraphPin* FindPin(UEdGraphNode* Node, const FString& PinName, EEdGraphPinDirection Direction = EGPD_MAX);
|
|
54
|
-
static UK2Node_Event* FindExistingEventNode(UEdGraph* Graph, const FString& EventName);
|
|
55
|
-
|
|
56
|
-
// Property utilities
|
|
57
|
-
static bool SetObjectProperty(UObject* Object, const FString& PropertyName,
|
|
58
|
-
const TSharedPtr<FJsonValue>& Value, FString& OutErrorMessage);
|
|
59
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Json.h"
|
|
5
|
+
|
|
6
|
+
// Forward declarations
|
|
7
|
+
class AActor;
|
|
8
|
+
class UBlueprint;
|
|
9
|
+
class UEdGraph;
|
|
10
|
+
class UEdGraphNode;
|
|
11
|
+
class UEdGraphPin;
|
|
12
|
+
class UK2Node_Event;
|
|
13
|
+
class UK2Node_CallFunction;
|
|
14
|
+
class UK2Node_VariableGet;
|
|
15
|
+
class UK2Node_VariableSet;
|
|
16
|
+
class UK2Node_InputAction;
|
|
17
|
+
class UK2Node_Self;
|
|
18
|
+
class UFunction;
|
|
19
|
+
|
|
20
|
+
/**
|
|
21
|
+
* Common utilities for UnrealMCP commands
|
|
22
|
+
*/
|
|
23
|
+
class FLOCKBAYMCP_API FUnrealMCPCommonUtils
|
|
24
|
+
{
|
|
25
|
+
public:
|
|
26
|
+
// JSON utilities
|
|
27
|
+
static TSharedPtr<FJsonObject> CreateErrorResponse(const FString& Message);
|
|
28
|
+
static TSharedPtr<FJsonObject> CreateSuccessResponse(const TSharedPtr<FJsonObject>& Data = nullptr);
|
|
29
|
+
static void GetIntArrayFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName, TArray<int32>& OutArray);
|
|
30
|
+
static void GetFloatArrayFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName, TArray<float>& OutArray);
|
|
31
|
+
static FVector2D GetVector2DFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
32
|
+
static FVector GetVectorFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
33
|
+
static FRotator GetRotatorFromJson(const TSharedPtr<FJsonObject>& JsonObject, const FString& FieldName);
|
|
34
|
+
|
|
35
|
+
// Actor utilities
|
|
36
|
+
static TSharedPtr<FJsonValue> ActorToJson(AActor* Actor);
|
|
37
|
+
static TSharedPtr<FJsonObject> ActorToJsonObject(AActor* Actor, bool bDetailed = false);
|
|
38
|
+
|
|
39
|
+
// Blueprint utilities
|
|
40
|
+
static UBlueprint* FindBlueprint(const FString& BlueprintName);
|
|
41
|
+
static UBlueprint* FindBlueprintByName(const FString& BlueprintName);
|
|
42
|
+
static UEdGraph* FindOrCreateEventGraph(UBlueprint* Blueprint);
|
|
43
|
+
|
|
44
|
+
// Blueprint node utilities
|
|
45
|
+
static UK2Node_Event* CreateEventNode(UEdGraph* Graph, const FString& EventName, const FVector2D& Position);
|
|
46
|
+
static UK2Node_CallFunction* CreateFunctionCallNode(UEdGraph* Graph, UFunction* Function, const FVector2D& Position);
|
|
47
|
+
static UK2Node_VariableGet* CreateVariableGetNode(UEdGraph* Graph, UBlueprint* Blueprint, const FString& VariableName, const FVector2D& Position);
|
|
48
|
+
static UK2Node_VariableSet* CreateVariableSetNode(UEdGraph* Graph, UBlueprint* Blueprint, const FString& VariableName, const FVector2D& Position);
|
|
49
|
+
static UK2Node_InputAction* CreateInputActionNode(UEdGraph* Graph, const FString& ActionName, const FVector2D& Position);
|
|
50
|
+
static UK2Node_Self* CreateSelfReferenceNode(UEdGraph* Graph, const FVector2D& Position);
|
|
51
|
+
static bool ConnectGraphNodes(UEdGraph* Graph, UEdGraphNode* SourceNode, const FString& SourcePinName,
|
|
52
|
+
UEdGraphNode* TargetNode, const FString& TargetPinName);
|
|
53
|
+
static UEdGraphPin* FindPin(UEdGraphNode* Node, const FString& PinName, EEdGraphPinDirection Direction = EGPD_MAX);
|
|
54
|
+
static UK2Node_Event* FindExistingEventNode(UEdGraph* Graph, const FString& EventName);
|
|
55
|
+
|
|
56
|
+
// Property utilities
|
|
57
|
+
static bool SetObjectProperty(UObject* Object, const FString& PropertyName,
|
|
58
|
+
const TSharedPtr<FJsonValue>& Value, FString& OutErrorMessage);
|
|
59
|
+
};
|
|
@@ -1,61 +1,61 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Json.h"
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Handler class for Editor-related MCP commands
|
|
8
|
-
* Handles viewport control, actor manipulation, and level management
|
|
9
|
-
*/
|
|
10
|
-
class FLOCKBAYMCP_API FUnrealMCPEditorCommands
|
|
11
|
-
{
|
|
12
|
-
public:
|
|
13
|
-
FUnrealMCPEditorCommands();
|
|
14
|
-
|
|
15
|
-
// Handle editor commands
|
|
16
|
-
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
17
|
-
|
|
18
|
-
private:
|
|
19
|
-
// Actor manipulation commands
|
|
20
|
-
TSharedPtr<FJsonObject> HandleGetActorsInLevel(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
-
TSharedPtr<FJsonObject> HandleFindActorsByName(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
-
TSharedPtr<FJsonObject> HandleSpawnActor(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
-
TSharedPtr<FJsonObject> HandleCreateLandscape(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
-
TSharedPtr<FJsonObject> HandleDeleteActor(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
-
TSharedPtr<FJsonObject> HandleSetActorTransform(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
-
TSharedPtr<FJsonObject> HandleGetActorProperties(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
-
TSharedPtr<FJsonObject> HandleSetActorProperty(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
-
|
|
29
|
-
// Blueprint actor spawning
|
|
30
|
-
TSharedPtr<FJsonObject> HandleSpawnBlueprintActor(const TSharedPtr<FJsonObject>& Params);
|
|
31
|
-
|
|
32
|
-
// Editor viewport commands
|
|
33
|
-
TSharedPtr<FJsonObject> HandleFocusViewport(const TSharedPtr<FJsonObject>& Params);
|
|
34
|
-
TSharedPtr<FJsonObject> HandleTakeScreenshot(const TSharedPtr<FJsonObject>& Params);
|
|
35
|
-
|
|
36
|
-
// Editor save commands
|
|
37
|
-
TSharedPtr<FJsonObject> HandleSaveAll(const TSharedPtr<FJsonObject>& Params);
|
|
38
|
-
|
|
39
|
-
// Editor play/preview commands
|
|
40
|
-
TSharedPtr<FJsonObject> HandleGetPlayInEditorStatus(const TSharedPtr<FJsonObject>& Params);
|
|
41
|
-
TSharedPtr<FJsonObject> HandlePlayInEditor(const TSharedPtr<FJsonObject>& Params);
|
|
42
|
-
TSharedPtr<FJsonObject> HandlePlayInEditorWindowed(const TSharedPtr<FJsonObject>& Params);
|
|
43
|
-
TSharedPtr<FJsonObject> HandleStopPlayInEditor(const TSharedPtr<FJsonObject>& Params);
|
|
44
|
-
|
|
45
|
-
// Asset discovery + placement
|
|
46
|
-
TSharedPtr<FJsonObject> HandleSearchAssets(const TSharedPtr<FJsonObject>& Params);
|
|
47
|
-
TSharedPtr<FJsonObject> HandleGetAssetInfo(const TSharedPtr<FJsonObject>& Params);
|
|
48
|
-
TSharedPtr<FJsonObject> HandleListAssetPacks(const TSharedPtr<FJsonObject>& Params);
|
|
49
|
-
TSharedPtr<FJsonObject> HandlePlaceAsset(const TSharedPtr<FJsonObject>& Params);
|
|
50
|
-
|
|
51
|
-
// Verify (editor diagnostics)
|
|
52
|
-
TSharedPtr<FJsonObject> HandleMapCheck(const TSharedPtr<FJsonObject>& Params);
|
|
53
|
-
|
|
54
|
-
// Context + spatial primitives
|
|
55
|
-
TSharedPtr<FJsonObject> HandleGetEditorContext(const TSharedPtr<FJsonObject>& Params);
|
|
56
|
-
TSharedPtr<FJsonObject> HandleGetPlayerContext(const TSharedPtr<FJsonObject>& Params);
|
|
57
|
-
TSharedPtr<FJsonObject> HandleRaycastFromCamera(const TSharedPtr<FJsonObject>& Params);
|
|
58
|
-
TSharedPtr<FJsonObject> HandleRaycastDown(const TSharedPtr<FJsonObject>& Params);
|
|
59
|
-
TSharedPtr<FJsonObject> HandleGetActorTransform(const TSharedPtr<FJsonObject>& Params);
|
|
60
|
-
TSharedPtr<FJsonObject> HandleGetActorBounds(const TSharedPtr<FJsonObject>& Params);
|
|
61
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Json.h"
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Handler class for Editor-related MCP commands
|
|
8
|
+
* Handles viewport control, actor manipulation, and level management
|
|
9
|
+
*/
|
|
10
|
+
class FLOCKBAYMCP_API FUnrealMCPEditorCommands
|
|
11
|
+
{
|
|
12
|
+
public:
|
|
13
|
+
FUnrealMCPEditorCommands();
|
|
14
|
+
|
|
15
|
+
// Handle editor commands
|
|
16
|
+
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
17
|
+
|
|
18
|
+
private:
|
|
19
|
+
// Actor manipulation commands
|
|
20
|
+
TSharedPtr<FJsonObject> HandleGetActorsInLevel(const TSharedPtr<FJsonObject>& Params);
|
|
21
|
+
TSharedPtr<FJsonObject> HandleFindActorsByName(const TSharedPtr<FJsonObject>& Params);
|
|
22
|
+
TSharedPtr<FJsonObject> HandleSpawnActor(const TSharedPtr<FJsonObject>& Params);
|
|
23
|
+
TSharedPtr<FJsonObject> HandleCreateLandscape(const TSharedPtr<FJsonObject>& Params);
|
|
24
|
+
TSharedPtr<FJsonObject> HandleDeleteActor(const TSharedPtr<FJsonObject>& Params);
|
|
25
|
+
TSharedPtr<FJsonObject> HandleSetActorTransform(const TSharedPtr<FJsonObject>& Params);
|
|
26
|
+
TSharedPtr<FJsonObject> HandleGetActorProperties(const TSharedPtr<FJsonObject>& Params);
|
|
27
|
+
TSharedPtr<FJsonObject> HandleSetActorProperty(const TSharedPtr<FJsonObject>& Params);
|
|
28
|
+
|
|
29
|
+
// Blueprint actor spawning
|
|
30
|
+
TSharedPtr<FJsonObject> HandleSpawnBlueprintActor(const TSharedPtr<FJsonObject>& Params);
|
|
31
|
+
|
|
32
|
+
// Editor viewport commands
|
|
33
|
+
TSharedPtr<FJsonObject> HandleFocusViewport(const TSharedPtr<FJsonObject>& Params);
|
|
34
|
+
TSharedPtr<FJsonObject> HandleTakeScreenshot(const TSharedPtr<FJsonObject>& Params);
|
|
35
|
+
|
|
36
|
+
// Editor save commands
|
|
37
|
+
TSharedPtr<FJsonObject> HandleSaveAll(const TSharedPtr<FJsonObject>& Params);
|
|
38
|
+
|
|
39
|
+
// Editor play/preview commands
|
|
40
|
+
TSharedPtr<FJsonObject> HandleGetPlayInEditorStatus(const TSharedPtr<FJsonObject>& Params);
|
|
41
|
+
TSharedPtr<FJsonObject> HandlePlayInEditor(const TSharedPtr<FJsonObject>& Params);
|
|
42
|
+
TSharedPtr<FJsonObject> HandlePlayInEditorWindowed(const TSharedPtr<FJsonObject>& Params);
|
|
43
|
+
TSharedPtr<FJsonObject> HandleStopPlayInEditor(const TSharedPtr<FJsonObject>& Params);
|
|
44
|
+
|
|
45
|
+
// Asset discovery + placement
|
|
46
|
+
TSharedPtr<FJsonObject> HandleSearchAssets(const TSharedPtr<FJsonObject>& Params);
|
|
47
|
+
TSharedPtr<FJsonObject> HandleGetAssetInfo(const TSharedPtr<FJsonObject>& Params);
|
|
48
|
+
TSharedPtr<FJsonObject> HandleListAssetPacks(const TSharedPtr<FJsonObject>& Params);
|
|
49
|
+
TSharedPtr<FJsonObject> HandlePlaceAsset(const TSharedPtr<FJsonObject>& Params);
|
|
50
|
+
|
|
51
|
+
// Verify (editor diagnostics)
|
|
52
|
+
TSharedPtr<FJsonObject> HandleMapCheck(const TSharedPtr<FJsonObject>& Params);
|
|
53
|
+
|
|
54
|
+
// Context + spatial primitives
|
|
55
|
+
TSharedPtr<FJsonObject> HandleGetEditorContext(const TSharedPtr<FJsonObject>& Params);
|
|
56
|
+
TSharedPtr<FJsonObject> HandleGetPlayerContext(const TSharedPtr<FJsonObject>& Params);
|
|
57
|
+
TSharedPtr<FJsonObject> HandleRaycastFromCamera(const TSharedPtr<FJsonObject>& Params);
|
|
58
|
+
TSharedPtr<FJsonObject> HandleRaycastDown(const TSharedPtr<FJsonObject>& Params);
|
|
59
|
+
TSharedPtr<FJsonObject> HandleGetActorTransform(const TSharedPtr<FJsonObject>& Params);
|
|
60
|
+
TSharedPtr<FJsonObject> HandleGetActorBounds(const TSharedPtr<FJsonObject>& Params);
|
|
61
|
+
};
|
|
@@ -1,20 +1,20 @@
|
|
|
1
|
-
#pragma once
|
|
2
|
-
|
|
3
|
-
#include "CoreMinimal.h"
|
|
4
|
-
#include "Json.h"
|
|
5
|
-
|
|
6
|
-
/**
|
|
7
|
-
* Handler class for Project-wide MCP commands
|
|
8
|
-
*/
|
|
9
|
-
class FLOCKBAYMCP_API FUnrealMCPProjectCommands
|
|
10
|
-
{
|
|
11
|
-
public:
|
|
12
|
-
FUnrealMCPProjectCommands();
|
|
13
|
-
|
|
14
|
-
// Handle project commands
|
|
15
|
-
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
-
|
|
17
|
-
private:
|
|
18
|
-
// Specific project command handlers
|
|
19
|
-
TSharedPtr<FJsonObject> HandleCreateInputMapping(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
-
};
|
|
1
|
+
#pragma once
|
|
2
|
+
|
|
3
|
+
#include "CoreMinimal.h"
|
|
4
|
+
#include "Json.h"
|
|
5
|
+
|
|
6
|
+
/**
|
|
7
|
+
* Handler class for Project-wide MCP commands
|
|
8
|
+
*/
|
|
9
|
+
class FLOCKBAYMCP_API FUnrealMCPProjectCommands
|
|
10
|
+
{
|
|
11
|
+
public:
|
|
12
|
+
FUnrealMCPProjectCommands();
|
|
13
|
+
|
|
14
|
+
// Handle project commands
|
|
15
|
+
TSharedPtr<FJsonObject> HandleCommand(const FString& CommandType, const TSharedPtr<FJsonObject>& Params);
|
|
16
|
+
|
|
17
|
+
private:
|
|
18
|
+
// Specific project command handlers
|
|
19
|
+
TSharedPtr<FJsonObject> HandleCreateInputMapping(const TSharedPtr<FJsonObject>& Params);
|
|
20
|
+
};
|