<ui:UXML xmlns:ui="UnityEngine.UIElements" xmlns:uie="UnityEditor.UIElements" xsi="http://www.w3.org/2001/XMLSchema-instance" engine="UnityEngine.UIElements" editor="UnityEditor.UIElements" noNamespaceSchemaLocation="../../../../../UIElementsSchema/UIElements.xsd" editor-extension-mode="False">
<ui:ScrollView>
<ui:VisualElement class="container" style="min-width: 320px;">
<!-- Header Section -->
<ui:Box name="contHeader" style="background-color: rgba(222, 222, 222, 0); flex-direction: row; flex-shrink: 0;">
<ui:VisualElement style="flex-grow: 1; background-color: rgba(0, 0, 0, 0);">
<ui:EnumField label="Log Level" name="dropdownLogLevel" type="com.IvanMurzak.Unity.MCP.Runtime.Utils.LogLevel, com.IvanMurzak.Unity.MCP.Runtime" value="Warning" class="content-item" style="align-self: flex-start;" />
<ui:IntegerField label="Timeout (ms)" name="inputTimeoutMs" value="10000" class="content-item" style="align-self: flex-start;" />
<ui:TextField picking-mode="Ignore" label="Version" value="0.0.0" readonly="true" name="currentVersion" focusable="false" class="content-item transparent-text-field" style="align-self: flex-start;" />
</ui:VisualElement>
<ui:VisualElement name="imgLogoPivot" class="animated-selectable" style="flex-grow: 0; height: 60px; width: 60px; right: 0; margin-left: 15px; flex-shrink: 0; margin-right: 0px; margin-top: 2px; flex-direction: row;">
<ui:VisualElement name="imgLogo" style="flex-grow: 1; background-color: rgba(0, 0, 0, 0); background-image: url("project://database/Assets/root/Editor/Gizmos/logo_512.png?fileID=2800000&guid=bbb0f64bd8f15164781e01168cd6fa4f&type=3#logo_512"); -unity-background-scale-mode: stretch-to-fill; align-self: stretch;" />
</ui:VisualElement>
</ui:Box>
<ui:VisualElement class="divider" />
<!-- Connection Section ============================== -->
<ui:Label text="Connection" class="header" />
<ui:TextField picking-mode="Ignore" label="Server URL" value="http://localhost:8080" name="InputServerURL" tooltip="Connection URL to an MCP server. Default value: http://localhost:8080" class="content-item" />
<ui:Foldout text="Information" value="false" class="base-foldout">
<ui:Label text="Usually the server is hosted locally at: http://localhost:8080 But feel free to connect to remote MCP server if needed. The connection under the hood is established using SignalR and supports wide range of features." class="section-desc" />
</ui:Foldout>
<!-- Connection Timeline -->
<ui:VisualElement name="ConnectionTimeline" class="connection-timeline">
<!-- Point 1: Unity -->
<ui:VisualElement name="TimelinePointUnity" class="timeline-point">
<ui:VisualElement class="timeline-indicator">
<ui:VisualElement name="connectionStatusCircle" class="status-indicator-circle status-indicator-circle-disconnected" />
<ui:VisualElement class="timeline-line" />
</ui:VisualElement>
<ui:VisualElement class="timeline-content">
<ui:Label text="Unity" name="connectionStatusText" class="timeline-label" />
<ui:Button name="btnConnectOrDisconnect" text="Connect" class="btn-primary timeline-btn" />
</ui:VisualElement>
</ui:VisualElement>
<!-- Point 2: MCP Server -->
<ui:VisualElement name="TimelinePointMcpServer" class="timeline-point">
<ui:VisualElement class="timeline-indicator">
<ui:VisualElement name="mcpServerStatusCircle" class="status-indicator-circle status-indicator-circle-disconnected" />
<ui:VisualElement class="timeline-line" />
</ui:VisualElement>
<ui:VisualElement class="timeline-content">
<ui:Label text="MCP server" name="mcpServerLabel" class="timeline-label" />
<ui:Button name="btnStartStopServer" text="Start" class="btn-secondary timeline-btn" />
</ui:VisualElement>
</ui:VisualElement>
<!-- Point 3: AI Agent -->
<ui:VisualElement name="TimelinePointAiAgent" class="timeline-point timeline-point-last">
<ui:VisualElement class="timeline-indicator">
<ui:VisualElement name="aiAgentStatusCircle" class="status-indicator-circle status-indicator-circle-disconnected" />
</ui:VisualElement>
<ui:VisualElement class="timeline-content">
<ui:Label text="AI agent" name="aiAgentLabel" class="timeline-label" />
</ui:VisualElement>
</ui:VisualElement>
</ui:VisualElement>
<ui:VisualElement class="divider" />
<!-- AI Agent Section ============================== -->
<ui:VisualElement class="row" style="margin-top: 0;">
<ui:Label text="AI agent" class="header" />
<!-- Transport mode toggle -->
<ui:VisualElement style="flex-direction: row; margin-top: 4px;">
<ui:Toggle name="toggleOptionHttp" label="http" class="toggle-text-button" tooltip="Configure AI agent to communicate over HTTP (RECOMMENDED)" />
<ui:Toggle name="toggleOptionStdio" label="stdio" class="toggle-text-button" tooltip="Configure AI agent to communicate over STDIO (NOT RECOMMENDED)" />
</ui:VisualElement>
</ui:VisualElement>
<ui:DropdownField name="aiAgentDropdown" label="Choose" class="content-item" />
<ui:VisualElement name="ConfigureAgentsContainer" />
<ui:VisualElement class="divider" />
<!-- MCP features section ============================== -->
<!-- Tools Configuration Section -->
<ui:VisualElement name="ToolsConfigurationSection">
<ui:VisualElement class="row-top">
<ui:VisualElement style="flex-direction: column;">
<ui:Label name="toolsCountLabel" text="0 / 0 tools" class="header" />
<ui:Label name="toolsTokenCountLabel" text="~0 tokens total" tooltip="Total tokens consumed by active tools in the AI context. Fewer tokens means more free context for AI to reason, leading to better and more accurate responses. Disable unused tools to reduce token usage." style="font-size: 11px; color: rgb(150, 150, 150); margin-top: 2px;" />
</ui:VisualElement>
<ui:Button name="btnOpenTools" text="Open" class="btn-secondary" />
</ui:VisualElement>
<ui:Foldout text="Information" value="false" class="base-foldout">
<ui:Label name="toolsStatusLabel" text="AI uses tools to achieve user's request. This is the main AI's instrument for doing everything. Active tools spend AI context. You want to keep the context consumption smaller, because AI works better when there is more free context. Consider disabling the tools you don't need." class="section-desc" />
</ui:Foldout>
</ui:VisualElement>
<ui:VisualElement class="divider" />
<!-- Prompts Configuration Section -->
<ui:VisualElement name="PromptsConfigurationSection">
<ui:VisualElement class="row-top">
<ui:Label name="promptsCountLabel" text="0 / 0 prompts" class="header" />
<ui:Button name="btnOpenPrompts" text="Open" class="btn-secondary" />
</ui:VisualElement>
<ui:Foldout text="Information" value="false" class="base-foldout">
<ui:Label name="promptsStatusLabel" text="Prompt is a command that user may use in MCP client. For example '/createGameObject'. The command may receive input arguments. The result of the command execution is the Prompt text message which injects into AI context and tells AI what to do. Prompt doesn't spent context memory. It only spends context when injected by a user action." class="section-desc" />
</ui:Foldout>
</ui:VisualElement>
<ui:VisualElement class="divider" />
<!-- Resources Configuration Section -->
<ui:VisualElement name="ResourcesConfigurationSection">
<ui:VisualElement class="row-top">
<ui:Label name="resourcesCountLabel" text="0 / 0 resources" class="header" />
<ui:Button name="btnOpenResources" text="Open" class="btn-secondary" />
</ui:VisualElement>
<ui:Foldout text="Information" value="false" class="base-foldout">
<ui:Label name="resourcesStatusLabel" text="Resources provide read-only data that AI can access to understand your Unity project. They expose information like scene hierarchy, asset metadata, project settings, and more. Unlike tools which perform actions, resources give AI contextual awareness without modifying anything. Resources are fetched on-demand when AI needs specific information." class="section-desc" />
</ui:Foldout>
</ui:VisualElement>
<ui:VisualElement class="divider" />
<!-- Support Section ============================== -->
<ui:VisualElement>
<ui:VisualElement>
<ui:Label text="Found an issue?" class="section-text" style="flex-grow: 1;" />
</ui:VisualElement>
<ui:VisualElement class="row-left-align">
<ui:Button name="btnDiscordHelp" class="btn-secondary btn-with-icon">
<ui:VisualElement name="btnDiscordHelpIcon" class="btn-icon" />
<ui:Label text="Help / Talk" class="btn-label" />
</ui:Button>
<ui:Button name="btnGitHubIssue" class="btn-secondary btn-with-icon">
<ui:VisualElement name="btnGitHubIssueIcon" class="btn-icon" />
<ui:Label text="Bug Report" class="btn-label" />
</ui:Button>
<ui:Button name="btnCheckSerialization" text="Check" class="btn-secondary" />
</ui:VisualElement>
</ui:VisualElement>
<ui:VisualElement class="divider" />
<!-- Thanks Section ============================== -->
<ui:VisualElement>
<ui:Label text="Thanks for using <b><color=red>AI</color> Game Developer</b>. If you like it, please give the project a star on GitHub. Sincerely, Ivan Murzak" class="section-text" />
<ui:Button name="btnGitHubStar" class="btn-secondary btn-with-icon btn-golden btn-floating">
<ui:VisualElement name="btnGitHubStarIcon" class="btn-icon" />
<ui:Label text="GitHub Star" class="btn-label" />
</ui:Button>
</ui:VisualElement>
</ui:VisualElement>
</ui:ScrollView>
</ui:UXML>