v0.4.9
Added
- Added 13 Profiler tools (category
Profiler):profiler_start/profiler_stop/profiler_statusfor session control;get_frame_timing/get_countersfor CPU/GPU frame timing and persistentProfilerRecordercounters;get_object_memoryfor per-asset/GameObject runtime memory footprint;get_top_memory_objectsfor ranking ALL loaded objects of a type by memory (the "which objects are consuming it" follow-up to a snapshot diff);memory_take_snapshot/memory_list_snapshots/memory_compare_snapshotsfor lightweight aggregate memory snapshots (not real.snapfiles);frame_debugger_enable/frame_debugger_disable/frame_debugger_get_eventsfor driving the Frame Debugger via reflection. See PROFILER_TOOLS.md for the full reference, implementation notes, known limitations, and test report. - Added prefab stage editing tools:
open_prefab_stageopens a prefab asset in Prefab Mode for isolated editing (hierarchy/component tools andexecute_codethen operate on the prefab contents),save_prefab_stagepersists edits back to the.prefabasset without closing, andclose_prefab_stagereturns to the main stage with an explicit save/discard choice. Closing clears the stage's dirty flag first so a blocking "save changes?" modal can never stall the MCP request. get_console_logsgained two optional parameters:group_duplicatescollapses repeated identical messages into one "message (xN)" line (in a real project this compacted 100 cached entries down to 20 unique lines, keeping spammy Animator warnings from drowning out unique entries), andfilter_textfilters entries by a case-insensitive substring. Both apply to the cache and console read paths; default behavior is unchanged.- Added ScriptableObject asset tools:
create_scriptable_objectcreates a new asset of any ScriptableObject-derived type,get_scriptable_objectreads all serialized properties (including[SerializeField]private fields), andset_scriptable_object_propertieswrites fields with a per-field success report and persists viaSaveAssetIfDirty. Reuses the component property machinery (ComponentSerializersignatures widened fromComponenttoUnityEngine.Object, source-compatible for existing callers). - Added Animator runtime control tools:
get_animator_statereads the current state (state name resolved from the controller when possible, including through AnimatorOverrideController) plus all parameters with current values;set_animator_parametersets a parameter by name with automatic Float/Int/Bool/Trigger type detection;play_animator_stateplays a named state and force-evaluates the animator once in Edit Mode so poses apply without entering Play Mode (useful for driving UI to a known state before a screenshot). - Added Unity Test Runner integration with an async job pattern:
run_testsstarts an EditMode/PlayMode run (with optional test/category/assembly filters) and returns a job id immediately;get_test_jobpolls progress (completed/total) and final results (pass/fail/skip counts plus failure messages and truncated stack traces);cancel_test_runcancels a stuck run (requires com.unity.test-framework 1.3+, resolved by reflection and reported as unsupported on the 1.1.x that Unity 2022.3 bundles). Job state lives in SessionState and the results callback re-registers on every domain load, so PlayMode runs that reload the domain mid-run still report completion. - Declared
capabilities.tools.listChangedin theinitializeresponse and implemented lazynotifications/tools/list_changeddelivery: when the exposed tool set changes (Tool Exposure save, newly registered tools after a recompile), the next client request that acceptstext/event-streamreceives an SSE response carrying the notification before the JSON-RPC result, so MCP clients such as Claude Code refresh their tool list without a session restart. Supported on both the direct HTTP transport and broker mode (broker protocol v2 with Accept/Content-Type passthrough).
Changed
-
MCP Server panel UX improvements to the transport/broker controls:
- The transport selector is now a "Transport Mode" dropdown (
Direct HTTP (default)/Broker Mode (Experimental)) instead of a checkbox, so the two transports read as an explicit mutually-exclusive choice instead of an on/off flag. - The "Broker Mono Path" field now shows the real effect of the "leave empty to auto-detect" default instead of always rendering blank: when no override is set, the field displays the actually auto-detected Mono executable path (display-only — it does not persist as an override), and if auto-detection fails, the field stays empty and a red inline hint explains that broker mode needs the path set manually.
Behavior, defaults, and the underlying settings are unchanged — both are presentation-only improvements.
- The transport selector is now a "Transport Mode" dropdown (
Fixed
- Broker manager now gracefully shuts down a stale broker process that no longer passes the health probe (typically a protocol-version mismatch after a package upgrade) instead of leaving it holding the port and failing the server with "Address already in use".
- A failure while handling a single broker-delivered request no longer terminates the broker poll loop (which previously left all subsequent requests queued forever).
- Fixed a broker process leak when the Server Port setting changes while broker mode is active:
MCPBrokerProcessManager.EnsureRunningonly shut down the previously recorded broker process when its recorded port matched the newly requested port, so changing the port left the old broker orphaned (and deleted its pid file, making it unrecoverable by any later cleanup) while a fresh broker started on the new port. The stale-broker shutdown now runs regardless of whether the port changed. - The "Server Port" field now commits on Enter/blur rather than per keystroke, so the settings-change restart path runs once per committed value instead of once per typed digit. The restart scheduler also uses editor-update fallbacks alongside
delayCallfor both stop and start phases, so port changes made from tools or non-IMGUI callbacks cannot get stuck with a scheduled-but-never-run restart. - Fixed
get_performance_snapshotandanalyze_scene_complexityunder-reporting scene stats in multi-scene projects. Both tools sourced root GameObjects fromSceneManager.GetActiveScene()only, silently excluding any additively loaded scenes (e.g. a bootstrap scene loading a content scene on top); they now walk every loaded scene viaSceneManager.sceneCount/GetSceneAt, and the "Scene:" summary line is renamed "Scene(s):" to list every scene that was counted. - Fixed
get_hierarchyandget_scene_infosilently omitting additively loaded scenes: both sourced content fromSceneManager.GetActiveScene()only, so in multi-scene projects (e.g. a bootstrap scene additively loading a content scene) everything outside the active scene was invisible. Both tools now walk every loaded scene, label each as(active)/(additive), andget_hierarchy'sroot_nameinactive-object search fallback also spans all loaded scenes. get_console_logsnow truncates each emitted line to 300 characters (annotated with the remaining length). A single log entry containing a huge one-line payload (observed in the wild: an entire 280KB save-file JSON logged to the console) previously blew up the whole tool response.