21 KiB
Changelog
All notable changes to Codely Bridge will be documented in this file.
[1.0.23] - 2026-02-25
Changed
- UI
- Codely bridge 页面改版
[1.0.22] - 2026-02-11
Enhanced
- ExecuteCSharpScript
- Added Unity.InputSystem assembly support for C# script execution
- Scripts can now access Input System types and APIs when the package is installed
[1.0.21] - 2026-02-06
Changed
- Batch Operations Refactoring
- Split generic
batchaction into two distinct operations:create_batchfor write-only deterministic sequences andedit_batchfor search-then-write edits - Added
HandleCreateBatchmethod for write-only deterministic batch operations - Added
HandleEditBatchmethod for search-then-write batch operations with captureAs support - Improved code clarity and prevented mixed read/write batch states
- Maintained parity with TypeScript client schema
- Added backward compatibility aliases for snake_case to camelCase parameters
- Updated ValidActions list to include new batch operation types
- Updated writeActions array to include new batch operations for state validation
- Split generic
Enhanced
-
ManageAsset
- Enhanced batch operation handling with clearer separation of concerns
- Improved parameter naming consistency with backward compatibility support
-
ManageGameObject
- Enhanced batch operation handling with clearer separation of concerns
- Improved parameter naming consistency with backward compatibility support
Test Coverage
- Updated
unity_asset_full_coverage.mdto reflect new batch operations - Updated
unity_gameobject_full_coverage.mdto reflect new batch operations - Updated
unity_workflow_full_coverage.mdwith refined batch operation workflows - Updated
Tests/Coverage/README.mddocumentation
[1.0.20] - 2026-02-05
Fixed
- TCP Port Management on macOS
- Disabled ReuseAddress socket option on macOS in PortManager.cs
[1.0.19] - 2026-02-04
Fixed
- TCP Port Management on macOS
- Disabled ReuseAddress socket option on macOS to prevent multiple Unity instances from listening on the same port
- Ensures proper port exclusivity across Unity Editor instances
[1.0.18] - 2026-02-04
Fixed
- TCP Connection Reliability
- Add LingerState to test listener to send RST on close (same as actual listener)
- Increase immediate retry attempts from 3 to 5
- Increase retry sleep time from 75ms to 150ms
- Extend wait time on Windows from 100ms to 500ms to allow TCP port full release
[1.0.17] - 2026-02-03
Fixed
- Revert IPV6 Loopback Support
[1.0.16] - 2026-02-03
Added
- C# Script Execution
- New
ExecuteCSharpScripttool for executing arbitrary C# code at runtime using Microsoft.CodeAnalysis.CSharp.Scripting (Roslyn compiler services) - Captures and returns Unity console logs during script execution
- Supports custom using directives and assembly references
- Enables dynamic C# code execution without requiring editor restart or recompilation
- Added bundled Roslyn assemblies:
Codely.Microsoft.CodeAnalysis.dll,Codely.Microsoft.CodeAnalysis.CSharp.dll,Codely.Microsoft.CodeAnalysis.Scripting.dll,Codely.Microsoft.CodeAnalysis.CSharp.Scripting.dll - Added supporting assemblies:
Codely.System.Collections.Immutable.dll,Codely.System.Reflection.Metadata.dll,Codely.System.Runtime.CompilerServices.Unsafe.dll
- New
Fixed
- UnityTcpBridge
- Reverted accidental handshake string change that broke package functionality (changed from incorrect 'WELCOME UNITY-TCP 1 FRAMING=1' back to correct 'WELCOME Codely-Bridge 1 FRAMING=1')
- Add IPV6 Loopback Support
Changed
-
Branding & Menu Structure
- Renamed "Unity TCP" to "Codely Bridge" across logging and port management
- Simplified menu structure: removed redundant menu items and kept only "Window/Codely Bridge/Control Window"
- Updated menu organization for better user experience
-
CI/CD
- Updated register_version job rules in CI pipeline
[1.0.15] - 2026-01-29
Changed
-
ManageScreenshot
- Simplified screenshot API: removed redundant
capture_game_viewaction; its behavior is now covered by the unifiedcaptureaction captureaction now consistently uses GameView reflection to capture what the user sees in both edit and play modes- Removed redundant
FlipTextureVerticallycall and related comments for clearer, more maintainable code
- Simplified screenshot API: removed redundant
-
Package Publishing
- Updated
.npmignoreto includeTests/directory in the published npm package so consumers can run and extend the test suite
- Updated
Fixed
- Screenshot Capture
- Fixed vertical flip of textures captured from RenderTexture so screenshots match on-screen orientation
Test Coverage
- Updated
unity_screenshot_full_coverage.mdandTests/Coverage/README.mdto reflect the simplified screenshot API and current test structure
[1.0.14] - 2026-01-22
Changed
-
Dependency Management
- Swapped to bundled
Codely.Newtonsoft.Json.dllinPlugins/directory instead of externalNewtonsoft.Jsonpackage - Removed external
Newtonsoft.Jsondependency frompackage.json - Updated all code references to use bundled Newtonsoft.Json assembly
- Swapped to bundled
-
Architecture
- Moved runtime implementation code from
Runtime/toEditor/scope to align with Unity usage patterns
- Moved runtime implementation code from
Added
-
Package Publishing
- Added
.npmignorefile to exclude unwanted files from npm publication - Excludes CI/CD configuration, build artifacts, Git metadata, IDE files, and test directories
- Ensures only essential code and documentation are published to npm registry
- Added
-
CI/CD Pipeline
- Added automated npm pack and TOS (Tencent Object Storage) upload steps to deployment pipelines
- Added backup version (1.0.0) upload for both staging and production environments
- Improved deployment reliability with fallback version availability
[1.0.13] - 2026-01-20
Fixed
- Test Assembly Dependencies
- Fixed missing
Newtonsoft.Json.dllreference inUnityTcp.Editor.Tests.asmdef - Added
com.unity.ext.nunitpackage dependency topackage.jsonfor proper NUnit framework support - Ensures test assembly can properly reference required dependencies for compilation
- Fixed missing
[1.0.12] - 2026-01-19
Added
- ManageGameObject
- Added
list_childrenaction for listing GameObject children with configurable depth - Support for three result modes:
auto(default),inline, andfile - Automatic fallback to file output when hierarchy exceeds
maxInlineItemsthreshold (default: 200) - Depth-limited traversal with
depthparameter (default: 1 for direct children) includeInactiveparameter to control whether inactive GameObjects are included- Iterative tree building to avoid stack overflow on deep hierarchies
- JSON streaming to file for large results to prevent memory issues
- New helper methods:
CountDescendantsUpToDepth,BuildChildrenTreeIterative,WriteChildrenTreeIterative
- Added
Enhanced
-
ManageScene
- Improved large scene hierarchy handling (>500 GameObjects)
- Returns shallow root-only tree with hints instead of error when scene is too large
- Changed
CountGameObjectsRecursiveto use iterative traversal (stack-based) to avoid stack overflow on deep hierarchies - Better user guidance for drilling down into large hierarchies incrementally
-
Coverage Tools
- Added
CodelyUnityCoverageToolsclass for E2E test utilities - New
codely.generate_large_hierarchycustom tool for quickly generating test hierarchies - Configurable generation parameters: root name, child/grandchild prefixes, and counts
- Added
Test Coverage
- Added
unity_large_hierarchy_e2e_coverage.mdwith 152 lines of E2E test scenarios for large hierarchy handling - Updated
unity_gameobject_full_coverage.mdwithlist_childrenaction coverage - Updated
unity_scene_full_coverage.mdwith improved large scene handling coverage
[1.0.11] - 2026-01-13
Added
- Tuanjie Editor Scene File Support
- Added support for
.scenefile extension used by Tuanjie Editor - Implemented extension-aware scene path handling in
ManageScene - Support both
.unity(Unity Editor) and.scene(Tuanjie Editor) extensions based on editor type
- Added support for
Enhanced
-
UnityStateDirtyHook
- Added
.sceneextension detection for scene file change tracking - Ensures proper state tracking for both Unity and Tuanjie editor scene files
- Added
-
Documentation
- Improved documentation for scene file extension handling
[1.0.10] - 2026-01-12
Fixed
-
ManageGameObject
- Updated default behavior for
searchInactiveparameter fromfalsetotrue - Ensures inactive GameObjects are included in search results unless explicitly specified otherwise
- Updated default behavior for
-
UnityEngineObjectConverter
- Added support for
{"find":"...", "method":"..."}reference format in object deserialization - Fixed deserialization errors when encountering find instruction format used by MCP tools for dynamic GameObject lookups
- Implemented delegate pattern to call
ManageGameObject.FindObjectByInstructionfrom Runtime assembly without direct Editor assembly reference
- Added support for
[1.0.9] - 2026-01-05
Changed
- Unity Project Metadata
- Updated Unity project metadata GUIDs across all .meta files
- Refreshed GUIDs in Editor, Runtime, and Tests directories
[1.0.8] - 2025-12-16
Enhanced
- Compilation Tracking
- Improved compilation error/warning count tracking with nullable integers
- Changed
CompilationHelper.GetCompilationErrors()andGetCompilationWarnings()to returnint?instead ofint - Updated
GetCompilationSummary()to only include known values in result (removes misleading default 0 values) - Enhanced compilation result handling in
ManageEditorto properly process nullable values - Improved type handling for compilation result payloads (supports both dictionary and anonymous object formats)
- Added clarifying comments explaining why returning 0 for unknown counts is problematic
- Better distinction between "0 errors/warnings" (validated) vs "unknown count" (not yet validated)
[1.0.7] - 2025-12-15
Changed
-
Package Renaming
- Renamed package from
com.unity.codelytocn.tuanjie.codely.bridge - Updated all internal references and documentation to reflect new package name
- Renamed package from
-
Branding Update
- Renamed all menu item paths and labels in the Unity Editor
[1.0.6] - 2025-12-10
Added
- Compilation Pipeline
- New
pipeline_kind: "compile"field for structured hints to downstream tools requires_console_validation: trueflag to guide compilation validation- Comprehensive integration test documentation for compilation pipeline policy
- Enhanced play mode state synchronization with
playModefield in responses
- New
Enhanced
-
StateComposer
- Simplified state reporting to focus on essential information (compiling vs idle)
- Minimized state complexity with clear documentation directing users to specific diagnostic tools
-
ManageAsset
- Improved
AssetExistsmethod with ghost asset detection - New
BuildAssetNotFoundResponsefor better error messaging about desync issues - Enhanced asset validation and error handling
- Improved
-
Test Coverage
- Added
unity_compile_pipeline_integration.mdwith 152 lines of comprehensive test scenarios - Updated
unity_editor_full_coverage.mdwith compilation pipeline requirements
- Added
[1.0.5] - 2025-12-04
Added
- Test Coverage
- Added comprehensive test coverage for
ExecuteCustomToolfunctionality - UI Toolkit tools test coverage documentation and validation
- Added comprehensive test coverage for
Enhanced
-
ManageUIToolkit
- Enhanced
link_uss_to_uxmlaction with GUID support - Added
ResolveAssetPathhelper method for flexible path/GUID resolution - Improved parameter validation for mixed path/GUID usage
- Enhanced
-
ManageShader
- Enhanced
ensure_material_shader_for_srpaction withmaterial_guidparameter support - Improved parameter handling for material identification via path or GUID
- Better error messages for missing material parameters
- Enhanced
-
CodelyUnityValidationTools
- Added nested field path support in
validate_response - Support for dot-notation field paths (e.g., "state.project.srp", "project.srp")
- Automatic recursive field search when direct path fails
- Enhanced field validation with path tracking and debugging
- Added nested field path support in
-
ManageBake
- Refactored NavMesh operations to use runtime reflection
- Improved AI Navigation package detection and type resolution
- Better compatibility with optional AI Navigation package installation
- Enhanced error handling for missing package scenarios
[1.0.4] - 2025-12-03
Added
-
Validation Tools Framework
- New
CodelyUnityValidationTools: 15+ validation helpers for automated testing codely.validate_play_mode: Validate current editor PlayMode statecodely.validate_active_tool: Validate current active editor toolcodely.validate_not_compiling: Ensure editor is not compilingcodely.validate_tag_and_layer_exist: Verify Tag/Layer existencecodely.validate_window_open: Check editor window statecodely.validate_console_contains: Validate console messages with filtercodely.validate_console_count: Verify console message countscodely.validate_active_scene: Validate active scene propertiescodely.validate_scene_dirty: Check scene dirty statecodely.validate_hierarchy_root_count: Verify hierarchy root object countcodely.validate_gameobject_exists: Check GameObject existencecodely.validate_response: Generic response validation
- New
-
Compilation Pipeline
CompilationHelper: New helper class for compilation status checking and error trackingstart_compilation_pipelineaction in ManageEditor for standardized compile workflow- Block compilation during play mode to prevent editor errors
-
Test Coverage Documentation
- Complete test coverage specs for all Unity tools
unity_editor_full_coverage.md: 24 actions coverageunity_console_full_coverage.md: Console operations coverageunity_scene_full_coverage.md: Scene management coverageunity_gameobject_full_coverage.md: GameObject operations coverageunity_asset_full_coverage.md: Asset management coverageunity_script_full_coverage.md: Script management coverageunity_shader_full_coverage.md: Shader operations coverageunity_package_full_coverage.md: Package manager coverageunity_menu_full_coverage.md: Menu execution coverage
Enhanced
-
State Management
- State delta tracking added to async operation responses
- Client state revision validation for all write operations
- Enhanced console state tracking with
since_tokenfiltering
-
ManageEditor
- Idempotent
ensure_tagandensure_layeroperations - Extended with compilation pipeline integration
- Idempotent
-
ManageAsset
- Enhanced robustness with better error handling
-
ManageGameObject
- Improved serialization with
GameObjectSerializerenhancements
- Improved serialization with
-
ReadConsole
- Enhanced filtering with
since_tokensupport for incremental reads
- Enhanced filtering with
-
ExecuteCustomTool
- Improved tool registry with better parameter validation
Fixed
- Improved Unity version compatibility across various tools
[1.0.3] - 2025-12-01
Added
-
State Management System
AsyncOperationTracker: Comprehensive async operation management with progress tracking and cancellation supportStateComposer: Full Unity state composition including scene, project, packages, and shadersUnityStateDirtyHook: Automatic tracking of Unity Editor state changes (hierarchy, project, selection, console)WriteGuard: Thread-safe write operation protection with main thread enforcement- New
get_current_stateendpoint for retrieving complete Unity state snapshots
-
New Unity Tools
ManageBake: Light baking controls (start, cancel, clear, status queries)ManagePackage: Package manager operations with version pinning support (package@version syntax)ManageUIToolkit: UI Toolkit template instantiation with automatic USS/C# generation
-
Custom Tool Execution Framework
ExecuteCustomTool: Reflection-based tool discovery and execution via[CustomTool]attribute- Automatic tool registry with parameter validation and error handling
- Support for custom tools without modifying CommandRegistry
-
Enhanced Existing Tools
ManageEditor: Extended with state-aware operations and full state retrievalManageGameObject: Added find, query, parent/child operations, and component managementManageAsset: New asset import, export, and metadata operationsManageScene: Enhanced with scene creation and multi-scene managementManageShader: Expanded with shader compilation, variant queries, and global property managementReadConsole: Added scope-based console clearing and entry filtering
Enhanced
- Response Helpers: New state-aware methods (
SuccessWithDelta,SuccessWithState,Conflict) for better change tracking - CompilationHelper: Improved compilation workflow handling with better async integration
- Test Coverage: Added unit tests for
AsyncOperationTracker,StateComposer, andWriteGuard
[1.0.2] - 2025-11-11
Fixed
- Unity Version Compatibility: Added conditional compilation in
ManageGameObject.cs- Uses
FindObjectsByTypewithFindObjectsInactiveenum for Unity 2022.2+ - Falls back to
FindObjectsOfTypefor Unity 2021.3 and earlier - Resolves CS0246 error:
FindObjectsInactivetype not found on Unity 2021 - Maintains backward compatibility across Unity versions
- Uses
[1.0.1] - 2025-11-07
Fixed
- 🐛 Fixed build compilation error
- Corrected assembly definition configuration for
UnityTcp.Editor.asmdef - Changed from platform exclusion list to explicit Editor platform inclusion
- Ensures Editor assembly only compiles in Unity Editor, not in game builds
- Resolves compilation errors during game packaging for all platforms
- Corrected assembly definition configuration for
[1.0.0] - 2024-12-19
Major Refactoring
- 🔄 Complete removal of MCP (Model Context Protocol) logic
- Removed all MCP-specific components, tools, and protocol handling
- Eliminated MCP server integration and HTTP server components
- Removed MCP client models, configuration systems, and UI windows
New TCP-Focused Architecture
- 🚀 Pure TCP Socket Implementation
- New
UnityTcpBridgeclass for TCP server management - Basic echo server implementation as starting point
- Async/await patterns for non-blocking operations
- Multi-client connection support with proper resource management
- New
Core TCP Features
-
Port Management
- Automatic port discovery and allocation
- Project-specific port persistence
- Smart port conflict resolution
- Cross-platform compatibility
-
Connection Handling
- TCP listener with automatic client acceptance
- Configurable socket options (keep-alive, timeouts)
- Graceful connection cleanup on shutdown
- Unity lifecycle integration (assembly reload, editor quit)
Updated Components
- Renamed Assemblies:
UnityTcp.*→UnityTcp.* - Updated Namespaces: All classes moved to
UnityTcp.Editor.*namespace - Simplified Helpers: Kept only TCP-relevant utilities (PortManager, TcpLog)
- Package Rebranding: Updated from "Unity MCP" to "Unity TCP Bridge"
Removed Components
- All MCP protocol handling and message processing
- MCP tool implementations (ManageScript, ManageAsset, etc.)
- MCP UI windows and editor integrations
- HTTP server and MCP server management
- Telemetry and MCP-specific logging
- Configuration builders and MCP client models
Technical Details
- Architecture: Direct TCP socket server with customizable protocol handling
- Performance: Lightweight implementation focused on TCP networking
- Compatibility: Unity 2021.3+ with Newtonsoft.Json dependency
- Protocol: Basic TCP with welcome handshake (easily customizable)
Migration Guide
This is a breaking change that removes all MCP functionality:
- Previous MCP Users: This package no longer provides MCP integration
- TCP Socket Users: Replace any
UnityTcpBridgereferences withUnityTcpBridge - Custom Protocols: Implement your protocol logic in
HandleClientAsyncmethod - Port Management: Use
PortManagerfor dynamic port allocation needs
Development Notes
- Codebase reduced by ~80% by removing MCP complexity
- Focus shifted to providing a clean TCP socket foundation
- Easy to extend for custom networking protocols
- Maintains Unity Editor integration for automatic lifecycle management
Previous Versions
Previous versions (1.x.x) included MCP (Model Context Protocol) integration which has been completely removed in this version.