Feature Request: Unity Profiler Integration
Hi! I've been using unityctl extensively for automating Unity Editor workflows from Claude Code — it's been incredibly useful for compiling, taking snapshots, running tests, and controlling play mode.
One area where I frequently hit a wall is performance profiling. When investigating frame drops or CPU spikes, I currently have to leave the CLI workflow and manually inspect the Unity Profiler window.
What would be helpful
Being able to read profiler data through unityctl, for example:
unityctl profiler capture — Capture a profiler frame or a range of frames
unityctl profiler hierarchy — Read the CPU profiler hierarchy (method names, self/total time, call counts) for the current or a specific frame
unityctl profiler stats — Summary stats (FPS, draw calls, batches, memory) for a frame range
unityctl profiler markers — List profiler markers/samples in a frame
Why this matters for agent workflows
Agents like Claude Code can already identify what to investigate (e.g., a scene loads slowly, a specific interaction causes a hitch), but without profiler access they can't see where the time is spent. Being able to read the profiler hierarchy would close the loop — an agent could profile, identify the hot path, and suggest or apply a fix in one session.
Unity API surface
Unity exposes profiler data through:
UnityEditorInternal.ProfilerDriver — frame data access
Unity.Profiling.LowLevel.Unsafe.ProfilerRecorder — runtime counters
UnityEditor.Profiling.HierarchyFrameDataView — hierarchy tree traversal
These could potentially be wrapped into unityctl commands.
Thanks for building this tool — it's made a real difference in how efficiently I can work with Unity projects!
Feature Request: Unity Profiler Integration
Hi! I've been using unityctl extensively for automating Unity Editor workflows from Claude Code — it's been incredibly useful for compiling, taking snapshots, running tests, and controlling play mode.
One area where I frequently hit a wall is performance profiling. When investigating frame drops or CPU spikes, I currently have to leave the CLI workflow and manually inspect the Unity Profiler window.
What would be helpful
Being able to read profiler data through unityctl, for example:
unityctl profiler capture— Capture a profiler frame or a range of framesunityctl profiler hierarchy— Read the CPU profiler hierarchy (method names, self/total time, call counts) for the current or a specific frameunityctl profiler stats— Summary stats (FPS, draw calls, batches, memory) for a frame rangeunityctl profiler markers— List profiler markers/samples in a frameWhy this matters for agent workflows
Agents like Claude Code can already identify what to investigate (e.g., a scene loads slowly, a specific interaction causes a hitch), but without profiler access they can't see where the time is spent. Being able to read the profiler hierarchy would close the loop — an agent could profile, identify the hot path, and suggest or apply a fix in one session.
Unity API surface
Unity exposes profiler data through:
UnityEditorInternal.ProfilerDriver— frame data accessUnity.Profiling.LowLevel.Unsafe.ProfilerRecorder— runtime countersUnityEditor.Profiling.HierarchyFrameDataView— hierarchy tree traversalThese could potentially be wrapped into unityctl commands.
Thanks for building this tool — it's made a real difference in how efficiently I can work with Unity projects!